Cointime

Download App
iOS & Android

The Untold Story of ditto-b

From Jameson Lopp

The fourth Bitcoin halving just triggered a few hours ago, ushering in the 5th mining epoch. As such, this seems like a good time to tell the tale of a little-known Bitcoin contributor who had a massive effect upon the halving algorithm.

The story takes place 10 years ago when an anonymous developer with no reputation managed to make a significant change to the Bitcoin consensus rules.

The Timeline

A user by the handle "ditto-b" joined GitHub on April 8, 2011.

In 2013 they forked OpenTransactions but didn't seem to do anything with it.

Ditto-b was a fan of Runescape as we can see from this table of Experience Point Levels. https://gist.github.com/ditto-b/933800

Ditto-b also built a basic funds sending script for interacting witih Bitcoin compatible RPC nodes. https://gist.github.com/ditto-b/9360868

On March 10, 2014 they created a pull request to change 4 lines of code in the Bitcoin repository.

These four lines of code are consensus critical and are not to be trifled with!

Long story short: ditto-b discovered a common type of software flaw known as a value overflow bug. No one in Bitcoin's first 5 years of existence had thought through how this function would operate when the blockchain was at a height of 13,440,000 after 64 halvings.

A few weeks later, Pieter Wuille used the timing of the pull request to publish BIP-42 as an April Fool's Day joke that was simultaneously satirical and dead serious.

Ditto Who?

Does "ditto-b" mean anything? The first hit I could come up with is a particular Windows virus dating back to 2007 called Ditto.B.

Then I discovered that "Ditto" is a Pokemon character, and Ditto's attributes are... interesting.

Ditto - Pokedex Guide - IGNDitto is the most flexible Pokémon in the entire universe. It's mainly used for breeding, seeing as how it can mate with almost any Pokémon.

IGNJSnakeC, das6486, Jim McQ, +787 moreupdatedFeb 13, 2013

To use Ditto you have to know a weakness when you see a Pokémon, so you can choose the best possible move at all times. Ditto can only run one set usefully.

It's just interesting, and perhaps coincidental, that this character is related to knowing / exploiting weaknesses. Who knows if the username was chosen with the intention of conveying any meaning; it seems unlikely since the account was created 3 years before the pull request was made.

My Speculative Take

The history on ditto-b's account is suspiciously sparse. It's uncharacteristic, to say the least, for a developer with practically no real contribution activity to simply appear and propose a patch for such a niche edge case in an extremely complex software project.

It's incredibly unlikely that ditto-b was just a random person with no history of contributing to Bitcoin who happened to run across these crazy edge case. Ditto-b is most like a well-known "Bitcoin wizard" who, upon noticing this edge case, decided that it was too sensitive an issue to want to have their reputation linked to the proposed change. As such, they chose to report the issue via an alternate pseudonymous account.

We only ever got 2 sentences out of ditto-b, so there's no point attempting any sort of stylometric analysis, but this snarky comment certainly lends credence to my claim that it was a seasoned Bitcoin developer who was very familiar with the wider ecosystem.

Lessons Learned

In one respect, it's interesting that there were no activation parameters suggested for this consensus change. A soft fork will be executed at block height 13,440,000 without any signaling whatsoever. This leads me to conclude that:

  • Consensus changes that are considered "bug fixes" are assumed to have such strong consensus that the effort to write and test signaling activation logic is considered wasteful.
  • Uncontroversial consensus changes that don't activate for an extremely long period of time are similarly considered not worth the effort for activation logic, as it's assumed that everyone will have updated their code long before the soft fork activates.

Pieter phrased it a bit more humorously in BIP-42:

Given the moderate time frame over which this change is to be implemented, we expect all miners to choose to screw themselves and deploy this change before 2214.If they don't, and a minority remains on the old code base, a fork may occur. Essentially, they'll be mining fool's gold after that time.

This has some tie-ins to my previous analysis of non-backwards compatible changes to Bitcoin client code:

Comments

All Comments

