mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-12-06 04:31:30 +00:00
Minor bug fix to --tamper
This commit is contained in:
@@ -539,6 +539,8 @@ def __setTamperingFunctions():
|
|||||||
for tfile in conf.tamper.split(','):
|
for tfile in conf.tamper.split(','):
|
||||||
found = False
|
found = False
|
||||||
|
|
||||||
|
tfile = tfile.strip()
|
||||||
|
|
||||||
if not tfile:
|
if not tfile:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
@@ -943,9 +945,6 @@ def __cleanupOptions():
|
|||||||
else:
|
else:
|
||||||
conf.testParameter = []
|
conf.testParameter = []
|
||||||
|
|
||||||
if conf.tamper:
|
|
||||||
conf.tamper = conf.tamper.replace(" ", "")
|
|
||||||
|
|
||||||
if conf.db:
|
if conf.db:
|
||||||
conf.db = conf.db.replace(" ", "")
|
conf.db = conf.db.replace(" ", "")
|
||||||
|
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ def tamper(place, value):
|
|||||||
newWord = str()
|
newWord = str()
|
||||||
|
|
||||||
for i in xrange(len(word)):
|
for i in xrange(len(word)):
|
||||||
newWord += word[i].upper() if randomRange(0,1) else word[i].lower()
|
newWord += word[i].upper() if randomRange(0, 1) else word[i].lower()
|
||||||
|
|
||||||
retVal = retVal.replace(word, newWord)
|
retVal = retVal.replace(word, newWord)
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ def tamper(place, value):
|
|||||||
newWord = word[0]
|
newWord = word[0]
|
||||||
|
|
||||||
for i in xrange(1, len(word) - 1):
|
for i in xrange(1, len(word) - 1):
|
||||||
newWord += "%s%s" % ("/**/" if randomRange(0,1) else "", word[i])
|
newWord += "%s%s" % ("/**/" if randomRange(0, 1) else "", word[i])
|
||||||
|
|
||||||
newWord += word[-1]
|
newWord += word[-1]
|
||||||
retVal = retVal.replace(word, newWord)
|
retVal = retVal.replace(word, newWord)
|
||||||
|
|||||||
Reference in New Issue
Block a user