Skip to main content

check_proof_of_work

Function check_proof_of_work 

Source
pub fn check_proof_of_work(header: &BlockHeader) -> Result<bool, ConsensusError>
Expand description

CheckProofOfWork: ℋ → {true, false}

Check if the block header satisfies the proof of work requirement. Formula: SHA256(SHA256(header)) < ExpandTarget(header.bits)