Difference between revisions of "Bailment Database"

From Open Transactions
Jump to navigation Jump to search
m (Update links and correct category, improve justification)
m (commas)
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
==Purpose==
+
==Purpose and Requirements==
  
The [[Audit Server (voting pools)|audit server]] and [[Transaction Server (voting pools)|transaction server]] both store a deposit database which permanently associate deposit addresses with [[nym|nyms]]. This allows unsolicited or duplicate deposits to be properly credited, and also prevents a malicious transaction server for assigning a deposit address to two different nyms.
+
Voting pools must be able to maintain accurate accounting between the OT balances issued and the actual amount of blockchain currency under their control. For this reason, every [[deposit address]] should be associated with a specific account to receive the initial credit for incoming blockchain transactions. This association must be maintained as a permanent record, because it's not possible to ensure users do not reuse deposit addresses.
 +
 
 +
Every notary and every auditor in the voting pool maintains a full bailment database for the entire pool. Auditors need a full database to ensure that notaries credit the correct nyms for incoming deposits. Notaries need a full database because users will verify bailment instructions by querying notaries other than the ones which provided them with the instructions.
 +
 
 +
The bailment database must be currency-agnostic because auditors and notaries do not contain any blockchain currency-specific knowledge.
  
 
==Format==
 
==Format==
Line 7: Line 11:
 
The database contains the following fields:
 
The database contains the following fields:
  
 +
; [[server id]]
 +
: The identifier for the notary managing the account associated with this bailment
 +
; [[transaction number]]
 +
: The transaction number associated with the [[bailment]] request.
 +
; [[nym id]]
 +
: The nym who owns the account associated with this bailment
 +
; [[account id]]
 +
: The account to be credited for the bailment. All incoming blockchain deposits to the address defined in this record will be credited to this account.
 +
; [[Wallet_(blockchain)#Address_Identification|address identifier]]
 +
: The blockchain deposit address, specified in a currency-agnostic manner
 +
; [[output script]]
 +
: The currency-specific representation of the address identifier. The auditor and notary will never parse the data in this field, but they can perform comparisons on it.
  
[[Wallet_(blockchain)#Address_Identification|address identifier]]
+
The (server id, transaction number) fields must be unique across all entries in the database and together they form the canonical identifier for distinguishing between, and tracking the lifecycle of, bailments.
 
 
pendingBailment ID,
 
 
 
nym
 
 
 
  
 
[[Category:Voting Pool Technical Specifications]]
 
[[Category:Voting Pool Technical Specifications]]

Latest revision as of 14:59, 8 October 2014

Purpose and Requirements

Voting pools must be able to maintain accurate accounting between the OT balances issued and the actual amount of blockchain currency under their control. For this reason, every deposit address should be associated with a specific account to receive the initial credit for incoming blockchain transactions. This association must be maintained as a permanent record, because it's not possible to ensure users do not reuse deposit addresses.

Every notary and every auditor in the voting pool maintains a full bailment database for the entire pool. Auditors need a full database to ensure that notaries credit the correct nyms for incoming deposits. Notaries need a full database because users will verify bailment instructions by querying notaries other than the ones which provided them with the instructions.

The bailment database must be currency-agnostic because auditors and notaries do not contain any blockchain currency-specific knowledge.

Format

The database contains the following fields:

server id
The identifier for the notary managing the account associated with this bailment
transaction number
The transaction number associated with the bailment request.
nym id
The nym who owns the account associated with this bailment
account id
The account to be credited for the bailment. All incoming blockchain deposits to the address defined in this record will be credited to this account.
address identifier
The blockchain deposit address, specified in a currency-agnostic manner
output script
The currency-specific representation of the address identifier. The auditor and notary will never parse the data in this field, but they can perform comparisons on it.

The (server id, transaction number) fields must be unique across all entries in the database and together they form the canonical identifier for distinguishing between, and tracking the lifecycle of, bailments.