What a post-quantum migration is
A post-quantum migration is the project of finding every place an organisation uses public-key cryptography and moving it to post-quantum methods. It takes years, so planning it well matters more than any one command.
Picture a college with a VPN, a website, door badges and backups. Each uses cryptography, often in places nobody has written down.
By the end of this lesson
Note
I can build a cryptographic inventory and put a post-quantum migration in order of urgency.
Key words
| Word | What it means |
|---|---|
| Cryptographic inventory | a list of where and how cryptography is used |
| Crypto agility | being able to change an algorithm by changing a setting |
| Migration | moving systems from old methods to new ones |
| Urgency | how soon a system must move |
| Middlebox | a firewall or proxy that inspects traffic on the way |
The cells students fill in are left blank in this preview.
Start with a cryptographic inventory
You cannot move what you have not found. An inventory lists each system with its key exchange, signatures and certificates. It also records the shelf life of its data, its owner and whether it can be updated.
Look in configuration files, certificate stores, code libraries and suppliers' answers. Embedded devices such as door badges and meters are often the hardest to find and to change.
Worked example: part of a college's inventory
| System | Key exchange | Signature | Shelf life | Can it be updated? |
|---|---|---|---|---|
| Staff VPN | ECDH | RSA-2048 | 10 years | Yes, by the supplier |
| Public website | X25519MLKEM768 | ECDSA P-256 | None | Yes, a setting |
| Student records link | X25519 | RSA-2048 | 30 years | Yes, a setting |
| Door badges | RSA | RSA-2048 | 1 year | No, new hardware |
The cells students fill in are left blank in this preview.
Put the work in order
First, key exchange for data with a long shelf life, because recordings are being made now. Second, anything a setting can fix, such as TLS groups and SSH key exchanges. Third, certificate authorities and signatures, which must be safe before quantum computers arrive.
Last, hardware that cannot be updated. It needs replacing, so it goes in the budget early even if the work comes late.
Crypto agility makes the next change cheap
A system is crypto agile when its algorithms are a setting, not code. The lab's TLS server chooses its groups with one option, and OpenSSH chooses its key exchange with one line.
Agility matters because this will not be the last change. A flaw found in one algorithm should mean editing a list, not rewriting a program.
What signed the TLS root?
docker exec pq sh -c "openssl x509 -in /keys/tls-ca.crt -noout -text | grep -E 'Subject:|Signature Algorithm'"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
The TLS server's group and signature
docker exec pq sh -c "openssl s_client -connect tls:4433 -servername tls -CAfile /keys/tls-ca.crt -brief 2>&1 | grep -E 'group|Signature type'"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
The SSH server's key exchange and host key
docker exec pq sh -c "ssh -v sshd true 2>&1 | grep -E 'kex: algorithm|host key algorithm'"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
The old-style SSH server
docker exec pq sh -c "ssh -v legacy true 2>&1 | grep -E 'kex: algorithm|host key algorithm'"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
Your own SSH key's type
docker exec pq sh -c "ssh-keygen -l -f /keys/client.pub | grep -o ED25519"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
The TLS groups are one setting
docker exec tls sh -c "xargs -0 < /proc/1/cmdline"Shown here, not run. Press Start lab to type it into your own lab’s terminal.
The lab's own inventory
| Where | What the Run printed | Verdict |
|---|---|---|
| TLS root certificate | Signature Algorithm: ML-DSA-65, Subject: CN=Lab Root CA | Post-quantum |
| TLS server | Signature type: mldsa65, Negotiated TLS1.3 group: X25519MLKEM768 | Post-quantum |
| SSH on 2222 | kex: algorithm: mlkem768x25519-sha256, host key algorithm: ssh-ed25519 | Key exchange done, host key classical |
| SSH on 2200 | kex: algorithm: curve25519-sha256, host key algorithm: ssh-ed25519 | Urgent if its data lasts |
| Your SSH key | ED25519 | Classical signature, checked live |
| TLS server settings | openssl s_server ... -groups X25519MLKEM768:X25519:MLKEM768 -www -quiet | Agile: one option |
The cells students fill in are left blank in this preview.
The cost is bytes, not time
ML-KEM and ML-DSA are fast: each step takes well under a millisecond on a laptop. The cost is size. A hybrid ClientHello no longer fits in one network packet, and some old middleboxes dropped such handshakes.
A chain of ML-DSA certificates adds kilobytes to every new TLS connection. Test on your own network, and roll out with the classical method still allowed as a fallback.
A common mistake
Warning
Many people think migration means swapping one algorithm for another, once. It means finding every use, changing what a setting can change, replacing what it cannot, and keeping things agile. Start with the inventory, not the algorithm.
What this lab leaves out
Note
WireGuard VPNs can gain a post-quantum key with Rosenpass, which runs beside WireGuard. It needs a kernel module and network rights a lab does not have, so it is not here. Hardware security modules and smart cards are left out too.