Skip to content
FunCoding

Search

Search docs, Skills and MCP

code-vuln-audit

Scan code for security issues: dependency vulnerabilities (npm/pip audit), secret leaks (regex and entropy analysis), and OWASP anti-patterns like SQL injection, XSS, or command injection. Use when the user mentions security scans, vulnerability detection, secret leaks, API keys, OWASP, npm audit, pip-audit, hardcoded passwords, or code security checks.

数据库与数据4.7kskills/code-vuln-audit/SKILL.md

Install

Send this to Claude Code, Codex or Cursor. The agent checks the Skill for safety first and installs it only after you confirm.

读取 https://funcoding.ai/skills/zebbern/claude-code-guide/code-vuln-audit/install.md ,按里面的步骤帮我安装这个 Skill。

SKILL.md

code-vuln-audit

A code security scanning tool with three core scanning capabilities:

  1. Dependency Vulnerability Scanning — Automatically detects known vulnerabilities in npm / pip dependencies
  2. Secret Leak Detection — Discovers hardcoded secrets, tokens, and passwords via regex matching + Shannon entropy analysis
  3. OWASP Pattern Detection — Identifies common security anti-patterns such as SQL injection, XSS, command injection, and insecure deserialization

Quick Start

# Scan the current directory (all checks)
python3 scripts/security_scan.py .

# Scan dependencies only
python3 scripts/security_scan.py --mode deps .

# Detect secret leaks only
python3 scripts/security_scan.py --mode secrets /path/to/project

# Detect OWASP security patterns only
python3 scripts/security_scan.py --mode owasp .

# Output report in JSON format
python3 scripts/security_scan.py --format json --output report.json .

# Only show findings at high severity and above
python3 scripts/security_scan.py --severity high .

Scan Module Details

1. Dependency Vulnerability Scanning (deps)

Automatically detects the project type and invokes the appropriate tool:

Project TypeDetection FileTool Used
Node.jspackage.json + package-lock.jsonnpm audit
Pythonrequirements.txt / pyproject.toml / Pipfilepip-audit

If the corresponding audit tool is not installed, a helpful message is displayed instead of an error.

2. Secret Leak Detection (secrets)

Detection is performed in two ways:

Regex Matching: Covers common secret formats

Secret TypeExample Pattern
AWS Access Key20-character string starting with AKIA
GitHub TokenStarts with ghp_ or github_pat_
Slack TokenStarts with xoxb- or xoxp-
Stripe KeyStarts with sk_live_ or pk_live_
Private Key File-----BEGIN PRIVATE KEY-----
Generic API KeyFormat like api_key = "..."
Credentials in URLhttps://user:pass@host
JWT TokeneyJ... format

Shannon Entropy Analysis: Computes information entropy for string constants in code (threshold > 4.5 and length >= 20) to discover secrets in non-standard formats.

3. OWASP Pattern Detection (owasp)

Covers statically detectable security patterns from the OWASP Top 10:

OWASP CategoryDetection Patterns
A02: Cryptographic FailuresWeak hashes (MD5/SHA1), weak ciphers (DES/RC4)
A03: InjectionSQL injection, command injection (os.system / subprocess shell / eval / exec), XSS (innerHTML / document.write / dangerouslySetInnerHTML / v-html)
A04: Insecure DesignPath traversal
A05: Security MisconfigurationDebug mode enabled, CORS wildcard, binding to 0.0.0.0
A08: Integrity FailuresInsecure deserialization (pickle / yaml.load / marshal / unserialize)
A10: SSRFUser input passed directly to HTTP requests

Supported languages: Python, JavaScript/TypeScript, Java, PHP, Ruby, Go, and more.

Parameters

ParameterDescriptionDefault
TARGETDirectory to scanCurrent directory
--mode MODEScan mode: all, deps, secrets, owaspall
--format FORMATOutput format: text, jsontext
--output FILEOutput file pathstdout
--severity LEVELMinimum reporting level: low, medium, high, criticallow
--exclude-dir DIRAdditional directories to exclude (repeatable)-
--max-file-kb SIZEMaximum file size to scan in KB512
-h, --helpShow help-

Output Format

Text Output (default)

=== Security Scan Report ===
Target: /path/to/project
Modules: deps, secrets, owasp

[CRITICAL] AWS Access Key ID
  File: src/config.py:15
  Code: AWS_KEY = "AKIAIOSFODNN7EXAMPLE"

[HIGH] SQL Injection (f-string)
  File: src/db.py:42
  Code: cursor.execute(f"SELECT * FROM users WHERE id={user_id}")

--- Summary ---
Critical: 1 | High: 1 | Medium: 0 | Low: 0
Total findings: 2

JSON Output

{
  "target": "/path/to/project",
  "scan_time": "2026-04-14T10:30:00",
  "findings": [
    {
      "scanner": "secrets",
      "name": "AWS Access Key ID",
      "severity": "critical",
      "file": "src/config.py",
      "line": 15,
      "snippet": "AWS_KEY = \"AKIAIOSFODNN7EXAMPLE\"",
      "category": "secret-pattern"
    }
  ],
  "summary": {"critical": 1, "high": 0, "medium": 0, "low": 0, "total": 1}
}

Exit Codes

Exit CodeMeaning
0No findings
1Findings present (at least one security issue)
2Scanner internal error

Prerequisites

  • Python 3.7+ (uses standard library only)
  • Dependency scanning requires the corresponding tools: npm (for Node.js projects), pip-audit (for Python projects)
  • If an audit tool is missing, that module will be skipped with a notice — other modules continue to run normally

Similar Skills

xlsx
anthropics/skills180k

xlsx

Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.

Databases & data

deprecation-and-migration
addyosmani/agent-skills103k

deprecation-and-migration

Manages deprecation and migration. Use when removing old systems, APIs, or features. Use when migrating users from one implementation to another. Use when migrating a database schema in production, such as renaming or dropping a column without downtime (expand/contract). Use when deciding whether to maintain or sunset existing code.

Databases & data

claude-mem-install
thedotmack/claude-mem99k

claude-mem-install

Use this when setting up claude-mem on Grok Bot: local worker plus CMEM Pro observer (default), optional host-login observer, or remote cmem.ai. No Cursor required.

Databases & data

do
thedotmack/claude-mem99k

do

No description

Databases & data

Agent Cost Report
thedotmack/claude-mem99k

Agent Cost Report

Believable agent cost report for any period, default the last 7 full days PT, not counting today. Measured tokens from Claude Code transcripts priced at OpenRouter list prices (ESTIMATED), measured provider spend when a sanctioned source exists, note-taker cost separate, Timing-style HTML/PDF plus report.json, line-items.csv, evidence.json.

Databases & data

Agent Cost Report
thedotmack/claude-mem99k

Agent Cost Report

Believable agent cost report for any period, default the last 7 full days PT, not counting today. Measured tokens from Claude Code transcripts priced at OpenRouter list prices (ESTIMATED), measured provider spend when a sanctioned source exists, note-taker cost separate, Timing-style HTML/PDF plus report.json, line-items.csv, evidence.json.

Databases & data