Recommended for you

  • Cryptocurrency market financing totaled $1.02 billion in April, involving 161 financings

    On May 6th, it was reported that the total financing amount in the cryptocurrency market in April reached 1.02 billion US dollars, involving 161 financing deals. This is slightly lower than the total investment of 1.09 billion US dollars in March, which had 186 deals. However, cryptocurrency venture capital has exceeded 1 billion US dollars for the second consecutive month this year, marking the first time since the end of 2022 for the industry.

  • The total open interest of ETH contracts increased to $10.68 billion

    According to Coinglass data, the total open positions of ETH futures contracts on the entire network are 3.39 million ETH, equivalent to approximately 10.68 billion US dollars. Among them, the open positions of Binance ETH contracts are 1.16 million ETH (approximately 3.64 billion US dollars), ranking first.

  • Suspected MakerDAO multi-signature wallet deposited 750 MKR to Binance 2 hours ago

    According to Spot On Chain monitoring, MakerDAO has been depositing MKR into CEX. Two hours ago, the multi-signature wallet 0xbba (possibly MakerDAO) deposited 750 MKR (approximately $2.19 million) at an average price of $2920 to Binance.

  • BASE network TVL exceeds $1.5 billion

    According to DefiLlama data, BASE Network TVL is currently at $1.527 billion with a 24-hour increase of 0.53%. The top three ecological protocol TVL rankings are as follows: Aerodrome TVL reached $670 million with a 7-day decrease of 7.5%; Uniswap TVL reached $228 million with a 7-day decrease of 3.52%. ExtraFinance TVL reached $104 million with a 7-day decrease of 8.25%;

  • ZeroLend will open ZERO airdrop claims on Linea at 15:30 on May 6th, and will take a snapshot closer to TGE

    On May 6th, ZeroLend, a decentralized lending protocol, announced that ZERO airdrop claiming will be opened on Linea at 15:30 on May 6th, and ZERO trading will be opened at 16:00. The Zero Gravity points and earlyZERO (1 earlyZERO = 1 ZERO) accumulated by users will be automatically converted to ZERO and displayed on the reward page. In terms of airdrop distribution, ZeroLend will distribute 18% of the token supply to the community, of which 5% will be allocated to Zero Gravity participants and 13% will be allocated to earlyZERO holders. ZeroLend stated that a snapshot will be taken near TGE. ZERO stakers will receive voting rights, staking rewards, and potential future airdrops based on their voting power. If staked for more than 1 year, a staking bonus of 5%-20% can be obtained.

  • It is estimated that there are about 28 days left before ETC production cuts

    Data shows that Ethereum Classic (ETC) is expected to undergo a reduction in production on June 3, 2024, which is about 28 days and 6 hours away. The current block reward is 2.56 ETC, and after the reduction, it will be 2.048 ETC.

  • South Korea's Seoul Prosecutors' Office recovers and seizes 7.6 billion won worth of Ethereum

    The cybercrime investigation team of the Seoul Eastern District Prosecutor's Office in South Korea announced that they have recovered a deleted electronic wallet from a fraud suspect and seized 760 million Korean won (approximately $5.6 million) worth of Ethereum.

  • The total value of Starknet bridge storage exceeds 900,000 ETH

    According to Dune data, the total value bridged (TVB) by Ethereum Layer 2 solution Starknet has exceeded 900,000 ETH, reaching 901,512 ETH, which is approximately worth $2.84 billion at current prices. The total number of bridged user addresses is 1,225,098.

  • NFT transactions on the Bitcoin chain exceeded $55 million in the past 7 days

    According to CryptoSlam data, the Bitcoin on-chain NFT transaction volume in the past seven days reached 55.02 million US dollars, Ethereum NFT transaction volume reached 48.7 million US dollars, and Solana NFT transaction volume reached 24.62 million US dollars.

  • Bitcoin opens $63K futures gap as thin liquidity threatens BTC price

    Bitcoin market participants are doubting the staying power of the ongoing BTC price relief bounce.