SecureForge: Finding and Preventing Vulnerabilities in LLM-Generated Code via Prompt Optimization
Houjun Liu, Lisa Einstein, John Yang, Joachim Baumann, Duncan Eddy, Christopher D. Manning, Mykel Kochenderfer, Diyi Yang · 2026
Read SecureForge: Finding and Preventing Vulnerabilities in LLM-Generated Code via Prompt Optimization by Houjun Liu, Lisa Einstein, John Yang, Joachim Baumann, Duncan Eddy, Christopher D. Manning, Mykel Kochenderfer, Diyi Yang (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-08382.txt.
Description
Houjun Liu, Lisa Einstein, John Yang, Joachim Baumann, and coauthors audit the security of code written by frontier models. A model can be told to write secure production code. It can even be handed the weaknesses to avoid. Verifiable flaws still appear in about twenty-three percent of outputs. The count comes from two hundred fifty ordinary coding prompts.
Their SecureForge pipeline first finds benign prompts that trigger statically detectable flaws. It grows them into a large synthetic corpus with a Markovian sampler. The sampler preserves both error rates and diversity. Lessons from the audit are folded into secure system prompts. Those prompts cut flaw rates in tests while keeping unit test performance intact.
Catalog record
| CREATOR | Houjun Liu, Lisa Einstein, John Yang, Joachim Baumann, Duncan Eddy, Christopher D. Manning, Mykel Kochenderfer, Diyi Yang |
|---|---|
| YEAR | 2026 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 56 KB |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2605.08382