BIP 34: Block v2, Height in Coinbase



Summary:

The Bitcoin Improvement Proposal 34 (BIP: 34) introduces an upgrade path for versioned transactions and blocks. Gavin Andresen created the BIP on July 6, 2012, as a draft. The abstract explains that Bitcoin blocks and transactions are versioned binary structures, both of which currently use version 1. The proposal adds a unique nonce to newly produced coinbase transactions, and blocks are updated to version 2. The motivation behind this proposal is to clarify and exercise the mechanism whereby the bitcoin network collectively consents to upgrade transaction or block binary structures, rules, and behaviors. It also aims to enforce block and transaction uniqueness and assist unconnected block validation. The specification mentioned in the BIP includes treating transactions with a version greater than 1 as non-standard. The first item in the coinbase transaction's scriptSig will be the height, and the block version will increase to 2. The format of the height would be serialized CScript - the first byte is the number of bytes in the number, followed by little-endian representation of the number. The BIP also mentions two rules - the 75% rule and the 95% rule - for rejecting invalid version 2 blocks. Backward compatibility is maintained as all older clients remain compatible with this change. Users and merchants should not be impacted. However, miners are strongly recommended to upgrade to version 2 blocks. Once 95% of the miners have upgraded to version 2, the remainder will be orphaned if they fail to upgrade. The implementation of the BIP can be found at https://github.com/bitcoin/bitcoin/pull/1525 and https://github.com/bitcoin/bitcoin/pull/1526.


Updated on: 2023-06-06T06:03:29.904711+00:00