XSS CheatSheet
ி Common Tags test link ி Uncommon Tags // hidden input : only on Firefox (when pressed Alt+Shift+X) ி Custom Tag ி Obfuscation link link Click // base64 YWxlcnQoMSk= // hex alert(1) // ascii 97,108,101,114,116,40,49,41 // JJEncode (http://utf-8.jp/public/jjencode.html) $=~[];$={___:++$,$$$$:(![]+"")[$],__$:++$,$_$_:(![]+"")[$],_$_:++$,$_$$:({}+"")[$],$$_$:($[$]+"..
XSS 화이트리스트 소스코드
클라이언트 단에 자바스크립트 필터링 로직이 구현될 경우 우회 가능성이 존재하므로 아래 코드를 참고하여 서버단에 XSS 화이트리스트 필터링을 구현할 것을 권고한다. // filter str= str.replaceAll("&","&") .replaceAll("#","#") .replaceAll(";",";") .replaceAll("\\\\","\") .replaceAll("",">") .replaceAll("\\(","(") .replaceAll("\\)",")") .replaceAll("'","'") .replaceAll("\"",""") .replaceAll("[$]","$") .replaceAll("[*]","*") .replaceAll("[+]","+") .replaceAll("[|]","|..