ai-ml-attacks
This skill should be used when the user asks about "AI security", "ML pipeline attacks", "prompt injection", "model…
Detect ANY credential/secret flowing to ANY output sink. Use when asked about "credential leakage", "secret logging", "sensitive data exposure", "CWE-532", "password in logs", "token exposure", or security logging issues.
Claude Code
$ npx -y skills add allsmog/vuln-scout --skill sensitive-data-leakage --agent claude-code
Codex
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a codex -y
Cursor
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a cursor -y
Gemini CLI
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a gemini-cli -y
GitHub Copilot
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a github-copilot -y
OpenCode
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a opencode -y
Windsurf
$ npx skills add allsmog/vuln-scout --skill sensitive-data-leakage -a windsurf -y
name: Sensitive Data Leakage description: Detect ANY credential/secret flowing to ANY output sink. Use when asked about "credential leakage", "secret logging", "sensitive data exposure", "CWE-532", "password in logs", "token exposure", or security logging issues. version: 2.1.0
IF data MATCHES sensitive_pattern AND data FLOWS TO output_sink THEN potential_leak
This skill detects credentials, secrets, and sensitive data flowing to logging, error messages, HTTP responses, or any other output - regardless of which libraries the codebase uses.
Search for variables, fields, parameters with these patterns:
**Go:**
grep -rniE "(secret|password|passwd|pwd|apikey|api_key|token|credential|private.?key|access.?key|auth.?token|bearer|encryption.?key|signing.?key|client.?secret|consumer.?secret|conn.?str|connection.?string)" --include="*.go" | grep -v "_test\.go"
**Python:**
grep -rniE "(secret|password|passwd|pwd|apikey|api_key|token|credential|private.?key|access.?key|auth.?token|bearer)" --include="*.py" | grep -v "test_"
**Java:**
grep -rniE "(secret|password|passwd|pwd|apiKey|api_key|token|credential|privateKey|accessKey|authToken|bearer)" --include="*.java" | grep -v "Test\.java"
**JavaScript/TypeScript:**
grep -rniE "(secret|password|passwd|pwd|apiKey|api_key|token|credential|privateKey|accessKey|authToken|bearer)" --include="*.js" --include="*.ts" | grep -v "\.test\." | grep -v "\.spec\."
# Functions that return/fetch secrets (Go) grep -rniE "func.*(Get|Read|Fetch|Load|Decrypt|Retrieve).*(Secret|Password|Key|Token|Cred)" --include="*.go" # Assignments from credential functions grep -rniE "(secret|password|key|token|cred).*:?=.*(Get|Read|Fetch|Load|Decrypt|Retrieve)" --include="*.go"
# Go struct fields grep -rniE "^\s+(Secret|Password|Key|Token|Credential|ApiKey|PrivateKey|AccessKey)\s+\S+" --include="*.go" # Python class attributes grep -rniE "self\.(secret|password|key|token|credential|api_key)" --include="*.py" # Java fields grep -rniE "(private|protected|public)\s+\S+\s+(secret|password|key|token|credential)" --include="*.java"
# Go grep -rniE "os\.Getenv\([\"'].*?(SECRET|PASSWORD|KEY|TOKEN|CREDENTIAL|API_KEY)" --include="*.go" # Python grep -rniE "os\.environ\.get\([\"'].*?(SECRET|PASSWORD|KEY|TOKEN|CREDENTIAL|API_KEY)" --include="*.py" # Node.js grep -rniE "process\.env\.(SECRET|PASSWORD|KEY|TOKEN|CREDENTIAL|API_KEY)" --include="*.js" --include="*.ts"
# Go - find log imports
grep -rniE "^import|^\t\"" --include="*.go" | grep -iE "log|zap|logrus|zerolog|klog|glog|slog" | head -10
# Find actual log function calls
grep -rhoE "\w+\.(Error|Info|Debug|Warn|Fatal|Print|Log|Msg)(f|ln|w|Context)?\s*\(" --include="*.go" | sort | uniq -c | sort -rn | head -20# Matches ANY logging library
grep -rniE "\.(log|print|error|warn|info|debug|fatal|trace|notice|output|write|emit|send|record)(f|ln|w)?\s*\(" --include="*.go" --include="*.py" --include="*.java" --include="*.js"# Go grep -rniE "(fmt\.Errorf|errors\.New|errors\.Wrap|errors\.Wrapf|fmt\.Sprintf.*[Ee]rr)" --include="*.go" # Python grep -rniE "(raise\s+\w+Exception|raise\s+\w+Error)" --include="*.py" # Java grep -rniE "throw\s+new\s+\w+Exception" --include="*.java"
# Go grep -rniE "(\.Write\(|\.WriteString\(|json\.Encode|\.JSON\(|c\.String\(|w\.Write)" --include="*.go" # Python (Flask/Django) grep -rniE "(jsonify|JsonResponse|Response\(|return.*json)" --include="*.py" # Node.js grep -rniE "(res\.send|res\.json|res\.write|response\.send)" --include="*.js" --include="*.ts"
# Direct pattern - sensitive var name in log arguments grep -rniE "(log|print|error|warn|info|debug|fatal)\w*\(.*\b(secret|password|key|token|cred|apikey)\w*\b" --include="*.go" | grep -v "_test\.go"
# These format verbs dump ALL struct fields including secrets grep -rniE "%[+#]?v" --include="*.go" | grep -v "_test\.go" # More specific - %v with config/options types grep -rniE "(Error|Info|Debug|Warn|Print|Log)(f|w)?\(.*%[+#]?v.*(config|option|session|setting|client|request)" --include="*.go"
# Sensitive variable as argument to printf-style function grep -rniE "(printf|errorf|sprintf|infof|debugf|warnf|fatalf)\([^)]+,\s*\w*(secret|password|key|token|cred)" --include="*.go"
# Functions returning errors with sensitive data grep -rniE "return.*(fmt\.Errorf|errors\.).*%(v|s|w).*\w*(secret|password|key|token|config|opt)" --include="*.go"
For each finding, verify:
| Check | Question | How to Verify | |-------|----------|---------------| | **Is it actually sensitive?** | Not a map key, keyboard key, or generic "key" | Check variable usage context | | **Does it reach output?** | Trace variable through code to log/response | Follow data flow | | **Has safe String() method?** | Struct implements fmt.Stringer that redacts secrets? | `grep -A10 "func (.*TypeName) String()"` | | **Format verb?** | Using %+v/%#v? (these bypass String() methods) | Check format string - `%s` and `%v` use String() | | **Is it SDK error?** | SDK errors rarely contain config structs | Don't flag SDK error logging by default | | **Log level?** | Debug logs may be disabled in prod | Lower
AI-powered whitebox penetration testing plugin for Claude Code. 9 languages, 22 skills, 7 autonomous agents. STRIDE threat modeling, OWASP 2025 coverage, polyglot monorepo support.
This skill should be used when the user asks about "AI security", "ML pipeline attacks", "prompt injection", "model…
This skill should be used when the user asks about "business logic", "workflow vulnerability", "trust boundary", "state machine",…
This skill should be used when the user asks about "cache poisoning", "web cache deception", "CDN cache", "proxy cache", "nginx…
This skill should be used when the user asks about "cloud security", "AWS security", "GCP security", "Azure security",…
This skill should be used when the user asks about "compliance mapping", "PCI-DSS", "HIPAA", "SOC 2", "NIST CSF", "regulatory…
This skill should be used when the user asks about "Code Property Graph", "CPG analysis", "Joern queries", "CPGQL", "data flow…
Use for authorized security assessment of REST, GraphQL, WebSocket, or SOAP APIs, including discovery, authentication,…
Extract and decrypt Windows DPAPI-protected secrets (Credential Manager, browser logins/cookies, Wi-Fi credentials, KeePass keys)…
Clean and finalize authorized natural-language text intended for readers by auditing suspicious invisible Unicode and rewriting…