The Quantum Threat to Bitcoin: How a Quantum Computer Can Steal Your Cryptocurrency in Under 10 Minutes

The first part of this series explored the principles of quantum computing. However, understanding the inner workings of a quantum computer does not necessarily reveal how it can be utilized to steal bitcoin. To grasp this, it's essential to comprehend what a quantum computer is attacking, the structure of bitcoin's security, and the specific vulnerability it exploits. This piece begins with an examination of bitcoin's encryption, explaining how it works and how a quantum algorithm can break it, as identified in a recent paper by Google. Bitcoin employs a system called elliptic curve cryptography to verify ownership. Each wallet has two keys: a private key, which is a secret 256-digit binary number, and a public key derived from the private key through a mathematical operation on the 'secp256k1' curve. The relationship between the private and public keys can be thought of as a one-way map, where it's easy to calculate the public key from the private key but virtually impossible for a classical computer to reverse the process. This one-way function is the foundation of bitcoin's security model, allowing users to prove ownership without revealing their private key. However, a quantum algorithm known as Shor's algorithm can efficiently break this one-way function, solving the elliptic curve discrete logarithm problem that classical computers find intractable. Shor's algorithm works by converting the problem into finding the period of a function, which quantum computers can solve efficiently by leveraging superposition, entanglement, and interference. The recent Google paper has reduced the estimated number of qubits needed to run Shor's algorithm against bitcoin's elliptic curve from millions to fewer than 500,000, significantly advancing the potential threat timeline. The paper also introduced a practical attack scenario where parts of the calculation can be precomputed, waiting for a target public key to appear. Once a public key is exposed, the quantum computer only needs about nine minutes to derive the private key, which is roughly the time it takes for a bitcoin transaction to be confirmed. This creates a 'mempool attack' scenario where an attacker has a 41% chance of redirecting funds before the original transaction is confirmed. Furthermore, approximately 6.9 million bitcoin are vulnerable to an 'at-rest' attack because their public keys have already been exposed on the blockchain, allowing an attacker to take as long as needed to derive the private key. The implications of these findings and the advancing hardware capabilities will be explored in the next piece.