Post-Quantum Cryptography: The NSA Is Pushing, and AI Is Doing the Math

Post-Quantum Cryptography: The NSA Is Pushing, and AI Is Doing the Math

An intelligence agency publicly urging haste is a rare thing. On December 2, 2026, the NSA told the owners, operators and vendors of US government systems to “immediately accelerate” their move to post-quantum cryptography. That same day, Amazon, Anthropic, Apple, Cloudflare, Google, Microsoft, OpenAI and Oracle published a joint statement backing that line. What is new about the warning is the reasoning behind it. It is no longer only about quantum computers, but about discoveries made by AI models.

The agencies do not say what exactly was found. Part of it is public, though, and it is more revealing than the “AI cracks encryption” headlines. It does not concern RSA at all, but precisely the new schemes meant to replace RSA. Why the move is still the right one has to do with quantum computers, with intercepted data and with a branch of mathematics that models are now working on too. Whether your own machine and your own servers are already on board can be checked with a handful of commands.

The warning in its own words

The NSA press release is addressed to “National Security Systems (NSS) owners, operators, and vendors”, not to the general public. Its central passage reads:

Frontier SI companies have engaged with the U.S. government to responsibly disclose recent discoveries that impact the security of some cryptographic systems currently in use. This threat, alongside the existing concerns about quantum computing, presents a significant threat to cryptographic systems protecting sensitive information.

In the joint statement from the US agencies (see below), “SI” stands for “Super Intelligence”. It refers to the major AI labs. Which schemes are affected and what the models found is stated nowhere. Instead, the NSA lists measures. Operators are to inventory their cryptographic dependencies, prioritize quantum-resistant firmware signatures and hardware roots of trust (keys anchored in the chip that protect things like the boot process), require CNSA 2.0, the NSA’s algorithm suite for cryptography in government systems, in every procurement, and build systems so that algorithms can be swapped out later. One sentence targets data that is already in transit today: “Adversaries are already collecting encrypted information to decrypt once the capabilities become available.”

On the same day, the White House Office of the National Cyber Director, the NSA and the US cybersecurity agency CISA issued a joint statement. It reassures and pushes at the same time. The current assessment, it says, is that the advances “do not present an immediate and widespread threat to that cryptography”. It also points to Executive Order 14412 (“Securing the Nation Against Advanced Cryptographic Attacks”), which President Trump signed in June to speed up the move to post-quantum cryptography across US federal agencies.

The statement from the eight companies is short. They support the recommendation to move to the algorithms in the NIST standards and want to accelerate the migration “as soon as possible”. Cloudflare has, by its own account, moved its target for converting its entire network to post-quantum schemes forward from 2029 to 2027.

A quantum attack on lattices, found by a language model

What is publicly known is a release from November 30. Anthropic published four mathematical papers on lattice problems together with a machine-checkable formalization in the proof language Lean 4. The repository states: “The results were discovered by an internal research Claude model. The formalization was written by AI models.” So an AI model found the results, and AI models wrote up the proofs in a form a computer can verify step by step.

The most important of the four papers describes a quantum algorithm against so-called module lattices, regular point patterns in a very large number of dimensions with an additional internal symmetry (more on that below). This is exactly the mathematics on which the new standards ML-KEM and ML-DSA rest, the successors to RSA and elliptic curves. The title already gives away the catch: “Galactic quasi-polynomial quantum algorithms for integral and module lattices”. Computer scientists call an algorithm “galactic” when it is faster on paper but never gets used in practice, because the advantage only kicks in for absurdly large inputs.

The Cryptography Incident Review Group, a new body of cryptographers that was able to review the results in advance, sees it the same way. In its initial statement it writes that against ML-KEM and ML-DSA the attack currently requires “vastly more computation than the best previously known attacks”. Cloudflare worked through the paper’s estimates in an analysis. Even a direct implementation would need “at least billions of logical quantum bits”, meaning error-corrected qubits, each built from many error-prone physical qubits. The cost against ML-DSA would exceed 2¹⁰⁰⁰ operations, while the security target of the smallest ML-DSA variant is 2¹²⁸. Cloudflare’s verdict: “This research is purely theoretical, and does not impact the security of deployed cryptosystems.”

