Skip to main content

validate_prev_block_hash

Function validate_prev_block_hash 

Source
pub fn validate_prev_block_hash(
    child: &BlockHeader,
    parent: &BlockHeader,
) -> bool
Expand description

H08 (§5.3.1): child.prev_block_hash MUST equal block_header_hash(parent).

Pure predicate for spec-lock binding. The node layer calls this before connect_block when the parent header is known; IBD/header sync enforces the same invariant while walking the chain.