agentleFS
blackbenjaminblackbenjamin/etps/.claude/skills/security-review/SKILL.md

security-review

Skill1 starsChanged 11 months agoMITView on GitHub

Audit code for OWASP Top 10 vulnerabilities including SQL injection, input validation, authentication, XSS, command injection, and exception handling. Use when reviewing security, checking for vulnerabilities, or before commits.

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

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

  • 0

    Common

    Most of the 167 edited versions we read keep these.

  • 2

    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:

    Read endpoints: 60 requests/minute

    line 74
  2. Distinctive:

    Use the reviewer agent for security checks

    line 85

“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 for ETPS

Pre-Commit Security Checklist

1. Injection Prevention

  • Use SQLAlchemy ORM (parameterized queries)
  • Validate all inputs with Pydantic schemas
  • Never use raw SQL or string concatenation
# GOOD - ORM
user = db.query(User).filter(User.id == user_id).first()

# BAD - raw SQL (NEVER do this)
db.execute(f"SELECT * FROM users WHERE id={user_id}")

2. Input Validation

  • Bounds check all parameters (page size, limits)
  • Validate string lengths with Field(max_length=...)
  • Whitelist enum values
  • Request body size limits in schemas
class MyRequest(BaseModel):
    name: str = Field(..., min_length=2, max_length=100)
    count: int = Field(..., gt=0, le=100)

3. Authentication/Authorization

  • No hardcoded secrets in code
  • Use environment variables for API keys
  • Check user permissions before operations
  • Validate user_id ownership

4. Exception Handling

  • No bare except: statements
  • Use specific exception types
  • Don't expose stack traces to users
  • Log errors with context
# BAD
try:
    something()
except:
    pass

# GOOD
try:
    something()
except ValueError as e:
    logger.error(f"Invalid value: {e}")
    raise HTTPException(status_code=400, detail="Invalid input")

5. Regex DoS Prevention

  • Pre-compile regex patterns
  • Limit input length before regex
  • Test with large/malicious inputs

6. Data Protection

  • No PII in logs
  • HTTPS in production
  • Sanitize error messages

Rate Limiting (Active)

  • Generation endpoints: 10 requests/minute
  • Read endpoints: 60 requests/minute

Security Commands

cd backend
bandit -r . -ll --exclude ./tests  # Security scan
python -m pytest tests/test_security.py -v  # Security tests

Best Practices

  1. Review code before every commit
  2. Use the reviewer agent for security checks
  3. Keep dependencies updated
  4. Document security decisions

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.