Structs§
- Merkle
Branch - A Merkle branch (proof) from a leaf or midpoint to the root
- Merkle
Payment Candidate Node - A node’s signed quote for potential reward eligibility
- Merkle
Payment Candidate Pool - One candidate pool: midpoint proof + nodes who could store addresses
- Merkle
Payment Proof - Data package sent from client to node for data storage and payment verification
- Merkle
Tree - A Merkle tree built from XorNames (content addresses)
- Midpoint
Proof - A reward candidate derived from a midpoint
- OnChain
Payment Info - What’s stored on-chain (or disk) - indexed by winner_pool_hash
- Pool
Commitment - Minimal pool commitment for smart contract submission
Enums§
- BadMerkle
Proof - Errors that can occur when verifying a Merkle proof for batch payments
- Merkle
Payment Verification Error - Errors that can occur during Merkle payment verification
- Merkle
Tree Error - Errors that can occur when working with Merkle trees
Constants§
- CANDIDATES_
PER_ POOL - Number of candidate nodes per pool (provides redundancy)
- MAX_
LEAVES - Maximum number of leaves (2^MAX_MERKLE_DEPTH)
- MAX_
MERKLE_ DEPTH - Maximum supported Merkle tree depth
- MERKLE_
PAYMENT_ EXPIRATION - Maximum age of a Merkle payment (one week in seconds) Payments older than this are considered expired and nodes will reject addresses
Functions§
- expected_
reward_ pools - Calculate expected number of reward pools for a given tree depth
- verify_
merkle_ proof - Verify a address proof against smart contract payment data