XSS Detection and Verification Techniques
XSS detection involves injecting unique test strings across input vectors and verifying if they execute as JavaScript in the victim's context.
Manual testing workflow
Submit distinctive payloads like <script>alert(1)</script>, ><img src=x onerror=alert(1)>, or javascript:alert(1) into URL params, forms,
headers (User-Agent, Referer), and POST bodies, then check if they reflect/executed in responses. Examine page source, browser console,
and network tab for unencoded reflections in HTML, attributes, JS contexts, or DOM sinks (innerHTML, eval()).
Automated scanning and tools
Use scanners like XSStrike, Dalfox, or Burp Scanner on all parameters/headers to fuzz payloads and detect reflections automatically. For blind/stored XSS,
deploy OAST callbacks (Burp Collaborator, xsshunter) in payloads to catch delayed executions in logs, admin panels, or emails.
Verification techniques
Confirm true positives by observing execution (alert, beacon to your server) rather than mere reflection, test context-specific breaks (", <, \`),
and chain with cookie theft (document.cookie) to prove impact. DOM XSS needs browser devtools to trace location.hash, document.referrer sinks.