Module check

Module check 

Source
Expand description

Consensus critical contextual checks

Re-exportsΒ§

pub use utxo::transparent_coinbase_spend;

ModulesΒ§

anchors πŸ”’
Checks for whether cited anchors are previously-computed note commitment tree roots.
difficulty πŸ”’
Block difficulty adjustment calculations for contextual validation.
nullifier πŸ”’
Checks for nullifier uniqueness.
utxo πŸ”’
Consensus rule checks for the finalized state.

FunctionsΒ§

block_commitment_is_valid_for_chain_history πŸ”’
Check that block is contextually valid for network, using the history_tree up to and including the previous block.
block_is_not_orphaned πŸ”’
Returns ValidateContextError::OrphanedBlock if the height of the given block is less than or equal to the finalized tip height.
block_is_valid_for_recent_chain πŸ”’
Check that the semantically verified block is contextually valid for network, based on the finalized_tip_height and relevant_chain.
difficulty_threshold_and_time_are_valid πŸ”’
Validate the time and difficulty_threshold from a candidate block’s header.
height_one_more_than_parent_height πŸ”’
Returns ValidateContextError::NonSequentialBlock if the block height isn’t equal to the parent_height+1.
initial_contextual_validity πŸ”’
Perform initial contextual validity checks for the configured network, based on the committed finalized and non-finalized state.
legacy_chain πŸ”’
Check if zebra is following a legacy chain and return an error if so.