agentleFS
alex-voloshin-devalex-voloshin-dev/ai-skills/.agents/skills/security-scan/SKILL.md

security-scan

Skill2 starsChanged 7 months agoMITView on GitHub

Security scan workflow — dependency audit, OWASP checklist, secrets scan, vulnerability report. Applies software-engineer role with security focus. Use standalone or as part of code review.

49 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use springboot-security, django-security 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.
  • FaisalAlqarniSkill

    springboot-security

    Spring Security best practices for authn/authz, validation, CSRF, secrets, headers, rate limiting, and dependency security in Java Spring Boot services.

    Also in 5 projects that use this

  • johnrtiptonSkill

    django-security

    This skill should be used when conducting security reviews, auditing Django applications, hardening security settings, implementing OWASP Top 10 protections, managing secrets, or ensuring multi-tenant security isolation. Provides automated security auditor that scans settings, code, dependencies, and multi-tenant configurations with auto-fix capabilities.

    Also in 5 projects that use this

  • JamkrisSkill

    security-bounty-hunter

    Hunt for exploitable, bounty-worthy security issues in repositories. Focuses on remotely reachable vulnerabilities that qualify for real reports instead of noisy local-only findings.

    Also in 3 projects that use this

  • joneqianSkill

    postgres-patterns

    PostgreSQL database patterns for query optimization, schema design, indexing, and security. Based on Supabase best practices.

    Also in 5 projects that use this

  • Microsoft AzureSkill

    iterative-retrieval

    Max-3-cycle protocol for agent sub-tasks with WHY context and coordinator validation. Use when spawning sub-agents to complete scoped work.

    Also in 5 projects that use this

  • LangChainSkill

    docker-patterns

    Best practices for Docker containerization and multi-stage builds

    Also in 5 projects that use this

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 43 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Read AGENTS.md and project config to determine:

    line 18
  2. Distinctive:

    Run the project's dependency vulnerability scanner:

    line 26
  3. Distinctive:

    Check for common secret patterns in source files:

    line 58
  4. Very specific:

    Use code-review skill's security-checklist.md for detailed checks.

    line 87
  5. Distinctive:

    No secrets in Dockerfile or image layers

    line 95
  6. Very specific:

    No hardcoded credentials in .tf files

    line 106

“Common” is measured: kept by at least 6 in 10 of the 43 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 Scan

Automated security audit for the project. Checks dependencies for known vulnerabilities, scans for hardcoded secrets, and reviews code against OWASP guidelines.

1. Detect Project Stack

Read AGENTS.md and project config to determine:

  • Language(s) and dependency managers
  • Infrastructure (Docker, Kubernetes, Terraform)
  • Existing security tools (Snyk, Trivy, OWASP dependency-check, etc.)

2. Dependency Audit

Run the project's dependency vulnerability scanner:

StackCommand
Node.js (npm)npm audit
Node.js (pnpm)pnpm audit
Node.js (yarn)yarn audit
Python (pip)pip-audit or safety check
Python (poetry)poetry audit or pip-audit
Java (Maven)mvn org.owasp:dependency-check-maven:check
Java (Gradle)gradle dependencyCheckAnalyze
Gogovulncheck ./...
.NETdotnet list package --vulnerable
Dockertrivy image <image-name> or docker scout cves

Classify findings by severity:

SeverityAction
Critical / HighMust fix before merge. Upgrade dependency or apply workaround
MediumShould fix. Schedule if no immediate upgrade available
LowTrack. Fix in next maintenance cycle

3. Secrets Scan

Scan the codebase for hardcoded secrets:

// turbo
git log --diff-filter=A --name-only --pretty=format: | sort -u

Check for common secret patterns in source files:

  • API keys (AWS, GCP, GitHub, Slack)
  • Private keys (RSA, EC, SSH)
  • Connection strings with credentials
  • JWT tokens and bearer tokens
  • Passwords in config files

Tools (if available):

  • gitleaks detect --source .
  • trufflehog filesystem .
  • detect-secrets scan

4. OWASP Top 10 Review

Manual code review against OWASP Top 10 (2021):

#RiskWhat to Check
A01Broken Access ControlAuthorization checks on every endpoint, CORS policy, directory traversal
A02Cryptographic FailuresTLS enforcement, password hashing, data encryption, no weak algorithms
A03InjectionSQL/NoSQL/OS command injection, parameterized queries, input validation
A04Insecure DesignThreat model, rate limiting, business logic flaws
A05Security MisconfigurationDefault credentials, debug mode, unnecessary features, error messages
A06Vulnerable ComponentsDependency audit results (Step 2)
A07Auth FailuresBrute force protection, session management, MFA
A08Data Integrity FailuresCI/CD pipeline security, deserialization, update verification
A09Logging FailuresSecurity event logging, no PII in logs, monitoring
A10SSRFServer-side request validation, allowlists for external calls

Use code-review skill's security-checklist.md for detailed checks.

5. Infrastructure Security (if applicable)

Docker

  • Base images from trusted registries
  • No latest tag — pinned versions
  • Non-root user in container
  • No secrets in Dockerfile or image layers
  • Minimal base image (distroless/alpine)

Kubernetes

  • Pods run as non-root with read-only filesystem
  • Network policies restrict traffic
  • Secrets in Kubernetes Secrets or external vault
  • Resource limits set on all containers
  • RBAC follows least-privilege

Terraform

  • No hardcoded credentials in .tf files
  • State file encrypted and access-controlled
  • Security groups follow least-privilege
  • Encryption enabled for storage and databases

6. Report

## Security Scan Report

### Summary
- **Risk level**: LOW / MEDIUM / HIGH / CRITICAL
- **Scan date**: [date]
- **Scope**: [what was scanned]

### Dependency Vulnerabilities
| Package | Current | Fixed In | Severity | CVE |
|---------|---------|----------|----------|-----|
| [pkg]   | [ver]   | [ver]    | [sev]    | [id]|

### Secrets Found
- [ ] [file:line] — [type of secret] — **ACTION: Remove and rotate**

### OWASP Findings
| Risk | Status | Details |
|------|--------|---------|
| A01 Access Control | ✅/❌ | [details] |
| A02 Crypto | ✅/❌ | [details] |
| ... | ... | ... |

### Infrastructure
- Docker: [pass/fail/N/A]
- Kubernetes: [pass/fail/N/A]
- Terraform: [pass/fail/N/A]

### Recommended Actions
1. **Critical**: [action] — [deadline]
2. **High**: [action] — [deadline]
3. **Medium**: [action] — [schedule]

Integration

  • Called by: code-review skill (security layer), pre-commit skill (optional)
  • Roles: software-engineer role (security focus), devops-engineer role (infra scan), devops-architect role (supply chain security, GHAS, SBOM/SLSA)
  • Skills: code-review skill (security checklist)

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.