mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-25 19:13:48 +03:00
Minor update
This commit is contained in:
parent
2642e453b5
commit
bae9db65ab
|
@ -5,8 +5,10 @@ Copyright (c) 2006-2015 sqlmap developers (http://sqlmap.org/)
|
||||||
See the file 'doc/COPYING' for copying permission
|
See the file 'doc/COPYING' for copying permission
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
import os
|
||||||
import re
|
import re
|
||||||
|
|
||||||
|
from lib.core.common import singleTimeWarnMessage
|
||||||
from lib.core.enums import PRIORITY
|
from lib.core.enums import PRIORITY
|
||||||
|
|
||||||
__priority__ = PRIORITY.HIGH
|
__priority__ = PRIORITY.HIGH
|
||||||
|
@ -30,7 +32,11 @@ def tamper(payload, **kwargs):
|
||||||
|
|
||||||
retVal = payload
|
retVal = payload
|
||||||
|
|
||||||
match = re.search(r"(?i)MID\(([^,]+?)\s*,\s*(\d+)\s*\,\s*(\d+)\s*\)", payload or "")
|
warnMsg = "you should consider usage of switch '--no-cast' along with "
|
||||||
|
warnMsg += "tamper script '%s'" % os.path.basename(__file__).split(".")[0]
|
||||||
|
singleTimeWarnMessage(warnMsg)
|
||||||
|
|
||||||
|
match = re.search(r"(?i)MID\((.+?)\s*,\s*(\d+)\s*\,\s*(\d+)\s*\)", payload or "")
|
||||||
if match:
|
if match:
|
||||||
retVal = retVal.replace(match.group(0), "MID(%s FROM %s FOR %s)" % (match.group(1), match.group(2), match.group(3)))
|
retVal = retVal.replace(match.group(0), "MID(%s FROM %s FOR %s)" % (match.group(1), match.group(2), match.group(3)))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user