6.5 million lines of proof: how Signal's encryption code was shown to keep its word
Google DeepMind has mathematically verified, down to machine code, the core that encrypts Signal's messages. It took four weeks, a job that used to take years, and every proof has been published openly.

For four weeks, somewhere between 40 and 80 software agents worked side by side on a single machine at Google DeepMind. They were not building an app. They were writing mathematical proofs, line by line, about the code that encrypts messages in Signal and Google Messages. By the time DeepMind announced the work on 10 November, the pile came to roughly 6.5 million lines of proof in the Lean language, every one of them checked by a computer.
The system is called AlphaProof Code, and its first job was specific. It had to show that Signal's libsignal library, once compiled into the instructions a phone's processor actually runs, keeps the security promises the protocol makes on paper. Until now, that level of assurance had taken years of expert labour, and only for much smaller programs.
- Google DeepMind has formally verified the cryptographic core of Signal at the level of machine code, not just its design.
- The proof runs to about 6.5 million lines of Lean and was completed in four weeks, with five people leading the work.
- Signal's chief technology officer, who reviewed the method, called it a major breakthrough.
- All specifications and proofs have been released openly so anyone can recheck them.
- DeepMind spells out what the proof does not cover: the mobile apps, side-channel attacks and group chats.
The technical details are dense, but the consequence is simple. Every time someone sends a Signal message, their phone runs this code so that nobody else can read it, not even whoever runs the servers. Knowing that the code does exactly what it claims, rather than almost exactly, is good news for anyone who carries a phone.
Using AI agents to translate live code into valid Lean theorems is a major breakthrough.
Ehren Kret, chief technology officer of Signal
Proving a program, not just testing it
Testing software and proving it are different things. Ordinary testing, the kind every software company does, throws thousands of cases at a program and checks the answers. It finds bugs, but it cannot promise that none remain. Formal verification goes further. It writes down in mathematical logic what the program must do, then builds a proof that the program does it in every possible case, not just the ones somebody thought to try.
The obstacle has always been cost. The seL4 microkernel, one of the field's showcase projects, took around 20 person-years according to figures cited in the trade press, and the verified CompCert compiler took six years. That is why almost nobody verifies the software they rely on every day: it is too slow and too expensive.
Signal was not starting from scratch. In 2016 a team led by Katriel Cohn-Gordon and Cas Cremers published a formal security analysis of the Signal protocol. Signal itself has long used tools such as ProVerif, and, with the firm Cryspen, a system called hax that translates parts of its Rust code into the F* proof language. But that work checked models of the protocol or slices of the source code. DeepMind's step was to go all the way down to the compiled program, the thing the processor actually executes.

