Module miden_crypto::merkle
source · Expand description
Data structures related to Merkle trees based on RPO256 hash function.
Structs
- Contains precomputed roots of empty subtrees in a Merkle tree.
- Representation of a node with two children used for iterating over containers.
- A merkle path container, composed of a sequence of nodes of a Merkle tree.
- An in-memory data store for Merkelized data.
- MerkleStoreDelta stores a vector of (RpoDigest, MerkleTreeDelta) tuples where the RpoDigest represents the root of the Merkle tree and MerkleTreeDelta represents the differences between the initial and final Merkle tree states.
- A fully-balanced binary Merkle tree (i.e., a tree where the number of leaves is a power of two).
- [MerkleDelta] stores the differences between the initial and final Merkle tree states.
- A fully materialized Merkle Mountain Range, with every tree in the forest and all their elements.
- Address to an arbitrary node in a binary tree using level order form.
- A partial Merkle tree with NodeIndex keys and 4-element RpoDigest leaf values. Partial Merkle Tree allows to create Merkle Tree by providing Merkle paths of different lengths.
- A container for a MerklePath and its [Word] root.
- A sparse Merkle tree with 64-bit keys and 4-element leaf values, without compaction.
- Tiered (compacted) Sparse Merkle tree mapping 256-bit keys to 256-bit values. Both keys and values are represented by 4 field elements.
- A proof which can be used to assert membership (or non-membership) of key-value pairs in a Tiered Sparse Merkle tree.
- A container for a [Word] value and its MerklePath opening.
Enums
Functions
- Extracts a [MerkleDelta] object by comparing the leaves of two Merkle trees specifies by their roots and depth.
- Utility to visualize a MerklePath in text.
- Utility to visualize a MerkleTree in text.
Type Aliases
- A default MerkleStore which uses a simple BTreeMap as the backing storage.
- A MerkleStore with recording capabilities which uses RecordingMap as the backing storage.