In November 2026, researchers at startup Calif pointed an AI agent at the OpenJDK source code. About an hour later, the agent uncovered a critical memory-corruption flaw in the hardware-accelerated AVX-512 Base64 decoder. Two hours after that, the team had a working exploit. The bug was named Java4Shell (CVE-2026-114938) with a CVSS v4 score of 9.2, and the entire run cost under $200 in tokens.
This is no longer a one-off trick. Slightly earlier, the PHP2Shell wave exposed old memory flaws in the PHP ecosystem that had sat unnoticed for years. And the FBI through IC3, alongside international agencies, issued an urgent warning: attackers are running autonomous pentesting frameworks like the open-source ARTEX and moving from target selection to privileged access in under three hours.
If an AI-assisted attacker can tear apart an app in an evening for a couple hundred dollars, waiting for an annual manual audit makes no sense. There is only one realistic move: hack your own app first, before the code hits production.
Illustration of automated vulnerability discovery by AI agents from the Cloudflare engineering blog (Source: Cloudflare Blog)
Any attacking agent's first pass revolves around five basic questions:
- Can an outsider slip past login or logout: get inside without permissions, or stay logged in after signing out?
- Can one user see another user's data? This is the IDOR (Insecure Direct Object Reference) class, where swapping someone else's ID in a request opens their profile or order.
- Have passwords, tokens, or API keys leaked into code, configs, logs, or the database?
- Can someone trick a built-in AI via prompt injection—sneaking text into a message or GitHub issue that hijacks system instructions and forces the model to run an attacker's command?
- Is it easy to burn through your API budget or crash the server with unlimited requests?
You don't need to know the answers upfront. This gives your coding agent a clear checklist to comb through the repository.
Why a single agent lies, and how a 'hunter + skeptic' pair clears the noise
If you just feed a repo to one AI model and ask it to "find vulnerabilities," it will dump dozens of hallucinations and minor nitpicks. Ask the same model to double-check its list, and it will confidently confirm its own mistakes. One agent should never grade its own homework.
The setup that worked for Java4Shell—and is detailed in the Cloudflare engineering blog—splits the audit into two opposing roles. First, a hunter casts a wide net and flags anything that remotely looks like a bug, even at low confidence. Then, for each hypothesis, a fresh verifier spins up as a devil's advocate. It isn't allowed to report new findings; its sole job is to prove the bug doesn't exist. Only what the skeptic fails to disprove survives.
Official funnel filtering false positives in Cloudflare's Vulnerability Discovery Harness and Validation System: from 20,799 candidates down to 7,245 confirmed bugs (Source: Cloudflare Blog)
The chart above shows real numbers from Cloudflare's internal pipeline, which grew into the open-source cloudflare/security-audit-skill in June 2026. More than half of the raw candidates get filtered out as duplicates or false alarms, leaving teams with a clean list of real issues, including dozens of critical and hundreds of high-severity bugs.
Released under the MIT license, the skill reached 78,760 GitHub stars by November 2026. Inside, it runs six phases. First, recon subagents follow RECONNAISSANCE.md to map the architecture, trust boundaries, and entry points into architecture.md and coverage-ledger.json. Next, the hunting phase (HUNTING.md) hands logical chunks of code to isolated hunters, while coverage critics hunt for blind spots using 15+ built-in attack guides (WEB-PROTOCOL-AND-AUTH.md, AI-AND-LLM.md, MEMORY-SAFETY-AND-BINARY.md, SUPPLY-CHAIN-AND-RELEASE.md, and more).
In the third phase (VALIDATION-AND-REPORTING.md), an independent verifier with zero hunter context tries to refute each candidate. Verdicts (confirmed, needs_validation, rejected) are written to findings.json and checked by zero-dependency scripts validate-findings.cjs and validate-coverage-ledger.cjs. Fresh agents then re-verify source links and compile REPORT.md, FINDINGS-DETAIL.md, and NEEDS-VALIDATION.md. On re-runs, the skill picks up existing coverage-ledger.json and findings.json files, checks changed code, and closes uncovered gaps.
Installing and running a live test on Archon without a sandbox
The skill works with coding agents that read SKILL.md and can spawn subagents, including Claude Code, Cursor, Codex, and similar tools. You install it via the Skills CLI:
# Install the skill locally into the current repository
npx skills add https://github.com/cloudflare/security-audit-skill \
--skill security-audit
# Or install globally for all your projects
npx skills add https://github.com/cloudflare/security-audit-skill \
--skill security-audit --global
Once installed, the agent picks up the instructions automatically when you ask for an audit. Still, there is a dangerous trap here.
Dynamic exploit testing requires building and running the code. If you turn that on for an unfamiliar or untrusted repo directly on your workstation, build scripts can execute malicious code. Cloudflare's docs explicitly require an OS-level sandbox—an isolated environment with no network access and stripped environment variables. If you don't have a sandbox handy, restrict the agent to static search and the refutation phase:
Use the security-audit skill to run a full security audit of this repo.
Save the report to ./security-audit-report/.
There is no sandbox on this machine, so do not execute exploits.
Run recon, hunters, and independent verifiers to build the final report.
That is exactly how Cole Medin ran the skill through Claude Code on his open-source project Archon. Recon subagents went first, followed by 12 parallel hunters, and the orchestrator added 6 more after they finished (18 hunters total). Every candidate got its own devil's advocate.
Almost all the noise vanished during validation. Exactly one confirmed low-severity bug survived in the auth service: after a user logged out, their old session cookie (the browser token proving you are signed in) was still accepted by the GET /verify endpoint.
Proving it with a test, fixing it, and setting a pre-release rhythm
A static-analysis finding still needs live proof. Open a separate, clean agent session, hand it the report from ./security-audit-report/, and ask it to write a regression test first:
// Regression test: old session cookie must be rejected after logout
test("revoked session cookie is rejected by GET /verify", async () => {
// Sign in as a test user and grab Set-Cookie
const loginRes = await app.request("/login", {
method: "POST",
body: JSON.stringify({
username: "test-user",
password: "test-password",
}),
});
const cookie = loginRes.headers.get("set-cookie");
expect(cookie).toBeTruthy();
// End the session with that same cookie
await app.request("/logout", {
method: "POST",
headers: { Cookie: cookie! },
});
// A repeat request to /verify must return 401
const verifyRes = await app.request("/verify", {
method: "GET",
headers: { Cookie: cookie! },
});
expect(verifyRes.status).toBe(401);
});
First, the test fails and proves the bug is real. In the same session, the agent patches the auth service, gets the test passing, and opens a pull request. Depending on the bug, you might need a unit test or a browser run instead of an integration test, yet the rule stays the same: reproduce first, patch second.
Running 18 hunters and dozens of verifiers burns plenty of tokens, so there is no point running it on every small commit. A practical rhythm is auditing before each major release (prior to merging into main) and right after fresh security patches in dependencies or infrastructure. Google has already noted that attackers regularly dissect public security patches to turn them into working exploits.
Use cloudflare/security-audit-skill strictly on your own applications and repositories where you have explicit owner permission. And don't skip basic hygiene: agentic audits catch subtle business-logic flaws, while CI scanners, secret isolation, and code reviews remain essential.


