agentleFS
ucdavisucdavis/ai-skills-registry/skills/security-general/SKILL.md

security-general

Skill9 starsChanged 8 months agoMITView on GitHub

Security checklist: OWASP top 10, secret scanning, input validation, and auth patterns

The file

We split this skill into the rules it gives an agent

9 rules. About 0 are common, 8 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈8

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use allowlists, not denylists, for permitted values.

    line 10
  2. Very specific:

    Command injection: never pass user input to exec, spawn, or shell commands unsanitized.

    line 16
  3. Distinctive:

    LDAP/XPath/NoSQL: use parameterized queries where available.

    line 18
  4. Distinctive:

    Use short-lived access tokens (15 min) + refresh tokens.

    line 23
  5. Distinctive:

    Never roll your own crypto — use established, audited libraries.

    line 24
  6. Distinctive:

    Never hardcode secrets in source code or config files.

    line 28
  7. Distinctive:

    Use environment variables or a secrets manager (Vault, AWS Secrets Manager, GCP Secret Manager).

    line 29
  8. Distinctive:

    Use framework-provided escaping — never write your own.

    line 35
  9. Distinctive:

    Never expose stack traces or internal details to end users.

    line 39

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “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 Checklist

Input Validation

  • Validate all inputs at system boundaries: API endpoints, CLI args, file uploads, env vars.
  • Use allowlists, not denylists, for permitted values.
  • Reject oversized inputs (prevent DoS via resource exhaustion).
  • Validate content type, not just file extension.

Injection Prevention

  • SQL: parameterized queries only. Never concatenate user input into SQL strings.
  • Command injection: never pass user input to exec, spawn, or shell commands unsanitized.
  • Path traversal: normalize and validate file paths. Reject ../ sequences.
  • LDAP/XPath/NoSQL: use parameterized queries where available.

Authentication & Authorization

  • Deny by default: if no explicit permission grant, deny the request.
  • Validate JWTs: signature, exp, iss, aud claims.
  • Use short-lived access tokens (15 min) + refresh tokens.
  • Never roll your own crypto — use established, audited libraries.
  • Rate-limit login and sensitive endpoints.

Secrets Management

  • Never hardcode secrets in source code or config files.
  • Use environment variables or a secrets manager (Vault, AWS Secrets Manager, GCP Secret Manager).
  • Scan commits for secrets with git-secrets, truffleHog, or gitleaks in CI.
  • Rotate leaked secrets immediately — assume they are compromised.

Output Encoding

  • Encode for the context: HTML entities for HTML, URL encoding for URLs.
  • Use framework-provided escaping — never write your own.
  • Set Content-Security-Policy, X-Content-Type-Options, X-Frame-Options headers.

Error Handling

  • Never expose stack traces or internal details to end users.
  • Log full errors server-side with correlation IDs; return generic messages to clients.

Dependencies

  • Audit regularly: npm audit, pip-audit, trivy, OWASP Dependency-Check.
  • Pin versions in production. Review changelogs before upgrading.
  • Remove unused dependencies.

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.