Janzeer blog ยท
How Janzeer will protect accounts from quantum computers
Which accounts are exposed, which are not, and the design we have chosen: the address stays, the key behind it changes, and nobody writes down new words. A plan, not a release.
Quantum computers are back in every crypto conversation. Most of what is said is either "everything is broken" or "nothing will ever happen". Neither helps a person who holds coins. This article says exactly what a quantum computer could do to a Janzeer account, what it could not do, and what we have designed against it.
One thing first, so nobody reads more into this than is here: this is a design, not a release. Nothing described below is live on mainnet today. We publish the plan now because a plan can be checked and criticised, and a slogan cannot.
What breaks and what does not
A blockchain uses two kinds of cryptography, and a quantum computer treats them very differently.
Hashes hold. Transaction hashes, block hashes, the state root and the address itself are made with SHA-256 and Keccak-256. The best known quantum attack on a hash is a faster search, and it leaves a 256-bit hash with about 128 bits of strength. That is not a practical attack.
Signatures do not hold. Janzeer signs transactions with ECDSA on the secp256k1 curve, like most chains. A large enough quantum computer can compute the private key from the public key. Nobody has such a machine today, and nobody can honestly say when one will exist. The planning horizon we use is the one NIST published: move away from elliptic-curve signatures after 2030, and stop using them after 2035.
So the question for an account is simple: is its public key known?
Which accounts are exposed
A Janzeer address is the first 20 bytes of the Keccak-256 hash of the public key. The address is public; the key behind it is not, until the account sends its first transaction. Every transaction carries the sender's public key, so that everyone can check the signature.
- An account that has only received coins has never shown its key. A quantum computer has nothing to work on. It is protected by the hash.
- An account that has sent at least one transaction has shown its key, and it stays on the chain for good. Janzeer accounts are reused (one address, a counter that goes up), so in practice this is every active account.
- The treasury, which holds the coins that pay block rewards, has no key at all. Nothing can be computed for it.
There is one piece of good news in this. With encryption, an attacker can record traffic today and decrypt it years later. Signatures are different: an old signature is worth nothing to an attacker until the day the key can be computed, and on that day it is worth something only if the account still depends on that key. An account that has moved to a new kind of key in time is safe. That is what makes a migration possible, and it is why the mechanism has to exist years before it is needed.
The design: the address stays, the key changes
Everything a person owns on the chain hangs on the address: the balance, the tokens, the history, the QR code they gave to a customer. A migration that asks people to move all of it to a new address would lose coins to typing mistakes and would break every saved address. So we do not move anything.
- A new signature type. Transactions get a field that says which signature scheme signed them. Today there is one. The second will be ML-DSA, the lattice-based signature that NIST standardised as FIPS 204 in August 2024.
- One transaction to switch. The owner sends a "bind key" transaction: from now on this account is controlled by this new key. It is signed with the account's current key, and it also carries a signature made with the new key, so that a mistake cannot lock the account for ever.
- After that, the old key is dead. The account accepts only the new signature. If someone computes the old private key ten years later, it opens nothing.
- New accounts can start protected. An account created with the new key type never has an elliptic-curve key. Its address will be 32 bytes long instead of 20, because a short address is itself a weakness against a quantum search.
No new words to write down
The part we care about most is the one the user sees. A person who wrote down 12 or 24 words should not be asked to write down another set.
ML-DSA builds a key from a 32-byte seed. We derive that seed from the same wallet seed the words already produce. One phrase restores both keys, the old and the new. In the wallet, the whole migration is one button, "Protect this account", a fee, and a confirmation.
What it costs
A post-quantum signature is large. These are the numbers:
| Today (ECDSA) | ML-DSA-44 | ML-DSA-65 | |
|---|---|---|---|
| Public key | 33 bytes | 1,312 bytes | 1,952 bytes |
| Signature | about 71 bytes | 2,420 bytes | 3,309 bytes |
A transfer grows from a few hundred bytes to about three kilobytes. To keep it there, the node will store an account's new public key once, and later transactions will carry only the signature. We lean towards the larger of the two parameter sets: a key bound to an account has to hold for decades, and a second migration would cost every user far more than the extra bytes.
There is a second cost, and it is not bytes. This is a change to the rules every node checks. It touches the node, five SDKs, three wallets and the command-line client, and they must agree byte for byte. We will not hurry that.
What is not solved yet
We would rather list these than have someone else find them.
- The validators. Blocks and votes are signed with the same kind of key. The same change is needed there, and it has a different problem: a large signature on every block, on validators that run on small boards at home. That gets its own design.
- The libraries. ML-DSA is available in mature libraries for Java, TypeScript, Go and Python. For Dart, which our mobile wallet uses, the choice is thin today. So the first thing we will build is not node code but test vectors: the same key and the same signature from five languages. If one language cannot match, we stop there.
- Accounts that never migrate. One day elliptic-curve signatures will be judged unsafe, and some accounts will still use them. Freeze them, or leave them open to whoever has the machine? We have not decided, and it should not be decided by us alone.
Where it stands
- The design is written.
- Decided: the address stays; new post-quantum accounts get a 32-byte address; no new backup words.
- Not decided: the parameter set, and the policy for accounts that never migrate.
- Not built: all of it. There is no date, and we will not give one until the test vectors pass in every SDK.
If you see a mistake in this design, we want to hear it before we write the code: github.com/janzeerOrg.
New to Janzeer? The wallet has a short quiz that explains the chain in five questions: https://t.me/janzeerwallet_bot/wallet?startapp=quiz_pq