File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1919from lib .core .enums import OS
2020
2121# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
22- VERSION = "1.1.2.8 "
22+ VERSION = "1.1.2.9 "
2323TYPE = "dev" if VERSION .count ('.' ) > 2 and VERSION .split ('.' )[- 1 ] != '0' else "stable"
2424TYPE_COLORS = {"dev" : 33 , "stable" : 90 , "pip" : 34 }
2525VERSION_STRING = "sqlmap/%s#%s" % ('.' .join (VERSION .split ('.' )[:- 1 ]) if VERSION .count ('.' ) > 2 and VERSION .split ('.' )[- 1 ] == '0' else VERSION , TYPE )
Original file line number Diff line number Diff line change 55See the file 'doc/COPYING' for copying permission
66"""
77
8+ import re
9+
810from lib .core .common import zeroDepthSearch
911from lib .core .enums import PRIORITY
1012
@@ -35,6 +37,7 @@ def tamper(payload, **kwargs):
3537 if payload :
3638 while True :
3739 indexes = zeroDepthSearch (retVal , '+' )
40+
3841 if indexes :
3942 first , last = 0 , 0
4043 for i in xrange (1 , len (indexes )):
@@ -52,6 +55,19 @@ def tamper(payload, **kwargs):
5255
5356 retVal = "%sCONCAT(%s)%s" % (retVal [:start ], '' .join (chars )[start :end ], retVal [end :])
5457 else :
55- break
58+ match = re .search (r"\((CHAR\(\d+.+CHAR\(\d+\))\)" , retVal )
59+ if match :
60+ part = match .group (0 )
61+ indexes = set (zeroDepthSearch (match .group (1 ), '+' ))
62+ if not indexes :
63+ break
64+ chars = [char for char in part ]
65+ for i in xrange (1 , len (chars )):
66+ if i - 1 in indexes :
67+ chars [i ] = ','
68+ replacement = "CONCAT%s" % "" .join (chars )
69+ retVal = retVal .replace (part , replacement )
70+ else :
71+ break
5672
5773 return retVal
Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ e544108e2238d756c94a240e8a1ce061 lib/core/optiondict.py
4545d8e9250f3775119df07e9070eddccd16 lib/core/replication.py
4646785f86e3f963fa3798f84286a4e83ff2 lib/core/revision.py
474740c80b28b3a5819b737a5a17d4565ae9 lib/core/session.py
48- bf27a71ebdeee395ebaabde9ed6974fe lib/core/settings.py
48+ f108158ecd5c238a5f94f6f80d5f4c1a lib/core/settings.py
4949d91291997d2bd2f6028aaf371bf1d3b6 lib/core/shell.py
50502ad85c130cc5f2b3701ea85c2f6bbf20 lib/core/subprocessng.py
5151afd0636d2e93c23f4f0a5c9b6023ea17 lib/core/target.py
@@ -252,7 +252,7 @@ a3a0e76922b4f40f422a0daca4e71af3 tamper/htmlencode.py
25225254e1793f30c755202ee1acaacfac45fb tamper/nonrecursivereplacement.py
25325300ba60e5869055aaa7ba0cd23b5ed1f4 tamper/overlongutf8.py
2542543cadacb0f39de03e0f8612c656104e03 tamper/percentage.py
255- 7805efc7af932c2ab452f41967f9eb7b tamper/plus2concat.py
255+ dfaa889d125c34c7b2b468012d2b5279 tamper/plus2concat.py
25625624753ed4e8ceab6f1a1fc13ee621943b tamper/randomcase.py
2572574d5fdfe77668fa44967e1d44f8a50ce7 tamper/randomcomments.py
25825822561b429f41fc0bdd23e36b9a8de9e5 tamper/securesphere.py
You can’t perform that action at this time.
0 commit comments