/akira-lite:akira-reviewfrom akira-lite
Use when a developer wants a hard, high-recall but token-light security review of their own code before committing, pushing, or opening a PR, or a full audit of a component/repo. Deterministic scanners do the bulk; the model reasons only about cross-file taint and missing controls; findings are reported by confidence tier with fixes. Triggers on "security review", "deep security review", "audit this for security", "is this safe to merge", "review my code for vulnerabilities", or "/akira-review".
Ships in akira-lite. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
High recall, low cost. Three layers, each catching what the others miss: scanners (signatures, secrets, CVEs, IaC), cross-file taint (source to sink), and a missing-control audit (access-control and logic gaps no scanner sees). Findings are ranked by confidence, not deleted.
Token cost = code read into context + text generated. Minimize both:
grep -nE '@app\.(get|post|put|delete|patch)|Depends|middleware|Authorization' <file>.
Use codegraph_search/codegraph_files for named symbols and codegraph_trace
between two names; do not rely on a prose context query to find the attack surface.
Fall back to grep + sed -n ranges when no graph is present.Also check for a code graph: if the codegraph MCP is present and the target repo
has a .codegraph/ index (confirm with codegraph_status), use it for pass A and
pass C below and note "code graph: ok" in the ledger. If absent, offer
codegraph init -i once, then fall back to grep/sed and note "code graph: none".
Presence is not enough; a broken tool reports a working layer while producing nothing. Run each tool; found means it actually executes. Backgrounded for speed.
for t in semgrep gitleaks trufflehog osv-scanner trivy checkov pip-audit npm; do
{ command -v "$t" >/dev/null 2>&1 \
&& ("$t" --version >/dev/null 2>&1 && echo "$t: ok" || echo "$t: BROKEN") \
|| echo "$t: MISSING"; } &
done; wait
Treat BROKEN like MISSING: a degraded layer. If a layer has no working tool, say so in the ledger ("secrets: no scanner - recall degraded").
Recommend-and-rerun rule: whenever any tool is MISSING or BROKEN, do NOT block.
Complete the review with the layers that work, then, at the end, tell the developer
exactly which layer was degraded, the one-liner to fix it, and that re-running the
scan afterwards gives full coverage. If every tool is present and working, say
nothing about installs. Install one-liners and the exact per-tool commands are in
references/scanners.md; for a broken tool, recommend a reinstall (e.g.
pipx reinstall semgrep).
git diff HEAD; if empty, diff against the repo's default
branch (main, master, or whatever origin/HEAD points to). Cheap..git or git is unavailable, there is no diff.
Review the whole tree in deep mode, or a path the user names, and note "no git:
reviewing " in the ledger.A. Map surface. List every entry point in scope BY NAME: routes/resolvers,
queue/event consumers, CLI/cron, file I/O, subprocess/exec, deserializers,
template renders, outbound HTTP, auth boundaries, raw SQL. With a code graph,
query these by name instead of reading files. This list is the termination
condition for pass F.
B. Scan (subprocesses, run in parallel, keep all raw hits). Exact commands per
layer (SAST, secrets, deps, IaC) are in references/scanners.md. Scope to
changed files in quick mode, to the path in deep mode.
C. Taint. For each entry point (top-ranked first), trace untrusted input source
to sink across files. With a code graph, trace source to sink in one call
(it bridges dynamic hops grep misses), then read only the bodies on that path;
otherwise follow the call chain with grep/sed. This finds what scanners cannot.
D. Missing-control audit. For each control category (Step 3), ask "is it present
on this reachable path?" With a code graph, list a sensitive sink's callers and
check each routes through an auth/ownership guard. A missing control is a
finding even with no scanner hit.
E. Merge and tier. Dedup by file:line + class; assign tier + severity (Step 4).
F. Completeness gate. Mark every pass-A entry point traced or not-traced by name.
Loop until the list is exhausted or the budget is hit. Report "N/M traced".
Audit against the full checklist in references/checklist.md (OWASP Web/API/LLM +
ASVS controls, each mapped to a CWE). The classes, highest-impact first:
Load references/checklist.md for the per-class hints and CWE mappings.
Tier every finding; delete nothing real:
Severity (derive from class, do not re-reason):
## Security review: <scope> [mode, escalated: y/n]
Coverage ledger
- Tools: semgrep BROKEN | gitleaks ok | osv-scanner MISSING | trivy ok
- Layers: SAST degraded | secrets ok | deps degraded | IaC ok
- Code graph: ok (used for surface + taint) | or: none (grep fallback)
- Entry points: 18/18 traced (or 16/18, untraced: worker.py:consume [budget])
- Files reviewed: <n> | skipped: <list + why> | suppressed: <n>
### [CRITICAL][Confirmed] <title>
- File: path:line Class: <e.g. SQL injection>
- Path: input X (source) -> ... -> sink Y. Attacker gains Z.
- Fix: specific change, with a snippet.
### [HIGH][Likely] ... (What confirms it: <the one check>)
### [MEDIUM][Needs-verification] ... (To verify: <exact thing>)
End with: the single highest-impact fix. Then, only if a layer was degraded, one line naming it, the install/reinstall one-liner to restore it, and that re-running the scan afterwards gives full coverage. If nothing was degraded, omit that line.
Change only the lines needed to close the finding, no refactors. Show the diff and the finding it closes, then re-review the changed lines for new holes.
Reviews your own code (defensive, not a live-target pentest). Recall is only as strong as the layers that ran; a degraded layer is stated, never hidden. When in doubt on a diff that touches auth or data, run deep on that component.
evals/GROUND_TRUTH.md (opens in a new tab)evals/README.md (opens in a new tab)evals/evals.json (opens in a new tab)evals/files/01-sqli/app.py (opens in a new tab)evals/files/02-command-injection/run.py (opens in a new tab)evals/files/03-idor/app.py (opens in a new tab)evals/files/04-hardcoded-secret/config.py (opens in a new tab)evals/files/05-ssrf/fetch.py (opens in a new tab)evals/files/06-xss/render.js (opens in a new tab)evals/files/07-deserialization/loader.py (opens in a new tab)evals/files/08-weak-crypto/auth.py (opens in a new tab)evals/files/09-crossfile-sqli/routes.py (opens in a new tab)evals/files/09-crossfile-sqli/store.py (opens in a new tab)evals/files/10-safe-parameterized/db.py (opens in a new tab)evals/files/11-safe-authz/app.py (opens in a new tab)evals/files/12-safe-bcrypt/auth.py (opens in a new tab)evals/triggering.json (opens in a new tab)references/checklist.md (opens in a new tab)references/scanners.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub kalpmodi/akira-lite --plugin akira-lite