source-code-scanning
Skill555 starsChanged 8 months agoMITView on GitHub
Security-focused source code review and SAST. Scans for vulnerabilities (OWASP Top 10, CWE Top 25), CVEs in third-party dependencies/packages, hardcoded secrets, malicious code, and insecure patterns. Use when given source code, a repo path, or asked to "audit", "scan", "review" code security, or "check dependencies for CVEs".
- Reads credentials
In this repository49 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- ai-threat-testingSkill
- api-securitySkill
- attack-path-stitcherSkill
- authenticated-session-acquisitionSkill
- authenticationSkill
- blockchain-securitySkill
- client-sideSkill
- cloud-containersSkill
- cloud-defenseSkill
- coordinationSkill
- cryptographySkill
- cve-poc-generatorSkill
- cve-risk-scoreSkill
- dfirSkill
- essential-toolsSkill
- firewall-reviewSkill
- github-workflowSkill
- hackeroneSkill
- hacktheboxSkill
- infrastructureSkill
- injectionSkill
- mobile-securitySkill
- network-appliance-offensiveSkill
- osintSkill
- patt-fetcherSkill
- pci-secure-softwareSkill
- pentest-engagementSkill
- protect-with-passwordSkill
- reconnaissanceSkill
- regression-sweepSkill
- reverse-engineeringSkill
- risk-prioritiserSkill
- script-generatorSkill
- server-sideSkill
- skill-pruneSkill
- skill-updateSkill
- social-engineeringSkill
- systemSkill
- techstack-backendSkill
- techstack-correlationSkill
- techstack-frontendSkill
- techstack-infraSkill
- techstack-osintSkill
- techstack-securitySkill
- techstack-identificationSkill
- ti-ingestSkill
- transilience-report-styleSkill
- web-app-logicSkill
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 6 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 11
Automated SAST: - run tools appropriate to the stack
- Distinctive: line 15
Malicious code: - check for backdoors, obfuscation, suspicious network calls
- Distinctive: line 102
When given a mobile app binary:
- Very specific: line 106
Encoded secrets: Search for base64 prefixes of known flag/secret formats (e.g., RkxBR = base64 of FLAG).
- Very specific: line 107
Native: Use jadx for Java/Kotlin decompilation, check AndroidManifest.xml, strings.xml, BuildConfig
- Very specific: line 108
Shared libs: Check .so files with strings for hardcoded credentials
- Distinctive: line 111
Never execute untrusted code during review
- Distinctive: line 112
Treat all findings as potential until verified
- Distinctive: line 113
Always cross-reference CVEs against actual version in use
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Source Code Security Review
Quick Start
- Identify - languages, frameworks, package managers present
- Automated SAST - run tools appropriate to the stack
- Dependency CVEs - scan lockfiles/manifests for known CVEs
- Secrets scan - detect hardcoded credentials/tokens
- Manual review - trace high-risk sinks (exec, eval, query, deserialize)
- Malicious code - check for backdoors, obfuscation, suspicious network calls
- Report - findings with CWE/CVE refs, severity, PoC, remediation
Workflow
Phase 1: Enumerate
- Languages: ls **/*.{py,js,ts,java,go,rb,php,cs,rs}
- Packages: find package.json, requirements.txt, go.mod, pom.xml, Gemfile, composer.json, Cargo.toml
- Entry points: main(), index.*, app.*, server.*
- Config files: .env*, config.*, settings.*, *.yaml, *.tomlPhase 2: Automated SAST
See sast-tools.md for commands per language.
Key tools:
- Multi-language: Semgrep (
semgrep --config=auto .) - Python: Bandit (
bandit -r . -f json) - JavaScript/TS: ESLint security plugin, njsscan
- Java: SpotBugs + FindSecBugs
- Go: gosec (
gosec ./...) - PHP: PHPCS Security Audit
- Ruby: Brakeman (
brakeman -o report.json) - All: CodeQL (via
gh codeql)
Phase 3: Dependency CVE Scan
See dependency-cve-scanning.md for commands.
| Ecosystem | Command |
| npm/yarn | npm audit --json / yarn audit |
| Python | pip-audit -r requirements.txt |
| Java | dependency-check --scan . |
| Go | govulncheck ./... |
| Ruby | bundle audit |
| Generic | trivy fs . / grype dir:. |
Phase 4: Secrets Detection
See secrets-detection.md.
trufflehog filesystem . --json
gitleaks detect --source . -vPhase 5: Manual Review
Focus on high-risk sinks — see manual-review.md:
- Injection sinks:
exec,eval,query,system,popen - Deserialization:
pickle.loads,ObjectInputStream,unserialize - Crypto: hardcoded keys, weak algorithms (MD5, SHA1, DES, ECB)
- Auth: JWT validation, session management, RBAC enforcement
- File ops: path construction with user input
Phase 6: Malicious Code
See malicious-code.md:
- Obfuscated strings (base64, hex, charCode)
- Unexpected network calls in library code
- Typosquatting indicators
- Postinstall/lifecycle script abuse
- Hidden backdoors in dependencies
Language-Specific Patterns
See language-patterns.md for Python, JS, Java, Go, PHP, Ruby.
Severity Mapping
| Severity | CVSS | Examples |
| Critical | 9.0+ | RCE, SQLi with exfil, auth bypass |
| High | 7.0-8.9 | Stored XSS, SSRF, insecure deserialization |
| Medium | 4.0-6.9 | Reflected XSS, info disclosure, IDOR |
| Low | 0.1-3.9 | Missing headers, verbose errors |
Output Format
findings/
<severity>-<vuln-type>-<location>.md # One file per finding
evidence/
<tool>-output.json # Raw tool output
summary-report.md # Executive summaryEach finding: CWE/CVE ID | File:Line | Severity | PoC | Remediation
Mobile App Analysis (APK/IPA)
When given a mobile app binary:
- Extract:
unzip app.apk -d extracted/(APKs are ZIP archives) - Identify framework: React Native (
assets/index.android.bundle), Flutter (libflutter.so), Xamarin, or native - React Native: JS bundle is plaintext — search for secrets, API keys, config objects, hardcoded tokens
- Encoded secrets: Search for base64 prefixes of known flag/secret formats (e.g.,
RkxBR= base64 ofFLAG). Config objects often store secrets as base64 indebug,secret,apiKeyfields - Native: Use
jadxfor Java/Kotlin decompilation, checkAndroidManifest.xml,strings.xml,BuildConfig - Shared libs: Check
.sofiles withstringsfor hardcoded credentials
Critical Rules
- Never execute untrusted code during review
- Treat all findings as potential until verified
- Always cross-reference CVEs against actual version in use
- Report supply chain issues separately (they affect all users)
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
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.