According to the CIRG, the other three papers found no better classical attacks and no better quantum attacks on unstructured lattices.

That still does not mean the all-clear. Anthropic itself writes that the results lower long-term confidence in structured lattices, and the CIRG considers improvements to the attack likely. According to MIT Technology Review, the cryptography company PQShield also continues to see the real risk in RSA and elliptic curves, not in lattices.

AI speeds up the mathematics, not the attack

As far as the public record goes, AI has not made existing keys vulnerable. No model has demonstrably factored an RSA key or broken an elliptic-curve key exchange in public.

What AI changes is the pace of the mathematics. The security of every asymmetric scheme rests on the assumption that nobody finds a fast way to solve a particular mathematical problem. Progress on such problems used to take years and came from a fairly small community of specialists. When a model delivers four papers complete with machine-checked proofs, the gap between “considered secure” and “no longer secure” may shrink considerably. Cloudflare sums it up in two sentences: “AI doesn’t change whether a cryptographic system is secure. It changes how quickly we understand its exact security level, against classical and quantum attacks.”

Then there is what is not public. The NSA speaks of discoveries affecting “some cryptographic systems currently in use”, meaning schemes deployed today. Whether that means RSA, elliptic curves or something else entirely cannot be determined from the outside. According to a Reuters report quoted by The Hacker News, Cloudflare CEO Matthew Prince said: “Yes, we were briefed on something. Yes, it’s a big deal.” Nothing more is known, and anything beyond that would be speculation.

RSA and elliptic curves fall first

Post-quantum cryptography is necessary regardless of AI. RSA relies on the fact that a large number is very hard to split into its two prime factors. Diffie-Hellman and elliptic curves (ECDH, ECDSA, Ed25519) rely on the discrete logarithm, that is, on the fact that exponentiation in a finite set of numbers is very hard to reverse. For classical computers, both problems are practically unsolvable at today’s key lengths. In 1994, Peter Shor showed that a sufficiently large quantum computer solves both efficiently. A quantum attack on RSA has therefore been known for thirty years. The only open question was how big the machine has to be.

That number keeps shrinking. In 2019, Craig Gidney of Google and Martin Ekerå estimated that RSA-2048 could be broken in eight hours with 20 million error-prone physical qubits. In his 2025 paper, Gidney arrives at fewer than one million qubits and a runtime of under a week, under the same hardware assumptions. Today’s machines are still far from that, as the announcements from Microsoft and QuEra show. But the gap is closing from two sides at once, through better hardware and through better algorithms.

No comparable attack is known for lattice schemes. Anthropic’s algorithm changes practically nothing about that either. According to Cloudflare, quantum computers would break “elliptic curves and RSA before lattices”.

Harvest now, decrypt later: data protected today with RSA or elliptic curves can be intercepted and decrypted later if its lifetime extends past the day a quantum computer becomes available.

The agencies are pushing even though the quantum computer does not exist yet because of an attack that is already under way. The NSA says so openly, and since version 10.1 OpenSSH has also explicitly warned about “store now, decrypt later”. Anyone who intercepts and stores encrypted traffic today can decrypt it as soon as the machine exists. For an online order, that does not matter. For health records, contracts, source code or diplomatic communications that still need protection ten years from now, it does.

The key exchange is the most exposed part, because it can be attacked retroactively. Signatures, by contrast, usually only need to hold for as long as a certificate is valid. The BSI, Germany’s federal cybersecurity agency, weighs it the same way.

Post-quantum cryptography is mathematics, not physics

