code-security
Skill0 starsChanged 7 months agoMITView on GitHub
Scan the current project for security issues, dead code, deprecated patterns, forgotten debug code, secrets in config, and hidden oddities. Use when user says 'scan for issues', 'find security problems', 'codebase audit', 'treasures', 'what's wrong with this codebase', 'find dead code', or 'security scan'. Do NOT use for code review of specific PRs (use review for that). Do NOT use for refactoring suggestions (use code-review for that).
- Reads credentials
5 other projects use a version of this.
Adopted by
Most recently taken up by
- fmind/dottheir own version, first seen Nov 8, 2026
- fmind/dotfilestheir own version, first seen Nov 8, 2026
- daemon-blockint-tech/Agentic-Enteprises-Skilltheir own version, first seen May 20, 2026
- rade-nugroho/Agentic-Enteprises-Skilltheir own version, first seen May 20, 2026
- KimYx0207/SkillSemgreptheir own version, first seen Feb 24, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 5
- KimYx0207/SkillSemgrep★ 37same name
- fmind/dot★ 13same name
- fmind/dotfiles★ 13same name
- rade-nugroho/Agentic-Enteprises-Skill★ 9same name
- daemon-blockint-tech/Agentic-Enteprises-Skill★ 8same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository21 other files it gives its agents.
- 5x5Skill
- business-planSkill
- chart-forgeSkill
- code-blast-radiusSkill
- code-edgesSkill
- code-preflightSkill
- code-reviewSkill
- hail-marySkill
- organizeSkill
- plan-capacitySkill
- plan-directionsSkill
- plan-reviewSkill
- postmortemSkill
- research-critiqueSkill
- research-searchSkill
- session-auditSkill
- session-driftSkill
- skill-builderSkill
- skill-evalSkill
- ui-ideasSkill
- update-prSkill
The file
We split this skill into the rules it gives an agent
6 rules. 0 are common, 6 are distinctive, and 0 are very specific to this project.
0
Common
Most of the 4 edited versions we read keep these.
6
Distinctive
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 21
Never modify any files. This is a read-only audit
- Distinctive: line 24
Do not report style issues (formatting, naming).
- Distinctive: line 31
Read the project structure.
- Distinctive: line 39
Search for these patterns across the codebase:
- Distinctive: line 75
Test files for deleted source files
- Distinctive: line 110
After the report, offer:
“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Treasures
Scan the current project for security vulnerabilities, code quality issues, dead code, and hidden oddities. Output a severity-ranked report.
Important
- Scan the ENTIRE project unless
$ARGUMENTSspecifies a scope (e.g.,auth/,src/api/) - Never modify any files. This is a read-only audit
- Rank every finding by severity: CRITICAL, HIGH, MEDIUM, LOW, INFO, FUN
- Be specific — include file paths and line numbers for every finding
- Do not report style issues (formatting, naming). Focus on correctness and security
- False positives are worse than missed findings. Only report things you are confident about
Instructions
Step 1: Map the project
Read the project structure. Identify:
- Language/framework (package.json, requirements.txt, go.mod, Cargo.toml, etc.)
- Entry points (main files, route definitions, CLI entry)
- Configuration files (.env.example, config/, settings files)
- Test directories
Step 2: Security scan
Search for these patterns across the codebase:
CRITICAL / HIGH:
- Auth bypass flags or backdoors (
bypass,skip_auth,admin.*true,debug.*mode.*prod) - Hardcoded secrets, API keys, passwords (
password\s*=,secret\s*=,api_key\s*=,token\s*=with actual values) - SQL injection vectors (string concatenation in queries, f-strings in SQL)
- Command injection (
exec(,eval(,child_process.execwith user input) - Unauthenticated endpoints that should require auth
- Deprecated crypto (MD5, SHA1 for authentication/signing, DES)
- Permissive CORS (
Access-Control-Allow-Origin: *on authenticated endpoints) - Missing rate limiting on auth endpoints
MEDIUM:
- Secrets in example/template files (
.env.examplewith real values) - Hidden feature flags (
DARK_LAUNCH,FEATURE_FLAG,BETA) - Overly permissive file permissions in scripts
- Missing input validation on user-facing endpoints
- Unencrypted sensitive data in logs
LOW / INFO:
- Dead routes (defined but no callers)
- Unused exports/functions (exported but never imported elsewhere)
- TODO/HACK/FIXME comments that indicate known issues
- Commented-out code blocks (>10 lines)
- Stale dependencies (check for known-vulnerable versions if lockfile exists)
FUN:
- Easter eggs, hidden messages, joke comments
- Unusual file names or directories
Step 3: Dead code detection
Search for:
- Exported functions/classes never imported by other files
- Route handlers with no corresponding client calls (if both client and server are in repo)
- Config values defined but never read
- Test files for deleted source files
Step 4: Compile report
Output findings in this format:
TREASURES — [project-name] — [N] findings
CRITICAL ([count])
* [file:line] [description]
Evidence: [the matching code or pattern]
Risk: [what could go wrong]
HIGH ([count])
* [file:line] [description]
...
MEDIUM ([count])
...
LOW ([count])
...
INFO ([count])
...
FUN ([count])
...
SUMMARY: [1-2 sentence overall assessment]Step 5: Offer next steps
After the report, offer:
- "Fix critical/high issues now" — walk through fixes one at a time
- "Create GitHub issues for HIGH+" — generate issue descriptions (if gh CLI available)
- "Re-scan [specific area]" — deeper dive into a flagged area
Error Handling
- No source code found: Report "No scannable source files found in [path]. Is this the right directory?"
- Scope argument doesn't exist: Report "Directory
$ARGUMENTSnot found. Available top-level directories: [list]" - Very large project (>1000 files): Scan top-level structure first, then focus on the most likely areas (auth, API, config, database)
Examples
Example 1: Full project scan
Input: /code-security
Process: Scans entire project, finds 3 HIGH issues in auth module, 2 MEDIUM in config, 1 FUN easter egg
Output: Severity-ranked report with file:line references
Example 2: Scoped scan
Input: /code-security src/auth/
Process: Deep scan of auth directory only
Output: Focused report on auth-related findings
Example 3: Clean project
Input: /code-security
Output: "TREASURES — acme-api — 0 critical/high findings. 2 LOW items (stale TODOs). Looking solid."
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.

