agentleFS
Cor-IncorporatedCor-Incorporated/claude-code-skills/skills/security-review/SKILL.md

security-review

Skill5 starsChanged 2 months agoMITView on GitHub

Run a security review against code changes or files. Covers OWASP Top 10: secrets management, input validation, SQL injection, XSS, CSRF, auth/authz, rate limiting, and sensitive data exposure. Use when adding auth, handling user input, creating API endpoints, working with secrets, implementing payments, or integrating third-party APIs. Triggers: 'security review', 'check for vulnerabilities', 'audit this endpoint', 'is this safe'. Do NOT use for general code review, performance optimization, or UI/UX feedback.

  • Reads credentials

192 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use linkerd-patterns, dependency-cve-sweep and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • xfstudioSkill

    linkerd-patterns

    Implement Linkerd service mesh patterns for lightweight, security-focused service mesh deployments. Use when setting up Linkerd, configuring traffic policies, or implementing zero-trust networking with minimal overhead.

    Also in 5 projects that use this

  • berntpoppSkill

    dependency-cve-sweep

    Use when handling Dependabot PRs, CodeQL/Trivy alerts, or doing a routine dependency/CVE sweep for this repo.

    Also in 12 projects that use this

  • berntpoppSkill

    fleet-standard-adoption

    Use when bringing this repo into compliance with a GeneFoundry fleet standard (tool-naming, response-envelope, container-hardening, versioning, MCP transport, or logging) or closing its tracking issue.

    Also in 12 projects that use this

  • HABUBUSSSkill

    project-guidelines-example

    Also in 16 projects that use this

  • niloykumarbarmanSkill

    agent-sort

    Build an evidence-backed ECC install plan for a specific repo by sorting skills, commands, rules, hooks, and extras into DAILY vs LIBRARY buckets using parallel repo-aware review passes. Use when ECC should be trimmed to what a project actually needs instead of loading the full bundle.

    Also in 13 projects that use this

  • royaluniondesign-sysSkill

    configure-ecc

    Interactive installer for Everything Claude Code — guides users through selecting and installing skills and rules to user-level or project-level directories, verifies paths, and optionally optimizes installed files.

    Also in 11 projects that use this

  • +2 more from berntpopp

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 167 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If a finding has no clear fix (e.g., third-party library vulnerability with no patch), report it with severity and recommend mitigation …

    line 57
  2. Distinctive:

    If the codebase uses patterns not covered here, flag them as "NEEDS MANUAL REVIEW" with the reason.

    line 58
  3. Distinctive:

    If no vulnerabilities are found, explicitly state "No issues found" with the scope of the review (files examined, checks performed).

    line 59

“Common” is measured: kept by at least 6 in 10 of the 167 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Security Review

Audit code for vulnerabilities. Report each finding with: location (file:line), severity (CRITICAL/HIGH/MEDIUM/LOW), description, and fix.

Review Order (by priority)

  1. Secrets -- No hardcoded keys, tokens, or passwords. All secrets in env vars. .env* in .gitignore.
  2. Input validation -- All user input validated with Zod schemas. File uploads restricted (size, type, extension). No direct use of user input in queries.
  3. SQL injection -- All queries parameterized. No string concatenation in SQL.
  4. Auth/Authz -- Tokens in httpOnly cookies (not localStorage). Authorization checks before sensitive operations. RBAC enforced.
  5. XSS -- User HTML sanitized with DOMPurify. CSP headers configured. No unvalidated dangerouslySetInnerHTML.
  6. CSRF -- CSRF tokens on state-changing operations. SameSite=Strict on cookies.
  7. Rate limiting -- All API endpoints rate-limited. Stricter limits on expensive operations (search, AI generation).
  8. Data exposure -- No secrets in logs. Generic error messages for users. No stack traces exposed.
  9. Dependencies -- npm audit clean. Lock files committed.

Quick Checks

# Hardcoded secrets
grep -rn "sk-\|password\s*=\s*[\"']" --include="*.ts" --include="*.tsx" src/

# Missing input validation
grep -rn "req\.body\|req\.query\|req\.params" --include="*.ts" src/app/api/ | grep -v "parse\|validate\|schema"

# SQL concatenation
grep -rn "SELECT.*\${\|INSERT.*\${\|UPDATE.*\${\|DELETE.*\${" --include="*.ts" src/

# localStorage tokens
grep -rn "localStorage.*token\|localStorage.*key" --include="*.ts" --include="*.tsx" src/

Pre-Deployment Checklist

  • No hardcoded secrets
  • All inputs validated
  • All queries parameterized
  • XSS: user content sanitized, CSP configured
  • CSRF protection enabled
  • Auth: httpOnly cookies, RBAC enforced
  • Rate limiting on all endpoints
  • HTTPS enforced
  • Security headers set (CSP, X-Frame-Options, X-Content-Type-Options)
  • No sensitive data in logs or error responses
  • Dependencies audited, lock files committed
  • CORS properly configured
  • File uploads validated

Error Handling

  • If a finding has no clear fix (e.g., third-party library vulnerability with no patch), report it with severity and recommend mitigation (pin version, add wrapper, monitor advisory).
  • If the codebase uses patterns not covered here, flag them as "NEEDS MANUAL REVIEW" with the reason.
  • If no vulnerabilities are found, explicitly state "No issues found" with the scope of the review (files examined, checks performed).

References

See references/code-examples.md for detailed code patterns (secrets, validation, auth, XSS, CSRF, rate limiting, blockchain).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.