Skip to main content
skill CX Codex

security-auditor · curiositech — Claude Code skill: scan dependencies and secrets

security-auditor runs dependency checks, finds hardcoded secrets, and flags injection or XSS risks in source code. Useful before shipping or when reviewing a pull request.

MIT 243 installs ★ 274 updated 2026-10-30

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add curiositech/some_claude_skills --skill security-auditor -a claude-code
Open on GitHub

What security-auditor does

The skill wires together three scans. npm audit and pip-audit report known CVEs in dependencies. A separate pass catches secrets using regex patterns and Shannon entropy on long strings. Static analysis then looks for classic code-level issues from the OWASP Top 10.

Bash access is locked to npm audit:*, pip-audit:*, grep:* and find:*. Scripts like full-audit.sh, detect-secrets.sh and owasp-check.py live inside the skill. Output lands in a JSON report with severity levels and locations.

It does not cover runtime protection: no WAF setup, no rate limiting, no firewall rules. SOC2 or HIPAA work is also out of scope. For those, you need different tooling. The skill also skips actual exploitation, so it prepares you for a pentest without performing one.

What it helps with

  • list vulnerable npm and pip dependencies
  • spot committed API keys and private keys
  • check code against the OWASP Top 10
  • produce a security report for stakeholders
  • run a pre-PR security sweep

Example prompts for the agent

  • Run a full security audit on this project
  • Check dependencies for critical CVEs
  • Scan src/ for leaked secrets and credentials

How to install security-auditor

1Skills CLI (Vercel)

npx skills add curiositech/some_claude_skills --skill security-auditor -a claude-code

2Manually: put the files in place

~/.claude/skills/security-auditor/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/security-auditor/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about security-auditor

How do I install security-auditor in Claude Code?

Run npx skills add curiositech/some_claude_skills --skill security-auditor -a claude-code. The skill file ends up at ~/.claude/skills/security-auditor/SKILL.md.

What does security-auditor do?

It scans a codebase for vulnerabilities: dependency audits via npm audit and pip-audit, secret detection using entropy analysis, and static checks for injection and XSS. Findings come back as a JSON report with severity and remediation notes.

What is security-auditor not for?

It does not handle WAF configuration, rate limiting, network rules, or compliance work like SOC2/HIPAA. The skill detects vulnerabilities, it does not exploit them or manage infrastructure.

Source text

SKILL.md · MIT
---
name: security-auditor
description: Security vulnerability scanner and OWASP compliance auditor for codebases. Dependency scanning (npm audit, pip-audit), secret detection (high-entropy strings, API keys), SAST for injection/XSS
  vulnerabilities, and security posture reports. Activate on 'security audit', 'vulnerability scan', 'OWASP', 'secret detection', 'dependency check', 'CVE', 'security review', 'penetration testing prep'.
  NOT for runtime WAF configuration (use infrastructure tools), network security/firewalls, or compliance certifications like SOC2/HIPAA (legal/organizational).
allowed-tools: Read,Write,Edit,Bash(npm audit:*,pip-audit:*,grep:*,find:*),Grep,Glob
metadata:
  category: Code Quality & Testing
  pairs-with:
  - skill: devops-automator
    reason: Secure deployment pipelines
  - skill: mcp-creator
    reason: Secure MCP server development
  tags:
  - security
  - owasp
  - vulnerabilities
  - sast
  - dependencies
---

# Security Auditor

Comprehensive security scanning for codebases. Identifies vulnerabilities before they become incidents. Focuses on actionable findings with remediation guidance.

## When to Use

**Use for:**
- Pre-deployment security audits
- Dependency vulnerability scanning
- Secret/credential leak detection
- Code-level SAST (Static Application Security Testing)
- Security posture reports for stakeholders
- OWASP Top 10 compliance checking
- Pre-PR security reviews

**Do NOT use for:**
- Runtime security (WAF, rate limiting) - use infrastructure tools
- Network security/firewall rules - use cloud/DevOps skills
- SOC2/HIPAA/PCI compliance - requires legal/organizational process
- Penetration testing execution - this is detection, not exploitation

## Quick Start

### Full Security Audit
```bash
# Run comprehensive scan
./scripts/full-audit.sh /path/to/project

# Output: security-report.json + summary
```

### Quick Checks
```bash
# Dependency vulnerabilities only
npm audit --json > deps-audit.json

# Secret detection only
./scripts/detect-secrets.sh /path/to/project

# OWASP check specific file
./scripts/owasp-check.py /path/to/file.js
```

## Core Scanning Capabilities

### 1. Dependency Scanning

| Package Manager | Command | Severity Levels |
|-----------------|---------|-----------------|
| npm | `npm audit --json` | critical, high, moderate, low |
| yarn | `yarn audit --json` | same as npm |
| pip | `pip-audit --format json` | critical, high, medium, low |
| cargo | `cargo audit --json` | same |

**Decision Tree:**
```
Critical severity found?
├── YES → Block deployment, immediate fix required
│   └── Check if patch available → npm audit fix --force
├── NO → High severity?
    ├── YES → Fix within sprint, document if deferred
    └── NO → Low/Moderate → Track, fix during maintenance
```

