| name | security-review |
| description | Use when the user wants a focused security audit of the current diff or recent changes. Triggered by /security-review, 'security review', 'audit this for security', 'check for vulnerabilities', 'OWASP review'. Runs deeper checks than the generic review — OWASP Top 10, secrets scanning, injection vectors, auth/authz boundaries, crypto usage. Independent of the generic review skill. |
| disallowed-tools | AskUserQuestion |
Security Review — Focused Vulnerability Audit
When to Use
- User says "/security-review", "security review", "audit for security", "check for vulnerabilities", "OWASP review"
- After implementing auth, payment, file-upload, deserialization, dynamic-code, or external-integration code
- Before merging high-risk PRs (auth, billing, admin endpoints, public APIs)
Scope
Diff-based by default. Full-codebase only on explicit user request (/security-review --full or "audit the whole codebase").
Workflow
1. git status + git diff -> identify changed files
2. Read CLAUDE.md "Architecture Principles" + env vars -> understand trust boundaries
3. (If GitNexus available) gitnexus_impact on changed auth/input symbols
4. Read every changed file completely
5. Evaluate against the OWASP-focused checklist below
6. Run security-relevant automated checks (see Tooling)
7. Fix findings inline (prefer over defer; security debt compounds)
8. Output standard Security Review Results table
9. For NOT-fixed findings -> BACKLOG.md with explicit Sev: P0/P1
Checklist — OWASP Top 10 + Common Pitfalls
A01 Broken Access Control
A02 Cryptographic Failures
A03 Injection
A04 Insecure Design
A05 Security Misconfiguration
A06 Vulnerable Components
A07 Identification & Auth Failures
A08 Software & Data Integrity Failures
A09 Security Logging & Monitoring
A10 SSRF
Project-Specific
Tooling (run if available, never gate on availability)
| Tool | Command | What it catches |
|---|
gitleaks / trufflehog | gitleaks detect --source . | Committed secrets |
npm audit / pip-audit / cargo audit / bundler-audit / composer audit | per language | Vulnerable deps |
semgrep | semgrep --config auto | Pattern-based code vulnerabilities |
| Language-specific SAST | bandit / brakeman / phpstan-security | Per-language SAST |
If a tool isn't available locally -> note in report, do NOT block the review.
Severity & Fixing Rules
- All security findings default to P0 or P1. P2 only for clearly informational items.
- Never defer a P0 without explicit user override + BACKLOG entry naming the user as the deferring party.
- Fix inline — security tech debt compounds.
Report
### Security Review Results
| # | OWASP / Area | Sev | Status | Finding | Action |
|---|--------------|-----|--------|---------|--------|
| 1 | A03 Injection | P0 | Fixed | Unparameterized SQL in users.search() | Switched to bound params |
| ... |
Tools run: <list>
Summary: X findings | Y fixed | Z deferred (with explicit user override) -> Backlog
Footer:
security-review skill -- independent of generic /review
Rules
- Do not run automatically. On-demand only.
- Do not skip OWASP categories even if "looks fine" — checklist coverage > intuition.
- Do not silently lower severity. If unsure, default to higher.
- Do not commit fixes without re-running the affected tests (autonomy + zero-cost rule still applies).