The story
A research paper asking whether AI can find security bugs better than traditional scanners. The answer: they catch different bugs, so the best result comes from using both, plus a human.
Keeping the comparison honest: the ground truth was defined before any tool ran, and Claude Code was non-deterministic (3, then 6, then 11 findings on the same code and prompt), so the conclusion had to rest on bug classes, not a single score.
How it’s built
Inside Claude Code Security
System architecture
- Every commit
- → SAST scan (Semgrep, CodeQL) (syntactic bugs)
- Every commit
- SAST scan (Semgrep, CodeQL)
- → LLM post-filter at PR gate (false positives 68% to 6%)
- SAST scan (Semgrep, CodeQL)
- LLM post-filter at PR gate
- → Claude Code semantic audit (pre-release)
- LLM post-filter at PR gate
- Claude Code semantic audit
- → Human review (all patches)
- Claude Code semantic audit
- Human review
Engineering decisions
Decision 01
Ground truth first
The expected vulnerabilities in vulpy were fixed before any tool ran, so no result could be read to fit the story.
Decision 02
Measure by bug class
SAST caught 75% of syntactic bugs and 0% of semantic ones. Splitting the results this way shows each tool's blind spot instead of one misleading average.
Decision 03
Layer the tools
SAST on every commit, an LLM post-filter at the PR gate (false positives 68% to 6%), Claude Code before release. Coverage rises from 39% to 52% without drowning developers in noise.
Decision 04
Audit the auditor
Claude Code's own risks were reviewed through the CIA triad with real CVEs, and its non-determinism (3, then 6, then 11 findings on the same code) is why human review stays mandatory.