Only 26% of AI security patches were clean fixes, 1Password says
In short
- Only 26.0% of AI-written security patches were clean fixes in a study by Off-By-1 Labs, the security research group at 1Password. Another 20.1% closed the hole but changed unrelated behaviour, and 53.9% left the flaw open, added a new one, or both.
- The team asked two models, OpenAI's ChatGPT 5.5 and Anthropic's Opus 4.8, to patch six recently disclosed open-source vulnerabilities, each of which needed changes in several files or code paths. After excluding 400 attempts that looked like cheating, 6,080 patches were scored.
- Better information helped only modestly. On the page, patches written from only accurate guidance were clean fixes 31% of the time, and wrong guidance cut that to 15%.
- This is the company's own study with a deliberately hard set of six bugs, and 1Password says that after publication it got feedback that its settings may have limited what the AI tools could do. The patches, tooling and paper are public.
26.0% clean fixes, no side effects; 20.1% fixed, but changed other behaviour; 53.9% failed to fix, added a flaw, or both; 6,080 patches scored
How often is an AI-written security patch correct?
The Off-By-1 Labs team, writing as 1Password, measured it on hard cases. They picked six vulnerabilities disclosed so recently that the models were unlikely to have seen the fixes in training, and whose complete fix needed changes across several files, functions or code paths.
For each model and bug they generated 540 patches, varying three environment set-ups and nine prompt wordings, for 6,480 attempts in all. They removed 400 where a model appeared to look up the existing upstream patch. Each remaining patch was put into one of five outcomes:
S3 to S5 add up to 53.8% here; the page gives 53.9%, a rounding difference in the source. The S1, S2 and S3-S5 shares come from the page and paper (Table 7); the five-way split is from the paper.
The page's examples of S2 side effects: a patch that "subtly altered how expressions are parsed", swapped an allowlist for a denylist, or rejected valid inputs as well as malicious ones. The team had expected a success rate above 67%.
What is a "complete" patch, and why does it matter?
A security patch can stop the one attack string in a report without removing the underlying weakness. The study counts a fix as complete only if it closes every known exploit path.
The authors found that more than one-third of patches graded S1 or S2 were also fragile: they cut off the route to the dangerous operation rather than removing the operation. In the Spring AI case, both models often escaped selected characters in user input so malicious strings would not reach an unsafe expression evaluator. A correct fix would swap that evaluator for a safely restricted one. The escaping may block the proof-of-concept input but leaves the vulnerable component reachable by other inputs.
Does better information help?
Somewhat. The page says that with only carefully vetted, known-correct guidance, the clean-fix share rose from 26% to 31%, and with incorrect root-cause or fix-direction information it fell to 15%. The paper's Table 12 breaks it down by the kind of fix guidance in the prompt:
The page's 15% and the paper's 7.4% are not the same measure, and this story could not reconcile them from the text read. Both show the same direction: wrong guidance is very costly.
The two models, and the spread between bugs
Across the whole set the models were close on clean fixes: Claude Opus 4.8 at 25.6% and ChatGPT 5.5 at 26.5% (paper, Table 7). They differed on side effects: 15.1% of Opus patches were S2 against 25.2% for ChatGPT.
The bigger swing was between bugs. For Opus 4.8, clean fixes ran from 75.8% for the Exim bug to 3.3% for ActiveMQ and 0.9% for Gemini CLI (paper, Table 8). The paper adds that no model, mode and prompt combination exceeded 50% clean fixes on every target, and that treating each of the six CVEs as one observation gives a 95% confidence interval for the 26.0% of roughly 3% to 49%. With six bugs, the average is an imprecise number.
Cost
The page puts the average cost of one patch attempt plus validation at $2.11 for ChatGPT 5.5 (medium effort, with OpenAI's Trusted Access for Cyber guardrails) and $2.81 for Opus 4.8 (high effort, with Anthropic's Cyber Verification Program guardrails). It stresses that this excludes the cost of confirming a patch really closes the hole and keeps the application's behaviour.
What the study does not show
- Six bugs, two models. The authors chose recent vulnerabilities whose complete fixes spanned several files or code paths, so the result is not a rate for ordinary bugs (our reading; the sources do not give one).
- Mostly AI-graded. Most patches were judged by AI validators. The paper says the team manually reviewed at least 10% of validator judgments and averaged across validator models, but some grading error remains.
- Settings. The first phase used default tool settings and cost limits. The October update says feedback after publication suggested these limited what agentic patching tools could produce, and that a useful next question is whether stronger verification changes the outcomes. The page names no critic and does not say what a re-run would show.
- A snapshot. The paper notes results could differ if the same tests were re-run later, since the models are served remotely.
Since the August publication
The page was updated on 26 October 2026 with a recommendations section. It reports Anthropic's feedback that patch generation has outpaced patch verification, and that verification should rest on running code rather than reading it, with domain experts as final reviewers at current model capabilities. It also notes that one of the original authors, Keith Hoodlet, wrote the 6 August paper but not the October updates.
Terms in plain English
- CVE: a public ID number for a specific software vulnerability. (Ours.)
- Patch: a code change that is meant to remove a vulnerability. (Ours.)
- Regression: a change that breaks or weakens something that worked before. (Ours.)
- FLAWED: the study's name for "Fix-Like Artifacts with Embedded Defects": patches that look like fixes but are not clean ones, and also the name of its test tooling.
Where things stand
The dataset of all 6,480 generated patches, including the 400 excluded, and the FLAWED tooling are released so teams can run it against bugs they have already fixed and compare. 1Password says it welcomes criticism of its methods.
Sources
- How information quality impacts LLMs' ability to patch complex, novel vulnerabilities, 1Password (Off-By-1 Labs), 6 August 2026 (updated 26 October 2026)
- LLM-Generated Patches for Complex, Novel Vulnerabilities are Often F.L.A.W.E.D. (PDF), Mierczuk, Michaels and Hoodlet, Off-by-1 Labs
Sources
- How information quality impacts LLMs' ability to patch complex, novel vulnerabilities
- LLM-Generated Patches for Complex, Novel Vulnerabilities are Often F.L.A.W.E.D.
Related stories
- Google releases Fuse, a test of how AI assistants read motives
- Ai2 releases XYBench, which tests if AI finds the real problem
- AI4Bharat and NVIDIA release 23 open tests for Indian languages
- DeepL builds a separate AI model to check translations for errors
- Cloudflare brings full post-quantum switch forward to 2027
- Anthropic says plain Claude Code review finds 11 of 21 logic bugs