### 2. Secret Detection

**High-Risk Patterns:**
- API keys: `/[A-Za-z0-9_]{20,}/` near "key", "api", "secret"
- AWS credentials: `AKIA[0-9A-Z]{16}`
- Private keys: `-----BEGIN (RSA|EC|OPENSSH) PRIVATE KEY-----`
- JWT tokens: `eyJ[A-Za-z0-9_-]+\.eyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+`
- Connection strings: `://[^:]+:[^@]+@`

**Entropy Analysis:**
- Shannon entropy > 4.5 on strings > 20 chars = suspicious
- Base64-encoded blobs in source = investigate

**False Positive Handling:**
```
Secret-like pattern found?
├── In test file? → Lower severity, document
├── In example/docs? → Check if placeholder
├── High entropy + near "password"/"secret" → High confidence
└── In .env.example? → Acceptable if placeholder values
```

### 3. OWASP Top 10 Static Analysis

| # | Vulnerability | Detection Pattern |
|---|---------------|-------------------|
| A01 | Broken Access Control | Missing auth checks on routes |
| A02 | Cryptographic Failures | Weak algorithms (MD5, SHA1 for passwords) |
| A03 | Injection | Unparameterized queries, eval(), innerHTML |
| A04 | Insecure Design | Hardcoded credentials, missing rate limits |
| A05 | Security Misconfiguration | Debug mode in prod, default credentials |
| A06 | Vulnerable Components | Known CVEs in dependencies |
| A07 | Auth Failures | Weak password policies, session issues |
| A08 | Integrity Failures | Unsigned updates, untrusted deserialization |
| A09 | Logging Failures | Sensitive data in logs, missing audit trails |
| A10 | SSRF | Unvalidated URL inputs to fetch/request |

### 4. Language-Specific Checks

**JavaScript/TypeScript:**
- `eval()`, `new Function()` - code injection
- `innerHTML`, `outerHTML` - XSS vectors
- `document.write()` - DOM-based XSS
- `child_process.exec()` with user input - command injection
- Regex without timeout - ReDoS vulnerability

**Python:**
- `pickle.loads()` with untrusted data - arbitrary code execution
- `yaml.load()` without `Loader=SafeLoader` - code injection
- `subprocess.shell=True` - command injection
- `eval()`, `exec()` - code injection
- SQL string concatenation - SQL injection

**SQL:**
- String concatenation in queries - SQL injection
- `LIKE '%' + input + '%'` - injection via wildcards
- Missing parameterization - critical vulnerability

## Anti-Patterns

### Anti-Pattern: Security by Obscurity
**What it looks like**: "Nobody will find this hardcoded password"
**Why wrong**: Secrets in source always leak eventually
**Instead**: Environment variables, secret managers, zero hardcoded secrets

### Anti-Pattern: Audit Fatigue
**What it looks like**: 500 findings, all "medium", team ignores
**Why wrong**: Critical issues buried in noise
**Instead**: Prioritize by exploitability, start with critical/high only

### Anti-Pattern: Fix Without Understanding
**What it looks like**: `npm audit fix --force` without review
**Why wrong**: May introduce breaking changes, doesn't address root cause
**Instead**: Review each fix, understand the vulnerability, test after

### Anti-Pattern: One-Time Audit
**What it looks like**: "We did a security audit last year"
**Why wrong**: New CVEs daily, code changes constantly
**Instead**: CI/CD integration, weekly automated scans minimum

## Security Report Format

```json
{
  "summary": {
    "critical": 0,
    "high": 2,
    "medium": 5,
    "low": 12,
    "informational": 8
  },
  "findings": [
    {
      "id": "SEC-001",
      "severity": "high",
      "category": "A03:Injection",
      "title": "SQL Injection in user search",
      "location": "src/api/users.js:45",
      "description": "User input concatenated directly into SQL query",
      "evidence": "const query = `SELECT * FROM users WHERE name = '${input}'`",
      "remediation": "Use parameterized queries: db.query('SELECT * FROM users WHERE name = $1', [input])",
      "references": ["https://owasp.org/www-community/attacks/SQL_Injection"]
    }
  ],
  "recommendations": [
    "Implement parameterized queries across all database access",
    "Add input validation layer",
    "Enable SQL query logging for monitoring"
  ]
}
```

## CI/CD Integration

### GitHub Actions Example
```yaml
security-scan:
  runs-on: ubuntu-latest
  steps:
    - uses: actions/checkout@v4
    - name: Run security audit
      run: |
        npm audit --json > audit.json
        ./scripts/detect-secrets.sh . > secrets.json
        ./scripts/generate-report.py
    - name: Fail on critical
      run: |
        if jq '.summary.critical > 0' report.json; then
          echo "Critical vulnerabilities found!"
          exit 1
        fi
```

## Scripts (in `scripts/` folder)

