security-watch
Skill515 starsChanged 22 days agoMITView on GitHub
Use when working on security-sensitive code to catch secrets, eval(), innerHTML, and other dangerous patterns before they're written. Activate with /security-watch for real-time security scanning.
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
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 9
When activated, scans every file write for common security anti-patterns and blocks dangerous code from being committed.
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 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
Security Watch Mode
When activated, scans every file write for common security anti-patterns and blocks dangerous code from being committed.
What It Does
Flags or blocks writes containing:
- Secrets: API keys, passwords, tokens, private keys in source code
- Dangerous functions:
eval(),Function(),innerHTML,dangerouslySetInnerHTML - Injection vectors: Unsanitized template literals in SQL/shell commands
- Insecure config:
http://URLs, disabled TLS verification,*CORS origins
Activation
/security-watchHook Configuration
{
"hooks": {
"PreToolUse": [
{
"matcher": "Write|Edit",
"hook": ".claude/skills/security-watch/scripts/scan-security.sh"
}
]
}
}Detection Patterns
#!/bin/bash
# scan-security.sh
CONTENT="$1"
ISSUES=0
# Secrets detection
SECRET_PATTERNS=(
'AKIA[0-9A-Z]{16}' # AWS Access Key
'sk-[a-zA-Z0-9]{48}' # OpenAI API Key
'ghp_[a-zA-Z0-9]{36}' # GitHub Personal Token
'password\s*[:=]\s*["\x27][^"\x27]+' # Hardcoded passwords
'BEGIN (RSA |EC )?PRIVATE KEY' # Private keys
'sk_live_[a-zA-Z0-9]+' # Stripe secret key
)
for pattern in "${SECRET_PATTERNS[@]}"; do
if echo "$CONTENT" | grep -qP "$pattern"; then
echo "BLOCKED: Potential secret detected matching pattern: $pattern"
ISSUES=$((ISSUES + 1))
fi
done
# Dangerous functions
DANGER_PATTERNS=(
'\beval\s*\('
'\bFunction\s*\('
'\.innerHTML\s*='
'dangerouslySetInnerHTML'
'child_process.*exec\('
'\$\{.*\}.*(?:SELECT|INSERT|UPDATE|DELETE)'
)
for pattern in "${DANGER_PATTERNS[@]}"; do
if echo "$CONTENT" | grep -qP "$pattern"; then
echo "WARNING: Dangerous pattern detected: $pattern"
ISSUES=$((ISSUES + 1))
fi
done
if [ $ISSUES -gt 0 ]; then
echo "Found $ISSUES security issues. Review before proceeding."
exit 1
fiGotchas
- False positives on test fixtures that intentionally contain patterns like
eval()— use// security-watch:ignorecomment - Base64-encoded secrets won't be caught — this scans for plaintext patterns only
- Template literal injection detection has false positives on safe string interpolation — review warnings carefully
- This is a first line of defense, not a replacement for proper security review
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- chinng-inta/portal4agents-plugin★ 0same 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 repository129 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .claude/commands/monitoring/agents.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- aqe-plan-qualitySkill
- aqe-plan-workSkill
- aqe-researchSkill
- aqe-review-qualitySkill
- aqe-rufloSkill
- aqe-test-changeSkill
- rufloSkill
- a11y-allySkill
- accessibility-testingSkill
- AgentDB Advanced FeaturesSkill
- AgentDB Learning PluginsSkill
- AgentDB Memory PatternsSkill
- AgentDB Performance OptimizationSkill
- AgentDB Vector SearchSkill
- agentic-quality-engineeringSkill
- api-testing-patternsSkill
- browserSkill
- brutal-honesty-reviewSkill
- bug-reporting-excellenceSkill
- chaos-engineering-resilienceSkill
- cicd-pipeline-qe-orchestratorSkill
- code-review-qualitySkill
- compatibility-testingSkill
- compliance-testingSkill
- consultancy-practicesSkill
- context-driven-testingSkill
- contract-testingSkill
- coverage-drop-investigatorSkill
- coverage-guardSkill
- database-testingSkill
- debug-loopSkill
- e2e-flow-verifierSkill
- enterprise-integration-testingSkill
- exploratory-testing-advancedSkill
- flow-nexus-neuralSkill
- flow-nexus-platformSkill
- flow-nexus-swarmSkill
- freeze-testsSkill
- github-code-reviewSkill
- github-multi-repoSkill
- github-project-managementSkill
- github-release-managementSkill
- github-workflow-automationSkill
- holistic-testing-pactSkill
- Hooks AutomationSkill
- iterative-loopSkill
- localization-testingSkill
- middleware-testing-patternsSkill
- mobile-testingSkill
- mutation-testingSkill
- n8n-expression-testingSkill
- n8n-integration-testing-patternsSkill
- n8n-security-testingSkill
- n8n-trigger-testing-strategiesSkill
- n8n-workflow-testing-fundamentalsSkill
- no-skipSkill
- The first 60 shown.
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.