The name is easily misleading. Post-quantum cryptography has nothing to do with quantum physics. It runs on ordinary processors, in ordinary software, over ordinary networks. All it does is replace the mathematical problem that security rests on with one for which neither classical nor quantum computers know a fast solution. Quantum key distribution (QKD), which actually sends photons, is a different thing. The BSI regards it as a niche technology that is “currently not sufficiently mature from a security perspective”.

In August 2024, NIST published the first three standards:

StandardSchemePurposeMathematical basis
FIPS 203ML-KEM (formerly Kyber)Key exchangeModule lattices
FIPS 204ML-DSA (formerly Dilithium)SignaturesModule lattices
FIPS 205SLH-DSA (formerly SPHINCS+)Signatures, fallbackHash functions

According to NIST, SLH-DSA is explicitly intended as a “backup method in case ML-DSA proves vulnerable”, which is why it rests on entirely different mathematics. After Anthropic’s release, that caution looks farsighted.

Learning with errors

ML-KEM and ML-DSA are based on the “Learning with Errors” (LWE) problem, or more precisely its module variant. The idea can be explained without formulas. Take a system of equations with many unknowns that any school student could solve with Gaussian elimination. Then add a small random error to each result. This slightly noisy system is suddenly extremely hard to solve, because the errors build up with every step of the calculation.

Geometrically, this corresponds to a lattice, a regular pattern of points in a space with hundreds of dimensions. The public key contains a point lying just next to a lattice point. Whoever knows the secret knows which lattice point is meant. Everyone else only has a skewed, unwieldy description of the lattice and has to search for the nearest point in a space with hundreds of axes. In two dimensions this is trivial; for ML-KEM-768 there are 768.

The same lattice, two descriptions: rounding assigns each lattice point the region its basis spans around it. With the short basis, the region is compact and the target point lands in the region of the correct point. With the skewed basis, it becomes a needle and the target point lands in the region of a different point.

Shor’s algorithm is of no use here, because it exploits a hidden periodicity that exists in RSA and elliptic curves but not in noisy lattices. Anthropic’s result targets a different regularity. The module structure that makes ML-KEM fast and its keys small comes with an internal symmetry, and the new algorithm exploits it. According to the CIRG, unstructured lattices are not affected by the result.

Encapsulation instead of exchange

ML-KEM works differently from Diffie-Hellman and its common modern elliptic-curve variant X25519. In a classical key exchange, each side sends the other a public value and both derive the same secret from them. ML-KEM is a “Key Encapsulation Mechanism”. The recipient publishes a key, the sender uses it to generate a random secret along with a “capsule” (ciphertext) and sends back only the capsule. Only the recipient can open it with their private key and obtain the same secret.

The price is size. In my test with OpenSSL 4.1.1, it looked like this:

ElementClassicalPost-quantum
Public key, exchangeX25519: 44 bytesML-KEM-768: 1206 bytes
Capsule or counterpart valueX25519: 32 bytesML-KEM-768: 1088 bytes
Public key, signatureECDSA P-256: 91 bytesML-DSA-65: 1974 bytes
SignatureECDSA P-256: 72 bytesML-DSA-65: 3309 bytes

The figures come from my own test. For the keys, I measured the files OpenSSL creates; for the capsule and signatures, the raw data. The key exchange grows almost thirtyfold, signatures roughly fiftyfold. For a TLS connection, that means a good two kilobytes more in the handshake. With signatures in certificate chains or on microcontrollers with little memory, things get tighter, and that is exactly why the NSA singles out firmware and hardware roots of trust.

Hybrid as a safety belt

Because the new schemes are young, they are combined with the old ones during the transition. A hybrid key exchange runs X25519 and ML-KEM in parallel and derives the session key from both secrets. An attacker then has to break both schemes. If ML-KEM falls to a mathematical advance, X25519 still protects against today’s adversaries. If X25519 falls to a quantum computer, ML-KEM protects.

Hybrid key exchange X25519MLKEM768 in TLS 1.3: the client sends its X25519 value and an ML-KEM key, the server replies with its X25519 value and an ML-KEM capsule. Both sides derive the session key from both secrets.

