AppLedger › Guides › Security scan for Claude Code

A second-opinion security scan for code Claude Code wrote.

Independent scanners check what the agent built, explain each problem in plain English, and hand the agent a fix request. Free, and one command to add.

Claude Code Trivy +Opengrep Plain-Englishreport + fix writes codechecks itfixes, re-checks
Short answer

Claude Code's /security-review is useful, but it's the same kind of AI checking work an AI wrote. Add a rule-based second opinion: AppLedger runs Trivy and Opengrep on the project, explains the results in plain English and gives the agent a fix request. Use both.

Is /security-review enough on its own?

Anthropic's security review asks Claude to look for vulnerabilities in your code, and it can find logic flaws that rule-based tools miss. But AI reviews are not deterministic, and in a 2025 test by Checkmarx the review dismissed a real remote-code-execution bug as a false positive and accepted dangerous code because a comment called it safe test code.

AI review (/security-review)Rule-based scanners (AppLedger)
Same answer every runNoYes
Can be talked out of a finding by a commentYesNo
Known vulnerable package versionsSometimesYes, from vulnerability databases
Leaked keys and tokensSometimesYes, dozens of known key formats
Logic flaws (who may see what)SometimesRarely

What AppLedger checks

Secrets

API keys, tokens and passwords written into the code (Trivy).

Vulnerable packages

Dependencies with published security holes, and the version that fixes them (Trivy).

Risky code

SQL and command injection, unsafe data loading, debug mode left on (Opengrep).

Plain English + fix

Each finding says what could happen and what to do, plus a fix request for the agent.

Add it to Claude Code in one command

$ claude mcp add appledger -- uvx --from appledger appledger-mcp
 
> Is my app safe to share?
appledger · check_app: checking with Trivy and Opengrep…
F · 12/100 · 5 fix before sharing · 9 fix soon · 7 good to know
Top problem: your code contains a live Stripe payment key. Fix them?

Needs uv. Without it: pip install appledger, then python -m appledger path/to/app. The full plugin with a guided “check my app” skill is on GitHub.

Does it work with Cursor and Codex?

Yes. It's a standard MCP server, so any agent that supports MCP can call it, and the command-line tool works anywhere Python runs. The fix request is plain Markdown that any coding agent can follow.

What happens to my code?

By default only the files git would commit are zipped (no dependencies, media, files over 1 MB or secret files such as .env and keys), sent over HTTPS to our scanning service after you confirm, checked, and deleted right after. With --local and the scanners installed, your code never leaves your computer. See the privacy policy.

What a scan can't catch

Whether your authorisation logic is right, business-logic flaws, and settings outside the code such as database access rules or cloud permissions. That's where an AI review or a human review still earns its keep.

Questions

Does it replace /security-review?

No. Use both. /security-review can reason about logic; AppLedger's rule-based scanners give the same answer every time and can't be talked out of a finding.

Does it work with Cursor and Codex?

Yes. It's a standard MCP server and a command-line tool, so any agent that supports MCP or can run a command can use it.

Is it free?

Yes. The check, the plain-English report and the fix request are free. The package is MIT-licensed.

What happens to my code?

In the default hosted mode, source files are sent over HTTPS, scanned with Trivy and Opengrep, and deleted right after. In local mode your code never leaves your computer.

Give your agent a second opinion.

Start free

Related guides