Module zebra_consensus::block::check

source ·
Expand description

Consensus check functions

Functions§

  • Checks if there is exactly one coinbase transaction in Block, and if that coinbase transaction is the first transaction in the block. Returns the coinbase transaction is successful.
  • Returns Ok(()) if hash passes:
  • Returns Ok(ExpandedDifficulty) if thedifficulty_threshold of header is at least as difficult as the target difficulty limit for network (PoWLimit)
  • Returns Ok(()) if the EquihashSolution is valid for header
  • Check Merkle root validity.
  • Returns Ok(()) if the miner fees consensus rule is valid.
  • Returns Ok(()) if the block subsidy in block is valid for network
  • Returns Ok(()) if header.time is less than or equal to 2 hours in the future, according to the node’s local clock (now).