New Technique Medium TD-2026-0163 For AppSec, AI Eng, Red Team AI-assisted
LLM agents find soundness bugs in safe Rust bindings to C and C++ libraries
The paper proposes LLM agents as auditors of safe Rust interfaces that wrap unsafe code. In repeated audits of a real-world crate, a closed model (Claude Opus 5.5) and an open model (DeepSeek V4.1 Flash) found undefined-behavior and divergence defects, but few incomplete unsafe contracts. The authors report 225 undefined-behavior bugs across 16 crates and 11 more in the Linux kernel's Rust abstractions, with maintainers fixing 26 of 83 reported findings.
Why it matters
Safe Rust callers can trigger undefined behavior when a binding encodes an unsafe invariant too weakly, exposing applications that depend on widely used crates such as OpenSSL, SQLite, libgit2, and libcurl bindings. The study is an arXiv preprint and its results are self-reported by the authors.
Do this
- Review unsafe blocks and safe wrapper APIs in Rust crates that bind C or C++ libraries for missing or weak invariant checks.
- Run sanitizers such as Miri or AddressSanitizer on candidate soundness findings before treating them as confirmed.
- Check whether maintainers of Rust bindings you depend on have released fixes for reported soundness issues, and pin to patched versions.
- Document unsafe contracts for public safe interfaces so reviewers can verify caller obligations.
Signals
- NoCISA KEV
- 23/100Priority
- 60%Confidence
Evidence
“If an interface encodes one rule of the code beneath it too weakly, a program written in purely safe Rust can cause undefined behavior.”
“Their findings are almost always real, even without an independent reviewer, yet they lack triage discipline: they seldom confirm with a sanitizer, and they stop early.”
“Maintainers have fixed 26 of the 83 findings that we reported.”
Sources
Affected / related
LLM agent auditing of Rust safe interfaces, Crustify, Claude Opus 5.5, DeepSeek V4.1 Flash, OpenSSL bindings, SQLite bindings, libgit2 bindings, libcurl bindings
Published 2026-11-24 02:06 UTC · updated 2026-11-25 02:35 UTC · AI-assisted summary, checked against quoted sources · How we score