Expand description
The implementation of Merkle Patricia Trie, a cryptographically authenticated radix trie that is used to store key-value bindings. https://ethereum.org/en/developers/docs/data-structures-and-encoding/patricia-merkle-trie/
§Feature Flags
test-utils
: Export utilities for testing
Modules§
- The implementation of forward-only in-memory cursor.
- The implementation of hash builder. MPT hash builder implementation.
- The cursor implementations for navigating hashed state.
- metrics
metrics
Trie calculation metrics. - The iterators for traversing existing intermediate hashes and updated trie leaves.
- The implementation of a container for storing intermediate changes to a trie. The container indicates when the trie has been modified.
- Merkle proof generation.
- Common root computation functions.
- serde_
bincode_ compat serde
andserde-bincode-compat
Bincode-compatible serde implementations for trie types. - Trie calculation stats.
- test_
utils test-utils
Collection of trie-related test utilities. - The cursor implementations for navigating account and storage tries.
- triehash
test-utils
Implementation of hasher using our keccak256 hashing function for compatibility withtriehash
crate. - Buffer for trie updates.
- The trie walker for iterating over the trie nodes.
- Trie witness generation.
Structs§
- The merkle proof with the relevant account info.
- A branch node in an Ethereum Merkle Patricia Trie.
- A struct representing a branch node in an Ethereum trie.
- A reference to BranchNode and its state mask. NOTE: The stack may contain more items that specified in the state mask.
- An extension node in an Ethereum Merkle Patricia Trie.
- Reference to the extension node. See ExtensionNode from more information.
- A component used to construct the root hash of the trie.
- Sorted account state optimized for iterating during state trie calculation.
- Representation of in-memory hashed state.
- Sorted hashed post state optimized for iterating during state trie calculation.
- Representation of in-memory hashed storage.
- Sorted hashed storage optimized for iterating during state trie calculation.
- The intermediate state of the state root computation.
- A key hasher that uses the Keccak-256 hash function.
- A leaf node represents the endpoint or terminal node in the trie. In other words, a leaf node is where actual values are stored.
- Reference to the leaf node. See LeafNode from more information.
- The state multiproof of target accounts and multiproofs of their storage tries. Multiproof is effectively a state subtrie that only contains the nodes in the paths of target accounts.
- Structure representing a sequence of nibbles.
- An RLP-encoded node.
StateRoot
is used to compute the root node of a state trie.- The merkle multiproof of storage trie.
- The merkle proof of the storage entry.
StorageRoot
is used to compute the root node of an account storage trie.- Account storage trie node.
- The representation of nibbles of the merkle trie stored in the database.
- The representation of nibbles of the merkle trie stored in the database.
- Walker sub node for storing intermediate state root calculation state in the database.
- An Ethereum account as represented in the trie.
- Inputs for trie-related computations.
- A struct representing a mask of 16 bits, used for Ethereum trie operations.
Enums§
- The progress of the state root computation.
- Enum representing an MPT trie node.
Constants§
- The range of valid child indexes.
- Root hash of an empty trie.
- The maximum size of RLP encoded trie account in bytes. 2 (header) + 4 * 1 (field lens) + 8 (nonce) + 32 * 3 (balance, storage root, code hash)
Traits§
- Trait for hashing keys in state.