Claude scales formal verification across open-source libraries
Anthropic and Theorem used Claude to prove security properties for 239 entry points across 123 open-source libraries in Google’s OSS-Fuzz initiative. Over a few weeks, Claude patched bugs it encountered and generated about 180 million lines of Rocq proofs covering compiled RISC-V instructions.
The approach converts existing fuzz tests into formal specifications, then asks Claude to prove that the compiled tests cannot crash for any input less than 64 MB under modeled operating conditions. Unlike fuzzing, which samples inputs without guaranteeing complete coverage, these proofs cover every permitted input and execution path reachable from the verified entry point. The Rocq proof checker independently checks whether each proof satisfies its specification.
The verification attempts uncovered hundreds of bugs, including memory errors requiring unusually large or specially structured inputs and logic flaws that do not cause crashes. Anthropic is releasing selected proofs and supporting formal models, while withholding proofs that could expose unpatched vulnerabilities. Theorem is also offering the pipeline to other open-source projects.
The guarantees remain narrower than proving entire libraries bug-free. They assume single-threaded, statically linked RISC-V binaries with fixed memory budgets running under modeled Linux behavior. Unverified entry points, incomplete memory-error detection and differences between formal models and deployed systems leave gaps. Generating proofs also remains resource-intensive, although newer models and shared proof components reduced token requirements in experiments.