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

  • ETH Falls Below $2100

    Market data shows that ETH has fallen below $2100, currently priced at $2096.81, with a 24-hour increase of 2.47%. The market is experiencing significant volatility, so please ensure proper risk management.

  • PAYS Officially Launches on Nivex, Surges 100% on Debut

    At 15:18 on May 24, 2026, PAYS officially launched on the Nivex exchange and opened for trading globally.

  • U.S. Secretary of State: Announcement on Agreement with Iran Possible Later Sunday

    On May 24, U.S. Secretary of State Rubio stated that an announcement regarding an agreement with Iran may be made later on Sunday.

  • BTC Surpasses $77,000

    Market data shows that BTC has surpassed $77,000, currently priced at $77,073.6, with a 24-hour increase of 1.32%. The market is experiencing significant volatility, so please ensure proper risk management.

  • Trump: Calls with Multiple World Leaders, Iran Agreement Nearly Finalized

    On May 24, Trump stated on social media that he had "very good calls" in the Oval Office with leaders from Saudi Arabia, the UAE, Qatar, Pakistan, Turkey, Egypt, Jordan, Bahrain, and others regarding Iran and a peace memorandum. Trump claimed that the agreement has been largely negotiated and is pending finalization by the U.S., Iran, and other relevant countries. Additionally, his call with Israeli Prime Minister Netanyahu was also "very smooth." The final details of the agreement are under discussion and will be announced soon. Trump specifically noted that, in addition to several aspects of the agreement, the Strait of Hormuz will be opened.

  • BTC Surpasses $76,000

    Market data shows that BTC has surpassed $76,000, currently priced at $76,001.27, with a 24-hour increase of 0.05%. The market is experiencing significant volatility, so please ensure proper risk management.

  • US and Iran Expected to Announce Final Peace Agreement Within 24 Hours

    On May 24, according to the Washington Times citing sources close to the negotiations, the United States and Iran are expected to announce the finalization of a peace agreement within 24 hours after negotiating representatives approved a draft agreement to end all combat on the front lines. The agreement still awaits final approval from both governments.

  • Iran: Negotiations Focus on Ending War, Efforts to Finalize Memorandum of Understanding

    On May 23, Iranian Foreign Ministry spokesman Baghaei stated in an interview with the Islamic Republic of Iran Broadcasting that the current focus of negotiations is to promote an end to the 'imposed war,' with no in-depth discussions on nuclear issues at this stage. Iran and the U.S. are working to finalize a memorandum of understanding. Baghaei mentioned that the current negotiations do not involve specific details regarding nuclear issues and the corresponding lifting of sanctions, but Iran's demands for the lifting of sanctions, particularly the release of frozen assets, are clearly outlined in the 14 articles of the memorandum. He explained that Iran is not delving deeply into nuclear discussions at this stage because it believes that the nuclear issue has previously been used as a pretext for waging war against Iran. Currently, Iran is focusing on promoting the end of 'wars on all fronts,' including in Lebanon, and may enter into negotiations on nuclear issues in the next phase, possibly in 30 or 60 days.

  • BTC Falls Below $75,000

    Market data shows that BTC has fallen below $75,000, currently priced at $74,988, with a 24-hour decline of 3.19%. The market is highly volatile, so please ensure proper risk management.

  • Michael Saylor: Strategy May Sell Some Bitcoin Before 2026

    According to Michael Saylor, Chairman of Strategy, the company is unlikely to refrain from selling Bitcoin entirely and may sell some BTC before the end of 2026. The company plans to dynamically manage its dollar cash reserves to maximize the number of Bitcoin per share. Currently, Strategy holds approximately 843,800 BTC, with a total value of about $65 billion and an average purchase cost of around $75,700. The current Bitcoin price is approximately $76,000, close to its overall holding cost.