On December 3, 2026, Bitcoin dropped about 6% to roughly $56K after the NSA told US national security systems to speed up their move to post-quantum cryptography. A lot of the panic boiled down to one question: if quantum computers can break elliptic curve keys, which bitcoin is actually at risk?
The plain-language market story is here: Bitcoin Quantum Scare: NSA Warning Hits BTC at $56K. This post is the developer version. It is less about the headline and more about a property you can check yourself: has this address already revealed its public key on-chain?
The short version of the threat
- Bitcoin signs spends with ECDSA or Schnorr over secp256k1. A large enough quantum computer running Shor's algorithm could recover a private key from a public key.
- SHA-256 and RIPEMD-160 (used for mining and for hashing addresses) are only weakened, not broken, by known quantum algorithms.
- So coins are mainly exposed when their public key is already visible. Coins sitting behind a hash that has never been spent from only reveal the key at spend time.
No one has publicly shown a machine that can do this today, and the US joint statement said recent advances "do not present an immediate and widespread threat." But exposure is a data question, and data questions are fun to script.
Which output types show the key?
| Output type | Address looks like | What is on-chain before a spend | Key visible? |
|---|---|---|---|
| P2PK (very old) | no standard address | the raw public key | Yes, always |
| P2PKH | 1... |
HASH160 of the key | Only after first spend |
| P2SH | 3... |
hash of the script | Only after first spend |
| P2WPKH |
bc1q... (42 chars) |
HASH160 of the key | Only after first spend |
| P2WSH |
bc1q... (62 chars) |
SHA-256 of the script | Only after first spend |
| P2TR (Taproot) | bc1p... |
the (tweaked) public key itself | Yes, always |
The practical takeaway: address reuse is what turns "hidden" into "exposed." Once you spend from an address, its key (or script with keys) is in the blockchain forever. If more coins later land on that same address, they sit behind a public key.
A stdlib Python check
This script classifies an address by format and asks the public mempool.space API whether it has ever been spent from and what is left on it. No API key, no dependencies.
#!/usr/bin/env python3
"""quantum_exposure.py: which Bitcoin addresses already reveal a public key?
Stdlib only. Uses the public mempool.space REST API (no key needed).
"""
import json
import sys
import urllib.request
API = "https://mempool.space/api/address/"
def address_type(addr: str) -> str:
a = addr.lower()
if a.startswith("bc1p"):
return "P2TR" # Taproot: the output itself holds a (tweaked) public key
if a.startswith("bc1q"):
return "P2WPKH" if len(a) == 42 else "P2WSH"
if addr.startswith("1"):
return "P2PKH"
if addr.startswith("3"):
return "P2SH"
return "unknown"
def fetch_stats(addr: str) -> dict:
req = urllib.request.Request(API + addr, headers={"User-Agent": "quantum-exposure-check/0.1"})
with urllib.request.urlopen(req, timeout=20) as r:
data = json.load(r)
return data["chain_stats"]
def assess(addr: str) -> dict:
kind = address_type(addr)
s = fetch_stats(addr)
balance_btc = (s["funded_txo_sum"] - s["spent_txo_sum"]) / 1e8
has_spent = s["spent_txo_count"] > 0
if kind == "P2TR":
verdict = "EXPOSED: Taproot outputs carry the public key on-chain"
elif kind == "unknown":
verdict = "UNKNOWN address format"
elif has_spent and balance_btc > 0:
verdict = "EXPOSED: key or script already revealed by a spend, and coins still sit here (address reuse)"
elif has_spent:
verdict = "REVEALED but empty: key is public, nothing left to steal"
else:
verdict = "HIDDEN: only a hash is on-chain until the first spend"
return {"address": addr, "type": kind, "spends": s["spent_txo_count"],
"balance_btc": round(balance_btc, 8), "verdict": verdict}
if __name__ == "__main__":
for addr in sys.argv[1:]:
r = assess(addr)
print(f"{r['address'][:20]}... {r['type']:<6} spends={r['spends']:<6} "
f"balance={r['balance_btc']:.8f} BTC\n -> {r['verdict']}")
I ran it on December 3, 2026 against four public addresses: the famous genesis-block address, a large reused P2SH address, a Taproot example address, and a reused SegWit address:
1A1zP1eP5QGefi2DMPTf... P2PKH spends=0 balance=57.72252135 BTC
-> HIDDEN: only a hash is on-chain until the first spend
34xp4vRoCGJym3xR7yCV... P2SH spends=451 balance=248597.59320425 BTC
-> EXPOSED: key or script already revealed by a spend, and coins still sit here (address reuse)
bc1p5d7rjq7g6rdk2yhz... P2TR spends=0 balance=0.00265092 BTC
-> EXPOSED: Taproot outputs carry the public key on-chain
bc1qar0srrr7xfkvy5l6... P2WPKH spends=1 balance=0.18269271 BTC
-> EXPOSED: key or script already revealed by a spend, and coins still sit here (address reuse)
Balances will have changed by the time you run it.
Caveats worth knowing
- This is a heuristic, not an audit. For P2SH and P2WSH, a spend reveals the script. If it is a multisig, the keys inside are now public.
-
The genesis 50 BTC is P2PK. The address
1A1zP1...above shows "hidden" because nobody has spent from it, but the original genesis coinbase output pays a raw public key (P2PK), so that key was never behind a hash. Early mined P2PK coins are the classic "exposed forever" bucket. - Mempool exposure. Even a fresh address reveals its key when you broadcast a spend. A fast enough attacker could in theory race that transaction. That is a different, much harder attack than cracking old exposed keys.
- Fixes are in progress. The draft BIP-360 proposes a new output type designed to resist long-exposure quantum attacks. Any change to Bitcoin itself needs broad agreement and usually takes years.
What this means if you build wallets
- Never reuse receive addresses. Derive a fresh one per payment (BIP-32/44/84 wallets do this by default). Our plain-language guide to crypto wallet addresses covers why.
- Send change to new addresses, not back to the input address.
- Do not ship "quantum-safe migration" flows that ask for a seed phrase. Headlines like this one are a gift to phishers. Nothing legitimate needs a user's seed phrase typed into a website.
- Separate today's risks from tomorrow's. Malware, phishing and bad key handling are far more likely to lose coins this year. Cold storage still matters: see hot wallet vs cold wallet and self-custody explained.
If you trade instead of build, news-driven drops like this one hit leveraged positions first. How crypto liquidation works and the Bitcoin price drop tracker give the market side.
This article is for education only and is not financial advice. Crypto assets are volatile and you can lose money.
I wrote this with help from AI tools. The script was run and checked by hand before publishing.
Top comments (0)