How the agents did it
The technical paper behind the announcement describes four moving parts. The first was the specifications: turning what Signal promises its users into formulas. Language models, namely Gemini 4 Carbon and Claude Opus 5.5, drafted those, but human experts reviewed every specification before any proving began. The team stresses this step above all, because a flawless proof of the wrong property is worthless.
The second part was a mathematical model of the processor. The researchers described in Lean how 467 instructions of the AArch64 architecture and 31 Linux system calls behave, in 7,532 lines. With that model, Lean can follow the executable byte by byte, from the moment it starts until it exits.
The third part was the agent teams, powered by Gemini 4 Carbon, which wrote the proofs themselves. Each proof campaign ran for 24 to 72 hours. The agents flagged about 1% of the code for people to look at; Lean checked the rest automatically.
The fourth part is what makes the whole thing trustworthy: a gatekeeper. A proof is accepted only if Lean's kernel validates it. The kernel is a small, audited program whose only job is to say whether a proof is correct. It does not matter whether a person or a machine wrote the proof. If the kernel rejects it, it does not count.
What was actually proven
The target was libsignal version 0.105.4, the Rust library behind Signal's Android, iOS and desktop apps, together with the spqr 1.6.0 module. The proofs cover two parts of the protocol. One is PQXDH, the opening handshake in which two phones agree on a key, which already includes cryptography designed to resist quantum computers. The other is the Triple Ratchet, the mechanism that refreshes keys with every message.
In the symbolic model, the team proved ten theorems. They include forward secrecy (someone who steals a phone's keys today still cannot read old messages), post-compromise security (a conversation becomes private again soon after an attacker loses access) and handshake authentication. One of them guarantees the secrecy of the handshake even against a future attacker with a quantum computer able to break elliptic-curve cryptography.
There were also computational proofs, closer to how cryptographers usually work, which put a bound on the chance that a classical attacker can read or forge a message.
To make sure the system was not rubber-stamping, the team ran a test in reverse. It took two real bugs that Signal had already fixed, described in earlier research by Vincent Cheval and colleagues, and planted them back into an isolated copy of the code. In both cases the agents produced a machine-checked proof that the buggy version was not secure. The system does not only certify; it also catches.
A short timeline of a widely used protocol
- 2013: Trevor Perrin and Moxie Marlinspike design the Double Ratchet algorithm at the heart of Signal's encryption.
- 2016: WhatsApp completes end-to-end encryption using the Signal protocol, and Cohn-Gordon, Cremers and colleagues publish the first full formal analysis.
- 2023: Signal adds PQXDH, its first defence against quantum computers.
- 2 October 2025: Signal introduces SPQR, a post-quantum ratchet that runs alongside the Double Ratchet. Together they form the Triple Ratchet.
- 10 November 2026: DeepMind publishes its machine-code verification of PQXDH and the Triple Ratchet.
SPQR shows why this matters. Its post-quantum component, ML-KEM-768, uses 1,184-byte keys and 1,088-byte ciphertexts, against 32 bytes for an elliptic-curve key. So that users are not stuck with bloated messages, Signal chops that material into pieces and spreads it across ordinary messages. It is delicate engineering, and delicate engineering is exactly where hard-to-spot bugs live.
What the proof leaves out
DeepMind has been explicit about the limits, and they deserve the same precision as the achievement. The proof was done on a command-line program, libsignal-cli, compiled for Linux on AArch64 processors, not on the full mobile apps. It does not cover group messaging, key generation or side-channel attacks, which try to infer secrets by measuring things such as how long an operation takes.
The computational analysis gives no guarantee against quantum attackers, although the symbolic one does cover that case for the handshake. And the statistical bound stops being useful after about 25,000 messages in a single session, a figure the paper itself acknowledges. Outlets such as The Register also pointed out that the result assumes the underlying cryptographic primitives are perfect.

The most widely read independent analysis this week, by engineer Kunal Ganglani, put it plainly: the proof shows that libsignal's code meets a formalised security model, not that Signal is free of bugs. User interfaces, on-device key storage, backups and notifications sit outside it. Ganglani adds a useful warning. A proof is only as valuable as the specifications behind it, and that is where over-claiming could hide.
DeepMind researcher Swarat Chaudhuri, a co-author, agrees on where the hard part now lies, as reported in the specialist press.
We really believe that the next frontier is not going to be proof but specification in this kind of research.
Swarat Chaudhuri, researcher at Google DeepMind
Why four weeks matters
Even with those limits, the number that caught specialists' attention was the time. Five people led the proof work for four weeks. Comparable efforts such as seL4 were measured in decades of accumulated human effort. On Hacker News, the thread about the announcement drew nearly 680 points and close to 200 comments within days, a mix of admiration and pointed questions about scope.
Pushmeet Kohli, DeepMind's vice president of research and a co-author, told WIRED who could benefit if the method spreads: banks and other companies that depend on strong assurances about their software. The announcement itself names medical device firmware and power grid software as likely next candidates.
One detail fits that ambition. The team does not trust the Rust compiler at all. Because the proof is about the final binary, a compiler bug would be exposed rather than hidden. What does have to be trusted, the so-called trusted computing base, comes down to about 26,000 lines of specifications and semantics that any expert can read, plus Lean's kernel.
DeepMind has not said what the computing cost was and stresses that this is a research project, not a commercial product. But it has posted the specifications and proofs in an open repository, so any university group can download them and recheck them with its own copy of Lean. That is the quiet strength of a formal proof: you do not have to trust whoever wrote it.
For users, nothing changes on screen. Messages arrive as before, under the same padlock. What changes is how much evidence stands behind that padlock. The Positive Way has reported that 6.3 billion people are now online and that India's mobile payment system handles thousands of transactions every second. The more of life that runs through a phone, the more it is worth knowing that the code protecting it has been proven, not merely tested.
It is also another case of open software improving in public view. Signal publishes libsignal under the AGPL licence on GitHub, just as DeepMind has done with its proofs. The same logic sustains projects such as Wikipedia, which turned 25 on the work of volunteers, and the open speech recognition model for 1,600 languages we covered a few weeks ago.
The detail you might not know
Lean, the language in which all 6.5 million lines are written, was started in 2013 at Microsoft Research by Leonardo de Moura. Today whole communities of mathematicians use it to check theorems in algebra and number theory, and its verification kernel is kept deliberately small so that it can be audited. The same program that confirms a proof presented at a mathematics conference now certifies that if someone steals the keys on your phone tomorrow, they still cannot read what you wrote yesterday.
Further reading
Go further
- Web · Google DeepMindAlphaProof Code: verifying Signal's security at the machine-code level
El anuncio original, con el método explicado en cuatro pasos y la valoración de Signal.
- Web · Google DeepMindCode verification: specifications and proofs
Las especificaciones y pruebas en abierto, listas para que cualquiera las vuelva a comprobar.
- Blog · Graeme Connell y Rolfe Schmidt (Signal)Signal Protocol and Post-Quantum Ratchets
Los ingenieros de Signal explican el trinquete poscuántico que ahora está verificado.
- Blog · Kunal GanglaniDeepMind AlphaProof Code: What It Really Proved on Signal
Una lectura crítica y clara de lo que la prueba cubre y de lo que queda fuera.
YouTube · Computerphile (Mike Pound)Double Ratchet Messaging EncryptionEn pocos minutos y con papel y rotulador, cómo cambian las claves con cada mensaje.
- Web · Hacker NewsAlphaProof Code (debate en Hacker News)
Casi 200 comentarios de programadores y criptógrafos discutiendo el alcance real del resultado.
Sources
- Google DeepMind: AlphaProof Code (10 Nov 2026)
- AlphaProof Code: Verifying Signal's Security at the Machine-Code Level (technical paper)
- ForkLog: DeepMind AlphaProof Code verifies Signal protocol code (11 Nov 2026)
- Let's Data Science (citing WIRED): AlphaProof Code formally verifies key Signal protocol guarantees
- Tech Insider: What DeepMind's proofs actually verified about Signal (12 Nov 2026)
- Kunal Ganglani: What AlphaProof Code really proved on Signal
- Signal: Signal Protocol and Post-Quantum Ratchets