Inflation Bug
A critical software flaw that allows minting more BTC than the 21 million cap (e.g., CVE-2018-17144).
An inflation bug is the most severe class of Bitcoin software vulnerability: a flaw that would let an attacker create more BTC than the protocol's 21-million-coin cap allows, by tricking validators into accepting invalid transactions or invalid coinbase outputs.
The one that actually minted coins came first. In August 2010 a value-overflow bug (CVE-2010-5139) let a single transaction create about 184 billion BTC, and the network rolled the chain back to remove it within a day. The most cited example is CVE-2018-17144, reported privately on 17 September 2018, patched on 18 September, and fully disclosed on 20 September.
What the 2018 bug was:
- A specific class of double-spend - one transaction listing the same coin as an input twice - had been a known impossibility. Bitcoin Core had checked for it during block validation since 2012.
- An optimization in Bitcoin Core 0.14.0 (2017) skipped that check, so a carefully constructed block could crash a node. A redesign in 0.15.0, later in 2017, made it worse: versions 0.15.0 through 0.16.2 would accept such a block when the coin being spent twice came from an earlier block.
- An attacker who produced such a block could double-spend an output. Iterated, this is inflation.
How it got found and fixed:
- Awemany (a developer working on Bitcoin Cash software) discovered the bug while reviewing inherited Bitcoin Core code.
- They reported it privately, as a crash bug, to developers of Bitcoin Core and two other node projects. Within three hours a Core developer had worked out that it was also an inflation bug.
- Bitcoin Core 0.16.3 shipped the fix on 18 September, the day after the report; patched releases for the two older branches followed on 28 September.
- One large mining pool had upgraded within six hours of the report. By the full disclosure on 20 September, Bitcoin Core estimated that over half of the hash rate had upgraded.
- No one is known to have exploited the bug in the wild before the fix.
Why this matters:
- Bitcoin's monetary integrity nearly broke. If exploited and not detected, the 21M cap would have been silently violated, which would have been catastrophic for trust in Bitcoin's monetary properties.
- The patch worked because the social process works. Private disclosure, fast review, fast deployment by infrastructure operators. The same coordination would be needed for any future critical bug.
- It's a reminder that "the code is the constitution" requires the code to actually be right. Bitcoin's monetary commitments depend on Bitcoin Core (and its compatible implementations) actually enforcing the rules. Subtle bugs in optimization paths can undermine the commitments.
CVE-2018-17144 remains the most cited example when developers argue for conservative changes to the validation code path, more test coverage on consensus-critical functions, and minimum review periods on optimizations.
See the Inflation Bug Postmortem rabbit hole for the full story of the 2010 overflow bug, and Bitcoin Core's disclosure for the 2018 timeline.
Key takeaways
- Threatens Bitcoin's core scarcity feature if unpatched
- Highlight of why rapid fixes and community diligence matter
- Historically rare but extremely serious vulnerability
Related chapters
Corrected
-
Was: The entry dated the disclosure of CVE-2018-17144 to 18 September 2018 and said patched releases for all supported branches shipped within 24 hours. It called the 2018 bug the canonical example without mentioning the 2010 bug that actually created coins.
Now: The bug was reported on 17 September, Bitcoin Core 0.16.3 fixed it on 18 September, full disclosure came on 20 September, and the older branches were patched on 28 September. The entry names the affected versions, 0.15.0 to 0.16.2, and opens with the August 2010 overflow bug. Details
Sources (5)
Related terms (7)
Published . Revised . One correction logged for this page.
Edit this page on GitHub