The Quantum Threat to Bitcoin: How Your Cryptocurrency Could Be Stolen in Under 10 Minutes
The first part of this series explored the fundamentals of quantum computing, but understanding how it can be utilized to steal bitcoin requires knowledge of what it's targeting and the weaknesses within bitcoin's security. This piece begins with an examination of bitcoin's encryption and progresses to the nine-minute window, as identified by Google's recent quantum computing paper, that it takes to break it. Bitcoin relies on elliptic curve cryptography, which involves a private key and a public key derived from it through a mathematical operation on a specific curve called 'secp256k1'. This process can be thought of as a one-way map, where starting from a known location, taking a certain number of steps defined by the curve's math leads to a public key, but reversing this process to find the private key is virtually impossible for classical computers. However, Shor's algorithm, a quantum algorithm discovered in 1994, can efficiently solve the discrete logarithm problem that underlies this one-way function. The algorithm works by converting the problem into finding the period of a function, which is then solved using quantum properties such as superposition, entanglement, and interference. Despite Shor's algorithm being known for over 30 years, its application has been hindered by the requirement for a large number of stable qubits. Recent estimates by Google have significantly reduced the number of qubits needed, making the threat more tangible. The team designed quantum circuits that implement Shor's algorithm against bitcoin's elliptic curve, requiring fewer than 500,000 physical qubits. This development introduces a practical attack scenario, where parts of the algorithm can be precomputed, leaving a quantum computer in a primed state, ready to finish the calculation once a target public key appears. Google estimates this could take about nine minutes, which is close to bitcoin's average block confirmation time, giving an attacker a roughly 41% chance of succeeding in a 'mempool attack'. Moreover, approximately 6.9 million bitcoin are vulnerable to an 'at-rest' attack, as their public keys have been exposed on the blockchain. These developments underscore the growing urgency of the quantum threat to bitcoin's security.