| Script | Purpose |
|--------|---------|
| `full-audit.sh` | Comprehensive security scan |
| `detect-secrets.sh` | High-entropy string and pattern detection |
| `owasp-check.py` | OWASP Top 10 static analysis |
| `generate-report.py` | Combine findings into unified report |

## Expert vs Novice Approach

| Novice | Expert |
|--------|--------|
| Runs audit once before release | CI/CD integration, every commit |
| Focuses on tool output only | Understands vulnerability context |
| Fixes everything or nothing | Triages by exploitability |
| Uses one scanner | Layers multiple tools |
| Ignores false positives | Tunes detection rules |

## Success Metrics

| Metric | Target |
|--------|--------|
| Critical/High pre-production | 0 |
| Mean time to remediate critical | < 24 hours |
| False positive rate | < 10% |
| Scan coverage | 100% of deployable code |

## Reference Files

- `references/owasp-top-10-2024.md` - Detailed OWASP guidance
- `references/secret-patterns.md` - Comprehensive regex patterns
- `references/remediation-playbook.md` - Fix guidance by vulnerability type
- `references/ci-cd-templates.md` - Integration examples
- `scripts/` - Working security scanning scripts

---

**Detects**: Dependency CVEs | Secret leaks | Injection vulnerabilities | OWASP violations | Security misconfigurations

**Use with**: site-reliability-engineer (deployment gates) | code-review (PR security checks)

© curiositech · MIT · curiositech/some_claude_skills

Similar skills

All skills for Security →

security-auditor by other authors comes first.

security-auditor rmyndharis The security-auditor Claude Code skill reviews application security and development pipelines. It checks threats, vulnerabilities, and existing controls, then suggests remediation steps. CX Codex +1 128installs security-auditor zhaono1 security-auditor — a skill that hunts vulnerabilities in your code: walks the OWASP Top 10, checks configs, dependencies and leaked secrets. Useful before a release or a review. CX Codex +1 1,100installs security-auditor ovachiever security-auditor scans your code for OWASP Top 10 patterns: SQL injection, XSS, exposed secrets, broken auth. Fires on file changes and before deployments. CX Codex +1 784installs security-testing proffesor-for-testing security-testing is a Claude Code skill that checks projects for vulnerabilities using the OWASP Top 10 approach. It activates for auth audits, injection testing, and security automation. CX Codex +1 152installs qe-security-compliance proffesor-for-testing qe-security-compliance runs code security audits, dependency vulnerability scans, secret detection, and compliance checks for OWASP and SOC2. CX Codex +1 120installs senior-secops borghei senior-secops is a Claude Code skill that scans code for vulnerabilities, checks dependencies for CVEs and reviews SOC 2, PCI-DSS, HIPAA and GDPR controls before a release or audit. CX Codex +1 133installs sentinel simota sentinel — a skill for Claude Code conducts static application security testing across codebases. Pinpoints hardcoded secrets, injection vectors, and dependency vulnerabilities prior to merge. CX Codex +1 106installs security-review official github security-review reviews code and dependencies for vulnerabilities, exposed secrets, and access-control flaws. Use it before a release or when auditing a project path. CX Codex +1 5,500installs draft-security-advisory frappe draft-security-advisory transforms vulnerability reports into publication-ready GitHub Security Advisories without leaking payloads, endpoints, or file paths. CX Codex +1 724installs

From the same set180

The whole set →
drone-cv-expert drone-cv-expert — a skill for autonomous drones and computer vision: flight control, SLAM, object detection, path planning. Activates on drone, UAV, SLAM and related terms. CX Codex +1 259installs project-management-guru-adhd project-management-guru-adhd is a Claude Code skill that helps ADHD engineers manage multiple projects, protecting hyperfocus and reducing context switches. CX Codex +1 253installs design-system-creator The design-system-creator skill builds design systems with tokens, CSS structure, component docs, and style guides. Use it when a project needs a shared UI foundation. CX Codex +1 250installs fullstack-debugger fullstack-debugger troubleshoots Next.js 15, Cloudflare Workers, and Supabase apps layer by layer. Fixes auth errors, broken RLS policies, CORS, and build failures. CX Codex +1 244installs native-app-designer native-app-designer — a skill for iOS, Mac and web app design that skips the generic AI look. It steers the agent toward spring physics, motion timing and details that make an interface feel human. CX Codex +1 241installs large-scale-map-visualization large-scale-map-visualization — a skill for web maps carrying tens of thousands of markers. It picks clustering libraries, viewport loading, and rendering tricks that keep the browser responsive. CX Codex +1 240installs api-architect api-architect is a Claude Code skill that guides REST, GraphQL, and gRPC API design, from contracts and schemas to documentation and specification checks. CX Codex +1 235installs vaporwave-glassomorphic-ui-designer vaporwave-glassomorphic-ui-designer — a skill for designing photo and memory apps with vaporwave and glassmorphic looks. Use it when you need SwiftUI interfaces with frosted glass, neon pastels, and a retro-futuristic feel. CX Codex +1 234installs

Project sponsors

Companies that keep this analytics open