File tree Expand file tree Collapse file tree 2 files changed +66
-0
lines changed Expand file tree Collapse file tree 2 files changed +66
-0
lines changed Original file line number Diff line number Diff line change
1
+ #!/usr/bin/env python
2
+
3
+ """
4
+ Copyright (c) 2006-2022 sqlmap developers (https://sqlmap.org/)
5
+ See the file 'LICENSE' for copying permission
6
+ """
7
+
8
+ from lib .core .enums import PRIORITY
9
+
10
+ __priority__ = PRIORITY .LOW
11
+
12
+ def dependencies ():
13
+ pass
14
+
15
+ def tamper (payload , ** kwargs ):
16
+ """
17
+ HTML encode in decimal (using code points) all characters (e.g. ' -> ')
18
+
19
+ >>> tamper("1' AND SLEEP(5)#")
20
+ '1' AND SLEEP(5)#'
21
+ """
22
+
23
+ retVal = payload
24
+
25
+ if payload :
26
+ retVal = ""
27
+ i = 0
28
+
29
+ while i < len (payload ):
30
+ retVal += "&#%s;" % ord (payload [i ])
31
+ i += 1
32
+
33
+ return retVal
Original file line number Diff line number Diff line change
1
+ #!/usr/bin/env python
2
+
3
+ """
4
+ Copyright (c) 2006-2022 sqlmap developers (https://sqlmap.org/)
5
+ See the file 'LICENSE' for copying permission
6
+ """
7
+
8
+ from lib .core .enums import PRIORITY
9
+
10
+ __priority__ = PRIORITY .LOW
11
+
12
+ def dependencies ():
13
+ pass
14
+
15
+ def tamper (payload , ** kwargs ):
16
+ """
17
+ HTML encode in hexadecimal (using code points) all characters (e.g. ' -> 1)
18
+
19
+ >>> tamper("1' AND SLEEP(5)#")
20
+ '1' AND SLEEP(5)#'
21
+ """
22
+
23
+ retVal = payload
24
+
25
+ if payload :
26
+ retVal = ""
27
+ i = 0
28
+
29
+ while i < len (payload ):
30
+ retVal += "&#x%s;" % format (ord (payload [i ]), "x" )
31
+ i += 1
32
+
33
+ return retVal
You can’t perform that action at this time.
0 commit comments