The BSI recommends post-quantum schemes “only … in combination with classical schemes (‘hybrid’) if possible”. After Anthropic’s discovery, the CIRG explicitly advises hybrids “that combine schemes based on different mathematical foundations” and the highest security level an application can handle. Anthropic’s result is the best argument for this caution.

The deadlines

For US agencies, there are fixed dates. In October 2026, NIST published the final version of NIST IR 8547, which governs the phase-out. It builds on Executive Order 14412 and on memorandum M-26-15, in which the White House Office of Management and Budget (OMB) sets deadlines for federal agencies:

WhatDeadlineSource
RSA, ECDSA, EdDSA, ECDH in NIST standards“deprecated after 2030”, “disallowed after 2035”NIST IR 8547
Key exchange in the most sensitive US government systemsby December 31, 2030NIST IR 8547, following EO 14412 and memorandum OMB M-26-15
Signatures in the same systemsby December 31, 2031NIST IR 8547
Cloudflare network fully post-quantum2027 (previously 2029)Cloudflare

These deadlines are not binding for German companies. For its current recommendations, the BSI refers to its technical guideline TR-02102-1 and considers the question of whether and when quantum computers will arrive “no longer paramount”. But because vendors are converting their products for the US market, the schemes will end up in your own infrastructure anyway. The real question is where they won’t.

Hands-on: checking and setting up

For end users, most of the transition has already happened without them noticing. A handful of commands is enough to verify it; the hands-on work is mainly on your own servers.

Browsers and web servers

According to Google, Chrome enabled hybrid key exchange by default on all desktop platforms as early as version 124 in spring 2024, back then still with the pre-standard version X25519Kyber768. Since OpenSSL 3.5 from April 2025, the most widely used TLS library also offers “X25519MLKEM768 and X25519” by default. A single command shows whether a server plays along:

echo | openssl s_client -connect www.bsi.bund.de:443 -brief 2>&1 | grep -i group

For me, this returned the following for www.cloudflare.com, www.bsi.bund.de and this website alike:

Negotiated TLS1.3 group: X25519MLKEM768

It matters which openssl you call. The binary macOS ships at /usr/bin/openssl is LibreSSL 3.3.6 on my machine and does not know ML-KEM. The test needs a current OpenSSL, on a Mac for example via Homebrew (/opt/homebrew/bin/openssl).

If you run your own web server with a current OpenSSL, you usually don’t have to do anything, because the default is already hybrid. The exception is configurations that explicitly pin the key exchange groups, in nginx for example via ssl_ecdh_curve. Such a list overrides the default and needs the hybrid group added to it:

ssl_protocols TLSv1.3 TLSv1.2;
ssl_ecdh_curve X25519MLKEM768:X25519:prime256v1;

Then verify with the s_client command above. TLS 1.2 has no post-quantum groups; the protection only applies with TLS 1.3.

SSH

OpenSSH is furthest along. According to the project page, it has used a hybrid post-quantum key exchange by default since version 9.0 from April 2022, and the mlkem768x25519-sha256 scheme since version 10.0. Since version 10.1, the client warns when a connection is established without a post-quantum scheme:

** WARNING: connection is not using a post-quantum key exchange algorithm.
** This session may be vulnerable to "store now, decrypt later" attacks.

Two commands show which schemes your client knows and which one it actually negotiates:

ssh -Q kex | grep -E 'mlkem|sntrup'
ssh -v -T git@github.com 2>&1 | grep 'kex: algorithm'

With OpenSSH 10.5p1 on my Mac, the second command returned kex: algorithm: mlkem768x25519-sha256 against both GitHub and Codeberg. On your own servers, it is worth taking a look at sshd_config. If you once pinned KexAlgorithms to curve25519-sha256 as part of a hardening effort, you quietly switched off the post-quantum exchange. An up-to-date line looks like this:

