Module mpc

Source
Expand description

Multi-protocol commitments according to LNPBP-4 standard.

Structs§

Commitment
Final LNPBP-4 commitment value.
InvalidProof
Error constructing MPC Merkle tree due to invalid MerkleProof data.
LeafNotKnown
Error indicating that a given ProtocolId does not participate in a specific MPC Merkle tree.
MerkleBlock
Partially-concealed merkle tree data.
MerkleConcealed
A fully concealed MPC Merkle tree, consisting just of the Merkle root and information about its original depth and used cofactor.
MerkleProof
A proof of the merkle commitment.
MerkleTree
Complete information about LNPBP-4 merkle tree.
Message
Original message participating in multi-message commitment.
MultiSource
Structured source multi-message data for commitment creation
ProtocolId
Source data for creation of multi-message commitments according to LNPBP-4 procedure.

Enums§

Error
Errors generated during multi-message commitment process by MerkleTree::try_commit
Leaf
A leaf of the MPC Merkle tree.
MergeError
Errors happening during the MerkleBlock::merge_reveal_path procedure.
Method
A specific cryptographic digest algorithm used in constructing MPC Merkle trees.

Constants§

MPC_MINIMAL_DEPTH
The constant defining the minimum depth of the MPC Merkle tree.

Traits§

Proof
Marker trait for variates of LNPBP-4 commitment proofs, which differ by the amount of concealed information.

Type Aliases§

MessageMap
Map from protocol ids to commitment messages.