[−][src]Module lnpbp::strict_encoding
Modules
strategies | Implemented after concept by Martin Habovštiak martin.habovstiak@gmail.com |
Enums
Error | Possible errors during strict encoding and decoding process |
Traits
ReadExt | Re-exporting extended read and write functions from bitcoin consensus
module so others may use semantic convenience
|
Strategy | |
StrictDecode | Binary decoding according to the strict rules that usually apply to consensus-critical data structures. May be used for network communications. MUST NOT be used for commitment verification: even if the commit procedure uses StrictEncode, the actual commit verification MUST be done with [CommitVerify], [TryCommitVerify] and [EmbedCommitVerify] traits, which, instead of deserializing (nonce operation for commitments) repeat the commitment procedure for the revealed message and verify it against the provided commitment. |
StrictEncode | Binary encoding according to the strict rules that usually apply to
consensus-critical data structures. May be used for network communications;
in some circumstances may be used for commitment procedures; however it must
be kept in mind that sometime commitment may follow "fold" scheme
(Merklization or nested commitments) and in such cases this trait can't be
applied. It is generally recommended for consensus-related commitments to
utilize [CommitVerify], [TryCommitVerify] and [EmbedCommitVerify] traits |
WriteExt | Re-exporting extended read and write functions from bitcoin consensus
module so others may use semantic convenience
|
Functions
strict_decode | Convenience method for strict decoding of data structures implementing
StrictDecode from any byt data source. To support this method a
type must implement |
strict_encode | Convenience method for strict encoding of data structures implementing
StrictEncode into a byte vector. To support this method a
type must implement |