KexAlgorithms mlkem768x25519-sha256,sntrup761x25519-sha512,curve25519-sha256

The classical scheme at the end keeps older clients working. If you only want to allow post-quantum connections, remove it, but that locks out older clients that don’t support any post-quantum scheme. sntrup761x25519-sha512 is the older post-quantum scheme OpenSSH used as its default before ML-KEM. Starting with version 10.6, the server also logs when a client connects without a post-quantum scheme.

For login keys, OpenSSH is still in transition. Version 10.4 introduced hybrid signature keys combining ML-DSA and Ed25519 as an experimental option; since 10.6 they are enabled by default. On my version 10.5, the type is still called ssh-mldsa44-ed25519@openssh.com:

ssh-keygen -t mldsa44-ed25519 -f ~/.ssh/id_mldsa44_ed25519

The public key is 1882 characters long instead of the roughly one hundred of an Ed25519 key. There is less urgency here than with the key exchange, because a login signature cannot be attacked retroactively. But if you have deployed a key on many servers for many years, you should replace it in the medium term.

Your own keys with OpenSSL

If you want to try the schemes yourself, OpenSSL 3.5 or later is all you need, no extra library required. An ML-DSA signature:

openssl genpkey -algorithm ML-DSA-65 -out mldsa.pem
openssl pkey -in mldsa.pem -pubout -out mldsa.pub
openssl pkeyutl -sign -inkey mldsa.pem -in message.txt -rawin -out message.sig
openssl pkeyutl -verify -pubin -inkey mldsa.pub -in message.txt -rawin -sigfile message.sig

ML-KEM encapsulation can be traced the same way. The first call generates the secret and the capsule, the second opens the capsule with the private key:

openssl genpkey -algorithm ML-KEM-768 -out kem.pem
openssl pkeyutl -encap -inkey kem.pem -secret secret1.bin -out ciphertext.bin
openssl pkeyutl -decap -inkey kem.pem -in ciphertext.bin -secret secret2.bin
cmp secret1.bin secret2.bin && echo "identical"

For me, both secrets were identical and 32 bytes long, and the capsule was 1088 bytes. For production use, these keys are of little use so far, because certificate authorities and most applications cannot yet handle ML-DSA certificates. For understanding how it works, they are enough.

Messengers

Since iOS 17.4 in spring 2024, Apple has protected iMessage with the PQ3 protocol, a hybrid of elliptic curves and Kyber. It keeps renewing the post-quantum keys during a conversation. Authentication remains classical there for now, for the same reason as with SSH keys. Users don’t need to do anything except install updates.

The real problem is the inventory

Browsers, SSH and messengers largely convert themselves. Things get difficult with everything nobody updates regularly. That includes VPN gateways, industrial controllers, embedded devices, old Java applications with hard-coded algorithms, internal certificate authorities and firmware signatures that remain valid for a device’s entire lifetime. The NSA names three steps for this: “Inventory your cryptographic dependencies”, “Assess risk”, “Triage and implement”. The same order works just as well for companies outside the US government, with risk best measured by how long the data needs to stay protected.

For new purchases, support for ML-KEM and ML-DSA belongs in the tender. A device bought today without it will probably still be in operation in 2035.

Mathematics has a new collaborator

The December 2 warning names no concrete attack. It responds to the fact that models are now working on the mathematics of cryptography. The publicly known AI discovery is a galactic algorithm that harms no one today. What the agencies know beyond that is not public, and the US government statement explicitly does not speak of an immediate threat.

The threat to RSA and elliptic curves still comes from quantum computers, and for intercepted data the clock is already ticking. At the same time, the era in which cryptographers could vet new schemes calmly over years is coming to an end, because models are now working on the same problems. The response is the same as before AI, only more urgent: switch to hybrid, keep algorithms swappable, start with the key exchange.

Encryption has always been a bet on the limits of mathematics. Now someone is testing those limits faster than ever before.

Sources