Post-Quantum Cryptography for Developers: What Changes in 2027 and What to Do Now
What post-quantum cryptography means for your code: the real 2027-2035 deadlines, hybrid TLS in Java, Node, Go and Python, and tested scripts to start now.
Post-quantum cryptography (PQC) for developers mostly means two things right now: turn on hybrid post-quantum key exchange in TLS (usually just by upgrading your runtime or OpenSSL), and build an inventory of where your code uses RSA and elliptic-curve keys so you can replace them before NIST deprecates them after 2030 and disallows them after 2035. You do not need to touch AES or SHA-256, and the much-quoted "2027 deadline" (CNSA 2.0) applies to US National Security Systems, not to ordinary apps.
Table of contents
- The short version: what to do, in order
- Why developers have to care: harvest now, decrypt later
- The real deadlines: 2027, 2030, 2035
- What changes in 2027 for Java, Node.js, Go and Python
- Test which TLS group your handshake really uses
- ML-KEM and ML-DSA in Python, with real output
- Build a crypto inventory: find quantum-vulnerable keys
- Crypto agility, pitfalls and when not to bother
- The bottom line
This guide separates the real deadlines from the hype, explains what changes in 2027 for Java, Node.js, Go and Python developers, and gives you working code: an ML-KEM and ML-DSA example in Python, a probe that shows which TLS group a handshake actually negotiated, a JDK check, and a script that finds quantum-vulnerable keys in a repository. Every code example below was run in our sandbox with the versions shown; statements about runtimes we didn't run (JDK 27, Go) come from their official documentation.
The short version: what to do, in order
| Step | What to do | Why now |
|---|---|---|
| 1 | Upgrade your TLS stack so it offers X25519MLKEM768 | Protects today's traffic from "harvest now, decrypt later" |
| 2 | Inventory RSA, ECDSA, Ed25519 and ECDH keys and certificates | You can't migrate what you can't find |
| 3 | Make algorithms configurable (crypto agility) | Swaps become config changes, not rewrites |
| 4 | Plan signature migration (ML-DSA, LMS/XMSS for firmware) | NIST: deprecated after 2030, disallowed after 2035 |
| 5 | Leave AES and SHA-2/SHA-3 alone | Symmetric crypto is not part of the transition |
Why developers have to care: harvest now, decrypt later
A large enough quantum computer running Shor's algorithm would break the public-key algorithms almost everything uses today: RSA, elliptic-curve Diffie-Hellman (ECDH), finite-field Diffie-Hellman, ECDSA and EdDSA (Ed25519). No such machine exists publicly yet, and nobody can tell you the year it will. So why act now?
Because of key exchange. An attacker can record encrypted TLS traffic today and decrypt it later once a quantum computer exists. Anything you send now that must stay secret for 10+ years (health data, credentials, source code, private messages) is already exposed to that future attack. That is why the industry fixed key exchange first.
Signatures are different. A forged signature only helps an attacker at the moment it's verified, so a future quantum computer can't retroactively forge a TLS handshake that happened in 2026. Signature migration (certificates, code signing, SSH keys) matters too, but on a slower clock.
The replacements are standardised. NIST's IR 8547 (finalised 27 October 2026) names ML-KEM (FIPS 203) for key establishment, ML-DSA (FIPS 204) and SLH-DSA (FIPS 205) for signatures, and the stateful hash-based LMS and XMSS schemes (SP 800-208) mainly for firmware and software signing. A Falcon-based signature standard and the backup KEM, HQC, are still being written.
The real deadlines: 2027, 2030, 2035
The dates you'll see online come from three different documents with three different audiences. Mixing them up is the most common mistake in PQC coverage.
| Date | What happens | Who it applies to | Source |
|---|---|---|---|
| 1 Jan 2027 | New National Security System acquisitions must be CNSA 2.0 compliant | US NSS owners and their vendors | NSA CNSA 2.0 FAQ |
| 2 Jan 2030 | Agencies must support TLS 1.3 (or a successor) | US federal civilian agencies | OMB M-26-15 |
| After 2030 | Quantum-vulnerable algorithms deprecated | Anyone following NIST / FIPS | NIST IR 8547 |
| 31 Dec 2030 | NSS equipment that can't support CNSA 2.0 phased out; agencies' goal for mitigating as much quantum risk as feasible in prioritised systems (OMB phase 3, 2028–2030) | NSS; federal agencies | NSA FAQ; OMB M-26-15 |
| 2031 (31 Dec for NSS) | PQC signatures (OMB phase 4); CNSA 2.0 algorithms mandated for NSS | Federal agencies; NSS | OMB M-26-15; NSA FAQ |
| 2035 / after 2035 | Quantum-vulnerable algorithms disallowed; OMB phase 5 (full migration); NSA goal of quantum-resistant NSS | Anyone following NIST / FIPS; agencies; NSS | NIST IR 8547; OMB M-26-15; NSA FAQ |
What this means in practice:
- CNSA 2.0 (the "2027" date) is not a general rule. The NSA FAQ says it is not dictating requirements to any entity outside National Security Systems. If you sell into US defence or intelligence, it's a hard procurement gate. If you run a SaaS app, it isn't. CNSA 2.0 is also stricter than NIST: it requires ML-KEM-1024, ML-DSA-87, AES-256 and SHA-384/512, and it does not approve SLH-DSA.
- OMB M-26-15 (24 June 2026) explicitly excludes national security systems and covers federal civilian agencies. It asks them to put PQC requirements into product procurement and to configure network terminators (firewalls, VPNs, cloud gateways, API proxies) for PQC-capable key exchange. If agencies are your customers, expect those questions in RFPs.
- NIST's 2030/2035 milestones are the broad ones. FIPS-validated products and regulated industries will follow them, and they set the long-term direction for everyone else.
- Symmetric crypto stays. IR 8547 treats AES and the SHA-2/SHA-3 families as less vulnerable to quantum attacks and keeps them out of the transition.
What changes in 2027 for Java, Node.js, Go and Python
For most developers, the practical PQC work is "make sure the runtime offers hybrid key exchange". Here's where each ecosystem stands.
| Runtime / library | Hybrid TLS (X25519MLKEM768) | ML-KEM / ML-DSA APIs |
|---|---|---|
| OpenSSL 3.5+ (Apr 2025) | On by default, preferred | Yes (also SLH-DSA) |
| Go 1.24+ | On by default when CurvePreferences is nil |
ML-KEM in crypto/mlkem |
| JDK 27 (Sep 2026) | On by default, first in the list (JEP 527) | Yes (JEPs 496, 497) |
| JDK 25 LTS | On by default since Oracle JDK 25.0.5 (20 Oct 2026) | Yes |
| JDK 21 / 17 LTS | Oracle projects H1 2027 | Oracle planned Oct 2026; present in the JDK 21.0.13 we ran |
| JDK 11 / 8 | Oracle projects H2 2027 | Oracle projects H2 2027 |
| Node.js | Follows the OpenSSL it's built with | Not in Node 22.23.5 (we tried) |
Python ssl |
Follows the linked OpenSSL | Use pyca/cryptography 48+ |
The JDK 21/17 and 11/8 dates come from Oracle's August 2026 roadmap post and are Oracle's projections for Oracle JDK; other OpenJDK distributions set their own schedules. The JDK 25 backport has shipped: the Oracle JDK 25.0.5 release notes say X25519MLKEM768 is enabled by default and is the most preferred group. Oracle stresses that offering PQC isn't the same as using it: your configuration and your peers still decide what gets negotiated. The protocol itself is standardised: the hybrid ECDHE-MLKEM draft was published as RFC 10024 in August 2026, with codepoint 0x11EC for X25519MLKEM768. In Node.js 22.23.5, crypto.generateKeyPairSync("ml-kem-768") and ("ml-dsa-65") both threw ERR_INVALID_ARG_VALUE, so use TLS or a dedicated library there.
Java: check what your JDK offers
This program prints the JDK's default TLS groups and whether the ML-KEM and ML-DSA algorithms exist:
import java.security.KeyPairGenerator;
import java.security.NoSuchAlgorithmException;
import java.util.Arrays;
import javax.net.ssl.SSLContext;
public class PqCheck {
public static void main(String[] args) throws Exception {
System.out.println("java.version = "
+ System.getProperty("java.version"));
String[] groups = SSLContext.getDefault()
.getDefaultSSLParameters().getNamedGroups();
System.out.println("default TLS named groups = "
+ Arrays.toString(groups));
System.out.println("hybrid X25519MLKEM768 enabled = "
+ Arrays.asList(groups).contains("X25519MLKEM768"));
for (String alg : new String[] {"ML-KEM", "ML-DSA"}) {
try {
KeyPairGenerator.getInstance(alg);
System.out.println(alg + " KeyPairGenerator: available");
} catch (NoSuchAlgorithmException e) {
System.out.println(alg + " KeyPairGenerator: not available");
}
}
}
}
On the JDK in our sandbox (Ubuntu's OpenJDK 21.0.13 build) the output was:
java.version = 21.0.13.1
default TLS named groups = [x25519, secp256r1, secp384r1, secp521r1, x448, ffdhe2048, ffdhe3072, ffdhe4096, ffdhe6144, ffdhe8192]
hybrid X25519MLKEM768 enabled = false
ML-KEM KeyPairGenerator: available
ML-DSA KeyPairGenerator: available
That matches Oracle's roadmap: on JDK 21 the ML-KEM and ML-DSA algorithms have arrived, but hybrid TLS hasn't yet. Setting -Djdk.tls.namedGroups=X25519MLKEM768,x25519 on this JDK simply left [x25519]: the property can't enable a group the JDK doesn't implement. On JDK 27, JEP 527 puts X25519MLKEM768 first by default, and jdk.tls.namedGroups (or SSLParameters.setNamedGroups) is how you reorder or remove it. JEP 527 covers TLS 1.3 in javax.net.ssl only; it doesn't change certificates or signatures.
ML-KEM itself already works through the standard javax.crypto.KEM API on this JDK 21 build. This is the core of the class we ran; the full version prints the ciphertext length and compares the two keys with Arrays.equals:
KeyPairGenerator g = KeyPairGenerator.getInstance("ML-KEM-768");
KeyPair receiver = g.generateKeyPair();
KEM.Encapsulated enc = KEM.getInstance("ML-KEM")
.newEncapsulator(receiver.getPublic()).encapsulate();
SecretKey k = KEM.getInstance("ML-KEM")
.newDecapsulator(receiver.getPrivate())
.decapsulate(enc.encapsulation());
// enc.key() and k hold the same 32-byte shared secret
ciphertext bytes: 1088
secrets match: true
If you work on Spring Boot services, hybrid TLS will arrive through your JDK update, so keeping up with JDK patch releases matters as much here as it did for the Java4Shell Base64 flaw.
Go
Per the Go 1.24 release notes, X25519MLKEM768 is enabled by default when Config.CurvePreferences is nil. If you set CurvePreferences yourself, add tls.X25519MLKEM768 explicitly. GODEBUG=tlsmlkem=0 turns it off, which the notes suggest for buggy servers that time out on large records. We did not run Go in this test.
Test which TLS group your handshake really uses
"We support post-quantum TLS" is easy to claim and easy to get wrong, because both sides must agree on a group. Node.js here was linked against OpenSSL 3.5.9, but tlsSocket.getEphemeralKeyInfo() returned an empty object {} for the hybrid group, so it can't tell you. This script reads the answer straight from the server's ServerHello message through a tiny local proxy. It spins up a local server and client with the groups you pass:
// Read the negotiated TLS 1.3 key-exchange group from the ServerHello.
// Usage: node tls_group_probe.mjs <serverGroups> <clientGroups>
import tls from "node:tls";
import net from "node:net";
import fs from "node:fs";
const NAMES = { 0x001d: "x25519", 0x0017: "secp256r1",
0x0018: "secp384r1", 0x11ec: "X25519MLKEM768",
0x11eb: "SecP256r1MLKEM768", 0x11ed: "SecP384r1MLKEM1024" };
const HRR_RANDOM = "cf21ad74e59a6111be1d8c021e65b891" +
"c2a211167abb8c5e079e09e2c8a8339c";
const [serverGroups, clientGroups] = process.argv.slice(2);
function serverHelloGroup(buf) {
if (buf[0] !== 0x16 || buf[5] !== 0x02) return null; // not ServerHello
// A HelloRetryRequest is a ServerHello with this fixed "random" value.
const hrr = buf.subarray(11, 43).toString("hex") === HRR_RANDOM;
let p = 5 + 4 + 2 + 32; // headers, version, random
p += 1 + buf[p]; // session id
p += 2 + 1; // cipher suite, compression
const end = p + 2 + buf.readUInt16BE(p);
for (p += 2; p < end; ) {
const type = buf.readUInt16BE(p), len = buf.readUInt16BE(p + 2);
if (type === 0x0033) { // key_share extension
return { group: buf.readUInt16BE(p + 4), hrr };
}
p += 4 + len;
}
return null;
}
const server = tls.createServer({
key: fs.readFileSync("key.pem"), cert: fs.readFileSync("cert.pem"),
minVersion: "TLSv1.3", ecdhCurve: serverGroups,
}, (s) => s.end());
server.listen(0, () => {
// A tiny TCP proxy between client and server that peeks at bytes.
const proxy = net.createServer((c) => {
const up = net.connect(server.address().port, "127.0.0.1");
c.pipe(up);
let first = true;
up.on("data", (d) => {
if (first) {
first = false;
const r = serverHelloGroup(d);
const name = r && (NAMES[r.group] ?? "0x" + r.group.toString(16));
console.log(`server=${serverGroups} client=${clientGroups}`);
console.log(` negotiated: ${name ?? "none"}` +
(r?.hrr ? " (after HelloRetryRequest: extra round trip)" : ""));
}
c.write(d);
});
c.on("close", () => up.destroy());
}).listen(0, () => {
const s = tls.connect({ port: proxy.address().port, host: "localhost",
ca: fs.readFileSync("cert.pem"), ecdhCurve: clientGroups }, () => {
s.end(); proxy.close(); server.close();
});
s.on("error", (e) => { console.log(" error:", e.code); process.exit(); });
});
});
Create a throwaway certificate (an ordinary ECDSA P-256 one) and run five scenarios:
openssl req -x509 -newkey ec -pkeyopt ec_paramgen_curve:P-256 -nodes \
-keyout key.pem -out cert.pem -days 2 -subj /CN=localhost
node tls_group_probe.mjs auto auto
node tls_group_probe.mjs X25519 auto
node tls_group_probe.mjs X25519 "X25519MLKEM768:X25519"
node tls_group_probe.mjs X25519 "*X25519MLKEM768:*X25519"
node tls_group_probe.mjs X25519MLKEM768 X25519
Output with Node.js v22.23.5 (OpenSSL 3.5.9):
server=auto client=auto
negotiated: X25519MLKEM768
server=X25519 client=auto
negotiated: x25519
server=X25519 client=X25519MLKEM768:X25519
negotiated: x25519 (after HelloRetryRequest: extra round trip)
server=X25519 client=*X25519MLKEM768:*X25519
negotiated: x25519
server=X25519MLKEM768 client=X25519
negotiated: none
error: ERR_SSL_SSL/TLS_ALERT_HANDSHAKE_FAILURE
Four lessons from this run:
- Defaults already do the right thing. With Node's
autosetting on OpenSSL 3.5, both sides picked X25519MLKEM768, and a classical-only server still connected without trouble. A normal P-256 certificate was fine, so you don't need a post-quantum certificate to get post-quantum key exchange. - Hand-written group lists can cost a round trip. Listing
X25519MLKEM768:X25519made the client send a key share for the first group only, so a classical server answered with a HelloRetryRequest. OpenSSL's*prefix (*X25519MLKEM768:*X25519) sends key shares for both and avoids it. This matches OpenSSL 3.5's documented default of offering X25519MLKEM768 and X25519 key shares. - Hybrid-only servers break old clients. A server that accepts only X25519MLKEM768 failed the handshake with a classical-only client. Keep a classical fallback group on public endpoints.
- The hybrid key shares are big. The ML-KEM-768 part is 1,184 bytes from the client and 1,088 bytes from the server, compared with 32 bytes for X25519. A ClientHello that grows past one packet can upset old middleboxes and badly written TLS servers; Go's release notes mention this exact failure. Test through your real load balancers and proxies.
ML-KEM and ML-DSA in Python, with real output
For application-level crypto (encrypting a file key, signing a release), pyca/cryptography now exposes both algorithms. Version matters. We installed three versions from PyPI on Linux x86-64 and tried to generate an ML-KEM-768 key:
46.0.7 ImportError: cannot import name 'mlkem'
47.0.0 UnsupportedAlgorithm: ML-KEM-768 is not supported by this backend.
48.0.0 mlkem ok, mldsa ok
That fits the changelog: 47.0.0 added the modules for AWS-LC and BoringSSL builds only, and 48.0.0 added support with OpenSSL 3.5 or later, and the PyPI wheels bundle OpenSSL 4.0.x, which qualifies. So pin cryptography>=48 (inside a virtual environment):
"""ML-KEM-768 and ML-DSA-65 with pyca/cryptography (needs 48.0+)."""
import cryptography
from cryptography.hazmat.primitives import hashes, serialization
from cryptography.hazmat.primitives.asymmetric import (
ec, ed25519, mldsa, mlkem, rsa, x25519,
)
from cryptography.hazmat.primitives.kdf.hkdf import HKDF
RAW = serialization.Encoding.Raw
RAW_PUB = serialization.PublicFormat.Raw
DER = serialization.Encoding.DER
SPKI = serialization.PublicFormat.SubjectPublicKeyInfo
print("cryptography", cryptography.__version__)
# 1) ML-KEM-768: a key encapsulation mechanism (FIPS 203)
receiver = mlkem.MLKEM768PrivateKey.generate()
receiver_pub = receiver.public_key()
secret_sender, ciphertext = receiver_pub.encapsulate() # sender side
secret_receiver = receiver.decapsulate(ciphertext) # receiver side
print("ML-KEM-768 secrets match:", secret_sender == secret_receiver)
print(" public key:", len(receiver_pub.public_bytes(RAW, RAW_PUB)), "bytes")
print(" ciphertext:", len(ciphertext), "bytes")
print(" shared secret:", len(secret_sender), "bytes")
# 2) Hybrid idea: X25519 + ML-KEM-768, combined with a KDF.
# Illustration only; TLS 1.3 uses its own combiner and key schedule.
a, b = x25519.X25519PrivateKey.generate(), x25519.X25519PrivateKey.generate()
ecdh_secret = a.exchange(b.public_key())
hybrid_key = HKDF(
algorithm=hashes.SHA256(), length=32, salt=None,
info=b"demo hybrid x25519+mlkem768",
).derive(secret_sender + ecdh_secret)
print("Hybrid key derived:", len(hybrid_key), "bytes")
# 3) ML-DSA-65: post-quantum signatures (FIPS 204)
signer = mldsa.MLDSA65PrivateKey.generate()
message = b"release-1.4.2.tar.gz sha256=..."
signature = signer.sign(message)
signer.public_key().verify(signature, message) # raises if invalid
print("ML-DSA-65 signature verified")
try:
signer.public_key().verify(signature, message + b"tampered")
except Exception as exc: # InvalidSignature
print(" tampered message rejected:", type(exc).__name__)
# 4) Size comparison: public key and signature, in bytes
def row(name, pub_len, sig_len):
print(f" {name:<12} public key {pub_len:>5} signature {sig_len:>5}")
print("Signature sizes:")
k = ed25519.Ed25519PrivateKey.generate()
row("Ed25519", len(k.public_key().public_bytes(RAW, RAW_PUB)),
len(k.sign(message)))
k = ec.generate_private_key(ec.SECP256R1())
row("ECDSA P-256", len(k.public_key().public_bytes(DER, SPKI)),
len(k.sign(message, ec.ECDSA(hashes.SHA256()))))
k = rsa.generate_private_key(public_exponent=65537, key_size=3072)
from cryptography.hazmat.primitives.asymmetric import padding
row("RSA-3072", len(k.public_key().public_bytes(DER, SPKI)),
len(k.sign(message, padding.PKCS1v15(), hashes.SHA256())))
row("ML-DSA-65", len(signer.public_key().public_bytes(RAW, RAW_PUB)),
len(signature))
Output with Python 3.13.18 and cryptography 50.0.2:
cryptography 50.0.2
ML-KEM-768 secrets match: True
public key: 1184 bytes
ciphertext: 1088 bytes
shared secret: 32 bytes
Hybrid key derived: 32 bytes
ML-DSA-65 signature verified
tampered message rejected: InvalidSignature
Signature sizes:
Ed25519 public key 32 signature 64
ECDSA P-256 public key 91 signature 72
RSA-3072 public key 422 signature 384
ML-DSA-65 public key 1952 signature 3309
(ECDSA and RSA public keys are DER-encoded SubjectPublicKeyInfo sizes; Ed25519 and ML-DSA are raw. ECDSA's DER signature length varies by a byte or two between runs.)
Two takeaways. First, the API looks like any other KEM: the sender calls encapsulate() on a public key and gets a shared secret plus a ciphertext to send; the receiver calls decapsulate(). Unlike Diffie-Hellman, there's no "exchange" with your own private key. Second, post-quantum signatures are about 50 times larger than Ed25519's. That matters for JWTs, certificate chains, signed URLs, QR codes and anything with a size limit. Check your size budgets before you plan to switch tokens or certificates to ML-DSA. Also remember what a KEM does not do: ML-KEM only establishes a shared secret. You still encrypt the data with a symmetric cipher such as AES-GCM, and ML-KEM doesn't prove who you're talking to; authentication is the signature's job.
The HKDF combiner in the snippet only illustrates the hybrid idea. Don't invent your own hybrid protocol for production: TLS defines exactly how it concatenates the two secrets, and for most needs you should use TLS, or a library's standard hybrid construction, rather than a custom one.
Build a crypto inventory: find quantum-vulnerable keys
Every official migration plan starts with an inventory, and OMB M-26-15 makes inventory phase one for agencies. For a developer, the cheapest version is scanning your repositories, config directories and deployment bundles for keys and certificates. This script finds PEM and OpenSSH key blocks and labels each one:
"""Find PEM keys and certificates and flag quantum-vulnerable ones.
Usage: python pq_inventory.py <directory>
"""
import pathlib
import re
import sys
from cryptography import x509
from cryptography.hazmat.primitives import serialization
from cryptography.hazmat.primitives.asymmetric import (
dsa, ec, ed448, ed25519, mldsa, mlkem, rsa, x448, x25519,
)
PEM_BLOCK = re.compile(
rb"-----BEGIN ([A-Z0-9 ]+)-----.+?-----END \1-----", re.S)
VULNERABLE = (rsa.RSAPublicKey, ec.EllipticCurvePublicKey,
dsa.DSAPublicKey, ed25519.Ed25519PublicKey,
ed448.Ed448PublicKey, x25519.X25519PublicKey,
x448.X448PublicKey)
PQC = tuple(getattr(m, n) for m in (mldsa, mlkem)
for n in dir(m) if n.endswith("PublicKey"))
def describe(pub):
if isinstance(pub, rsa.RSAPublicKey):
return f"RSA-{pub.key_size}"
if isinstance(pub, ec.EllipticCurvePublicKey):
return f"EC {pub.curve.name}"
return type(pub).__name__.lstrip("_").replace("PublicKey", "")
def load_public_key(label, block):
if label == "CERTIFICATE":
cert = x509.load_pem_x509_certificate(block)
expiry = f" expires {cert.not_valid_after_utc:%Y-%m-%d}"
return cert.public_key(), expiry
if label == "PUBLIC KEY":
return serialization.load_pem_public_key(block), ""
if label == "OPENSSH PRIVATE KEY":
key = serialization.load_ssh_private_key(block, password=None)
return key.public_key(), ""
if "PRIVATE KEY" in label and "ENCRYPTED" not in label:
key = serialization.load_pem_private_key(block, password=None)
return key.public_key(), ""
return None, ""
def main(root):
for path in sorted(pathlib.Path(root).rglob("*")):
if not path.is_file() or path.stat().st_size > 1_000_000:
continue
for m in PEM_BLOCK.finditer(path.read_bytes()):
label = m.group(1).decode()
try:
pub, extra = load_public_key(label, m.group(0))
except Exception as exc:
print(f"{path}: {label}: could not parse ({exc})")
continue
if pub is None:
print(f"{path}: {label}: skipped (encrypted or unknown)")
continue
if isinstance(pub, VULNERABLE):
status = "QUANTUM-VULNERABLE"
elif isinstance(pub, PQC):
status = "post-quantum"
else:
status = "unknown"
print(f"{path}: {label}: {describe(pub)}{extra} -> {status}")
if __name__ == "__main__":
main(sys.argv[1] if len(sys.argv) > 1 else ".")
Against a test folder with an RSA certificate, EC keys, an Ed25519 SSH key and an ML-DSA public key, it printed:
.ssh/id_ed25519: OPENSSH PRIVATE KEY: Ed25519 -> QUANTUM-VULNERABLE
ec.key: EC PRIVATE KEY: EC secp256r1 -> QUANTUM-VULNERABLE
ec.pub: PUBLIC KEY: EC secp256r1 -> QUANTUM-VULNERABLE
mldsa.pub: PUBLIC KEY: MLDSA65 -> post-quantum
rsa.crt: CERTIFICATE: RSA-2048 expires 2027-11-27 -> QUANTUM-VULNERABLE
rsa.key: PRIVATE KEY: RSA-2048 -> QUANTUM-VULNERABLE
Yes, your Ed25519 SSH key is on the list. That's expected and not an emergency: it's a signature key, so recorded traffic doesn't put it at risk, and it remains the right choice today (see our SSH keys guide). The same reasoning applies to passkeys and FIDO2 security keys, which use elliptic-curve signatures today (how passkeys work); their migration depends on the WebAuthn ecosystem, not on your code.
The script has limits. It only sees keys stored as files. Passphrase-protected keys are reported as "skipped" or "could not parse" rather than classified. It won't find keys in cloud KMS or HSMs, keys embedded in binaries, or algorithm names hard-coded in source. For those, also grep your code for RSA, ECDSA, secp256r1, ECDH, KeyPairGenerator and ssl_ciphers or ecdh_curve in server configs, and ask your cloud provider for its KMS key list.
Crypto agility, pitfalls and when not to bother
Make algorithms configuration, not code. OMB M-26-15 asks agencies to make all systems cryptographically agile, and that's good advice for everyone. Concretely: don't hard-code "SHA256withRSA" or a curve name deep in business logic; put algorithm choices in one module or config file; version your token and ciphertext formats so a new algorithm can coexist with the old one during a rollover.
Pitfalls we'd watch for:
- Pinning group lists in config. An nginx
ssl_ecdh_curve, a Javajdk.tls.namedGroupsor GoCurvePreferencesset years ago can silently block the hybrid group even after you upgrade. Audit these settings when you patch. If you run nginx, the upgrade itself matters too (recent nginx patches). - Only half the path is upgraded. TLS is per hop. If your CDN negotiates X25519MLKEM768 with browsers but talks classical TLS to your origin, the second hop is still exposed to recording.
- Treating "PQ-ready" as a checkbox. A vendor saying "PQC-ready" may mean "will support it later". Ask which groups their endpoints negotiate today, then verify it yourself.
- Rolling your own. Use the standard algorithms from maintained libraries. The PQC algorithms are new in production, and implementation bugs are the more realistic near-term risk. The OWASP Post-Quantum Cryptography Cheat Sheet is a good checklist for the rest.
When it can wait: if your data has a short shelf life (public content, session data that's worthless next week), and you're on a maintained runtime that already defaults to hybrid key exchange, there's little to do beyond keeping it patched and not overriding the defaults. Signatures, certificates and tokens can follow the 2030 timeline as standards and tooling mature. Don't replace AES-256 or SHA-256 because of quantum headlines.
The bottom line
Post-quantum cryptography in 2027 is mostly an upgrade-and-inventory job for developers, not a rewrite. Get hybrid X25519MLKEM768 into every TLS hop you control (OpenSSL 3.5+, Go 1.24+, JDK 27, Oracle JDK 25.0.5+, and JDK 21/17 when Oracle's backports land), use our probe to check what's actually negotiated, run an inventory of RSA and elliptic-curve keys, and make algorithm choices configurable. Ignore the "encryption breaks in 2027" headlines: 2027 is a procurement date for US national security systems, while NIST's broad deadlines are 2030 for deprecation and 2035 for disallowance. For other security basics worth doing today, start with phishing-resistant two-factor authentication.
Frequently asked questions
+Do I need to switch to post-quantum cryptography now?
For TLS key exchange, you should start now, mostly by upgrading: recent OpenSSL, Go, Node.js and JDK releases already offer the hybrid X25519MLKEM768 group, which protects recorded traffic against future quantum decryption. Signatures and certificates are less urgent and follow later, with NIST planning to deprecate quantum-vulnerable algorithms after 2030 and disallow them after 2035.
+Does the January 1, 2027 CNSA 2.0 deadline apply to my web app?
Almost certainly not. CNSA 2.0 is the NSA's algorithm suite for US National Security Systems. From January 1, 2027, new acquisitions for those systems must be CNSA 2.0 compliant. It matters if you sell products into that market; it is not a rule for ordinary websites or apps.
+Do I need to replace AES and SHA-256 because of quantum computers?
No. NIST's IR 8547 leaves its symmetric standards out of the post-quantum transition, because they are less vulnerable to quantum attacks. AES with 128-bit or larger keys and SHA-2/SHA-3 stay in place. The algorithms being replaced are public-key ones: RSA, elliptic-curve and finite-field Diffie-Hellman, ECDSA and EdDSA.
+What is X25519MLKEM768?
It is a hybrid TLS 1.3 key-exchange group that runs classic X25519 and the post-quantum ML-KEM-768 together and combines both shared secrets. An attacker has to break both to recover the session key. It is the default first choice in OpenSSL 3.5+, Go 1.24+, JDK 27 and Oracle JDK 25.0.5+.
+Do I need a post-quantum certificate to use hybrid TLS?
No. Hybrid key exchange works with your existing RSA or ECDSA certificate; in the test in this article the server used an ordinary P-256 certificate. The certificate (signature) side of the migration is a separate, later step.
+Which Python library supports ML-KEM and ML-DSA?
pyca/cryptography. Its changelog shows ML-KEM and ML-DSA modules arriving in 47.0.0 for AWS-LC and BoringSSL builds, and support with OpenSSL 3.5 or later (the PyPI wheels bundle OpenSSL 4.0.x) in 48.0.0. In our test on Linux x86-64, 47.0.0 imported the modules but raised UnsupportedAlgorithm, while 48.0.0 and 50.0.2 worked.
Sources & references
- NIST — IR 8547, Transition to Post-Quantum Cryptography Standards (final, October 2026)
- NSA — CNSA 2.0 FAQ (version 2.1, December 2024)
- OMB — M-26-15, Execution of the Migration to Post-Quantum Cryptography (June 2026)
- OpenJDK — JEP 527: Post-Quantum Hybrid Key Exchange for TLS 1.3
- Oracle Java blog — Post-Quantum Cryptography in Long-Term Support JDK Releases (August 2026)
- Oracle — Oracle Releases Java 27 (September 15, 2026)
- IETF — RFC 10024, hybrid ECDHE-MLKEM key agreement for TLS 1.3 (formerly draft-ietf-tls-ecdhe-mlkem)
- OpenSSL — 3.5 series release notes
- Go — Go 1.24 release notes (crypto/tls)
- Oracle — JDK 25.0.5 release notes (October 20, 2026)
- OWASP — Post-Quantum Cryptography Cheat Sheet
- pyca/cryptography — Changelog
Spotted an error? See our Corrections Policy.
- #post-quantum-cryptography
- #pqc
- #ml-kem
- #ml-dsa
- #tls
- #java
- #python
- #nodejs
- #cryptography
Dipak SuryawanshiFounder & Editor
Dipak Suryawanshi is a backend developer who works with Java and Spring Boot, focused on building APIs, clean architectures and developer tools. He founded KernelBrief, an independent technology publication based in India, sets its editorial direction and is responsible for everything published on it. Every KernelBrief article is researched and checked against primary sources such as official documentation, vendor advisories and release notes before it is published.
Related articles
MONAI Label 0.8.6 Patches CVE-2026-133968, the Zero-Day AI Agents Exploited: Who Is Affected and How to Update
MONAI Label 0.8.6 is out with the fix for CVE-2026-133968, a path traversal zero-day that attackers' AI agents used to get root. Who is affected and what to do.
· 6 min read
Java4Shell (CVE-2026-114938): The OpenJDK Base64 Bug Explained, Who Is Affected and How to Patch
Java4Shell is a critical OpenJDK Base64 decoder bug on AVX-512 x86-64 CPUs. Affected Java versions, fixed builds, the JVM flag workaround and how to check.
· 6 min read
LiteLLM Flaw CVE-2026-40217 Is Being Exploited in LLMjacking Attacks: Who Is Affected and How to Patch
CISA added LiteLLM flaw CVE-2026-40217 to its exploited list. Affected versions, why it matters for LLMjacking, and how to patch and rotate keys.
· 7 min read