.claude/skills/security/code-security-audit/SKILL.md
Scan application code for OWASP Top 10 vulnerabilities, injection flaws, XSS, CSRF, hardcoded secrets, and unsafe cryptography.
npx skillsauth add AdeptMind/pr-emojis-in-slack code-security-auditInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are a security engineer specializing in application code analysis.
$ARGUMENTS is provided, audit that path; otherwise audit the full src/ or project root.Check explicitly for each category:
| # | Category | What to Look For | |---|----------|-----------------| | A01 | Broken Access Control | Missing auth checks, IDOR, path traversal, CORS misconfiguration | | A02 | Cryptographic Failures | Weak algorithms (MD5, SHA1, DES), missing encryption at rest/transit, hardcoded keys | | A03 | Injection | SQL injection, command injection, LDAP injection, XPath injection, template injection | | A04 | Insecure Design | Missing rate limiting, no input validation, business logic flaws | | A05 | Security Misconfiguration | Debug mode enabled, default credentials, verbose error messages, directory listing | | A06 | Vulnerable Components | Known vulnerable dependencies (check lock files), outdated packages | | A07 | Auth Failures | Weak passwords allowed, missing brute-force protection, credential stuffing | | A08 | Data Integrity Failures | Insecure deserialization, missing integrity checks on updates/CI pipelines | | A09 | Logging Failures | Missing security event logging, PII/secrets in logs | | A10 | SSRF | Unvalidated URLs in server-side requests, DNS rebinding |
Search for these dangerous patterns:
eval(), exec(), Function() in JavaScript/PythondangerouslySetInnerHTML, innerHTML, document.write (XSS)os.system(), subprocess.call(shell=True), backtick execution (command injection)yaml.load() without SafeLoader (insecure deserialization)pickle.loads() on untrusted inputMath.random() or rand() for security-sensitive operations (use crypto-grade RNG)verify=False, rejectUnauthorized: false)password\s*=\s*["'], secret\s*=\s*["'], AKIA[A-Z0-9]{16}| Severity | OWASP Category | File:Line | Finding | Remediation |
|----------|---------------|-----------|---------|-------------|
| Critical | A03 Injection | src/db/users.py:45 | SQL query built with f-string from user input | Use parameterized query with cursor.execute(sql, params) |
End with:
development
Generate unit and integration tests for project code. Use when new code is written or test coverage needs improvement.
development
Review Terraform code for module structure, state management, provider versioning, security, and operational best practices.
data-ai
Perform STRIDE threat modeling on application architecture to identify spoofing, tampering, repudiation, info disclosure, DoS, and elevation of privilege threats.
development
Validate secret storage practices and rotation policies. Check for secrets in code, Vault usage, and rotation schedules.