bitcoin-dev

Prevent future duplicate coinbase transactions as part of Consensus Cleanup

Prevent future duplicate coinbase transactions as part of Consensus Cleanup

Original Postby Antoine Poinsot

Posted on: November 22, 2024 18:54 UTC

Antoine Poinsot has initiated a discussion regarding the Consensus Cleanup proposal to address the issue of potential duplicate coinbase transactions in the Bitcoin network.

The primary focus is on preventing the necessity to re-enable BIP30 verification after the block height reaches 1,983,702. Poinsot outlines several proposed solutions to ensure that future coinbase transactions are distinguishable from early transactions that committed to a future block height, thus avoiding duplication. This concern arises from BIP34's requirement for the block height to be included as the first element of the scriptSig in coinbase transactions, an issue compounded by some transactions predating BIP34 and committing to future heights.

The proposed fixes include modifications to various transaction elements such as nLocktime, nSequence, and nVersion fields, along with ensuring the presence of a witness commitment even in blocks without SegWit transactions. These measures aim to differentiate future coinbase transactions from those early ones that specified a block height, thereby eliminating the risk of duplication. Poinsot is seeking feedback from engineers and stakeholders in the mining industry on these proposals, inviting input on their feasibility and impact on mining operations. He highlights an additional motivation for these changes: the inability of Utreexo nodes to perform BIP30 validation, which underscores the need for a solution that accommodates future technological advancements within the Bitcoin network.

For further details, references are made to specific sources including comments within the Bitcoin Core source code and a post in the Consensus Cleanup thread, which lists all block heights below 10,000,000 committed in early coinbase transactions. Poinsot encourages responses from individuals in the mining sector, whether through direct reply or participation in the ongoing Delving thread discussion, to gather insights and alternative suggestions that could inform the final approach to resolving this issue.