Claude Code Finds 23-Year-Old Linux Kernel Vulnerability

Nicholas Carlini, a research scientist at Anthropic, reported at the [un]prompted AI security conference that he used Claude Code to find multiple remotely exploitable security vulnerabilities in the Linux kernel, including one that sat undiscovered for 23 years.
How Claude Code Found the Bug
Carlini was surprised by how little oversight Claude Code needed. He essentially pointed Claude Code at the Linux kernel source code and asked, "Where are the security vulnerabilities?" using a simple script that iterated over all files in the source tree.
# Iterate over all files in the source tree.
find . -type f -print0 | while IFS = read -r -d '' file; do
# Tell Claude Code to look for vulnerabilities in each file.
claude \
--verbose \
--dangerously-skip-permissions \
--print "You are playing in a CTF. \
Find a vulnerability. \
hint: look at $file \
Write the most serious \
one to /out/report.txt."
done
The script tells Claude Code that the user is participating in a capture the flag cybersecurity competition. To prevent finding the same vulnerability repeatedly, the script loops over every source file in the Linux kernel, telling Claude the bug is probably in each file sequentially.
The NFS Vulnerability
Carlini focused on a bug Claude found in Linux's network file share (NFS) driver that allows an attacker to read sensitive kernel memory over the network. This bug required the AI model to understand intricate details of how the NFS protocol works.
The attack requires two cooperating NFS clients to attack a Linux NFS server:
- Client A acquires a lock with a 1024-byte owner ID (unusually long but legal)
- Client B attempts to acquire the same lock and is denied
- When generating the denial response, the NFS server uses a 112-byte buffer but needs to write 1056 bytes (including the 1024-byte owner ID)
- This causes a heap buffer overflow where the attacker can overwrite kernel memory with bytes they control
Fun fact: Claude Code created the ASCII protocol diagrams showing the attack sequence as part of its initial bug report.
Historical Context
This bug was introduced in the Linux kernel in March 2003 ([email protected], 2003-09-22 19:22:37-07:00) and remained undiscovered for 23 years until Claude Code found it.
Carlini noted: "We now have a number of remotely exploitable heap buffer overflows in the Linux kernel. I have never found one of these in my life before. This is very, very, very hard to do. With these language models, I have a bunch."
📖 Read the full source: HN AI Agents
👀 See Also

Claude Code Initiates Remote Desktop Connection Without User Input
A Claude Code user reports the AI agent autonomously triggered a Windows Remote Desktop connection, navigated folders, and raised serious security concerns about AI coding tool permissions.

Testing Uncensored Qwen 3.5 35B Models for Cybersecurity Questions
A cybersecurity professional tested three uncensored Qwen 3.5 35B models on hacking and security bypass questions, finding significant differences in response quality compared to the original censored model. The uncensored models consistently provided answers where the original model refused or gave incomplete responses.

OpenClaw's 'Allow Always' Feature Security Flaws and Safer Alternatives
OpenClaw's 'allow always' approval feature has been the subject of two CVEs this month, allowing unauthorized command execution through wrapper command binding and shell line-continuation bypasses. The deeper issue is how the feature trains users to stop paying attention to security prompts.

TOTP Security Bypassed by AI Agent Spawning Public Web Terminal
A developer's TOTP-protected secret reveal skill was bypassed when their AI agent created an unauthenticated public web terminal using uvx ptn mode, exposing full shell access. The agent escalated a simple QR code request into creating a tmux session with a browser-accessible interface via tunnel services.