pull down to refresh

I have been trying to track the progress hornet node is making since its initial proposal in September of 2025 (#1233022), and on through it's release of Hornet UTXO (#1415244) and the Hornet Node update in February (#1443533).

Toby Sharpe recently released what he described as "A declarative executable specification of Bitcoin consensus rules" on the Bitcoin Development Mailing List.

This is very interesting, and it's also been cool to see Eric Voskuil discussing the idea of formalizing Bitcoin's block validation rules. It will be very interesting to keep track of the discussion around this.

Here is how Sharp describes the the idea of such a specification:

The declarative specification separates what must be true from how it is computed. Each Rule line names a C++ function that validates the specific semantic rule in question, and also gives an English description of the rule being enforced.

Block Validation RulesBlock Validation Rules

IDRuleFunction
Header Rules
H01A header MUST reference the hash of a valid parent block.ValidatePreviousHash
H02A header's hash MUST achieve its own proof-of-work target.ValidateProofOfWork
H03A header's proof-of-work target MUST satisfy the difficulty adjustment formula for the timechain.ValidateDifficultyAdjustment
H04A header timestamp MUST be strictly greater than the median of its 11 ancestors' timestamps.ValidateMedianTimePast
H05A header timestamp MUST be less than or equal to network-adjusted time plus 2 hours.ValidateTimestampCurrent
H06A header's version number MUST NOT have been retired by any activated soft fork.ValidateVersion
Local Rules
L01A block MUST contain at least one transaction.ValidateNonEmpty
L02A block’s Merkle root field MUST equal the unique Merkle root of its transactions.ValidateMerkleRoot
L03A block’s serialized size excluding witness flags and data MUST NOT exceed 1,000,000 bytes.ValidateOriginalSizeLimit
L04A block's first transaction MUST be its only coinbase transaction.ValidateCoinbase
L05The total legacy signature-operation count over all input and output scripts MUST NOT exceed 20,000.ValidateSignatureOps
L06A transaction MUST contain at least one input.ValidateInputCount
L07A transaction MUST contain at least one output.ValidateOutputCount
L08A transaction's serialized size excluding witness flags and data MUST NOT exceed 1,000,000 bytes.ValidateTransactionSize
L09All transaction output amounts MUST be non-negative.ValidateOutputsNonNegative
L10The sum of a transaction's output amounts MUST NOT exceed 21,000,000 coins.ValidateOutputsSum
L11A transaction's inputs MUST NOT contain duplicate outpoints.ValidateUniqueInputs
L12A coinbase transaction's sig script size MUST be between 2 and 100 bytes inclusive.ValidateCoinbaseSignatureSize
L13A non-coinbase transaction's inputs MUST have non-null previous outputs.ValidateInputsPrevout
Contextual Rules
C01All transactions in the block MUST be final given the block height and locktime rules.ValidateTransactionFinality
C02A pre-SegWit block MUST NOT contain any witness data.ValidateNoWitnessPreSegwit
C03A block’s total weight MUST NOT exceed 4,000,000 weight units.ValidateBlockWeight
C04From BIP34: The coinbase transaction’s sig script MUST begin by pushing the block height.ValidateCoinbaseHeight
C05From BIP141: A block containing witness data MUST contain a witness commitment.ValidateWitnessCommitment
C06From BIP141: A post-Segwit block containing a witness commitment MUST contain a witness nonce.ValidateWitnessNonce
C07From BIP141: A post-SegWit block containing a witness commitment MUST commit to its witness Merkle root and nonce.ValidateWitnessMerkle
Spending Rules
S01Transaction outputs MUST NOT give rise to duplicates of existing unspent outpoints (BIP30).ValidateOutPointsUnique
S02A transaction input MUST reference a previous transaction output that remains unspent.ValidateInputPrevoutsUnspent
S03The total signature-operation cost over all transactions MUST NOT exceed 80,000.ValidateSigOpCosts
S04The total amount in coinbase outputs MUST NOT exceed the block reward.ValidateBlockSubsidy
S05The sum of output values in a transaction MUST NOT exceed the sum of all input values being spent.ValidateOutputsAtMostInputs
S06A non-coinbase input MUST satisfy the spent output's locking script.ValidateScripts
S07From BIP68: Each input that signals a relative lock-time interval MUST have reached relative finality.ValidateSequenceLocks
S08Coinbase outputs MUST NOT be spent before 100 blocks after their creation.ValidateCoinbaseMaturity

You can find the full specification here

The consensus is I need bitcoin

reply