The Tragic Tale of BIP30

Posted by Ruben Somsen

Apr 27, 2025/16:45 UTC

In a recent exploration of SwiftSync, it was discovered that a potential issue exists which could become exploitable once checkpoints set up until 2013 are removed. These checkpoints currently prevent a reorganization (reorg) back to 2010, thus mitigating the risk. BIP30, a unique piece in the consensus checks because it encompasses the entire Unspent Transaction Output (UTXO) set without directly relating to the spending of inputs, has been identified as inefficient and complicates the implementation of alternative validation methods such as utreexo, SwiftSync, and possibly Zero-Knowledge Proof (ZKP) systems like ZeroSync. There is a discussion about the possibility and implications of sunsetting BIP30 altogether.

The primary concern regarding BIP30 involves two duplicate transactions that were treated as exceptions. Specifically, an issue arises when a reorg occurs between block 91722 and 91880, leading to one of the coinbase transactions being overwritten and potentially causing a fork if the UTXO is later spent by a node unaware of the reorg. Two proposed solutions include enforcing a rule that no reorg can occur between these blocks or changing the pre-checkpoint consensus rules to not remove the coinbase transaction in the case of a reorg involving blocks 91880 and 91842.

Additionally, BIP30 remains indefinitely active from genesis until BIP34 activates at block height 227931 (March 2013). If this block is reorged out, BIP34 deactivates, raising concerns about the creation of outputs that could conflict with BIP34's rules for ensuring coinbase transaction uniqueness. The inefficiency of BIP30's UTXO set check has prompted suggestions to replace it with a more efficient system that caches coinbase TXIDs to ensure no duplicates exist, potentially allowing BIP30 to be sunsetted completely. This approach would involve checking coinbase uniqueness up until block 227931 and ensuring future coinbases do not conflict with BIP34 or the Consensus Cleanup BIP, facilitating BIP34's activation regardless of a reorg.

These discussions and proposed solutions underscore the complexity of maintaining and updating blockchain consensus mechanisms, especially in light of new technologies and methodologies that offer increased efficiency and security. The dialogue continues among developers, highlighting the collaborative effort to address and resolve these technical challenges.

Link to Raw Post
Bitcoin Logo

TLDR

Join Our Newsletter

We’ll email you summaries of the latest discussions from authoritative bitcoin sources, like bitcoin-dev, lightning-dev, and Delving Bitcoin.

Explore all Products

ChatBTC imageBitcoin searchBitcoin TranscriptsSaving SatoshiBitcoin Transcripts Review
Built with 🧡 by the Bitcoin Dev Project
View our public visitor count

We'd love to hear your feedback on this project?

Give Feedback