mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-26 03:23:48 +03:00
Minor improvement of the randomcase tamper script
This commit is contained in:
parent
70215a95a1
commit
35ed668a85
|
@ -44,11 +44,15 @@ def tamper(payload, **kwargs):
|
||||||
word = match.group()
|
word = match.group()
|
||||||
|
|
||||||
if word.upper() in kb.keywords:
|
if word.upper() in kb.keywords:
|
||||||
_ = str()
|
while True:
|
||||||
|
_ = ""
|
||||||
|
|
||||||
for i in xrange(len(word)):
|
for i in xrange(len(word)):
|
||||||
_ += word[i].upper() if randomRange(0, 1) else word[i].lower()
|
_ += word[i].upper() if randomRange(0, 1) else word[i].lower()
|
||||||
|
|
||||||
|
if len(_) > 1 and _ not in (_.lower(), _.upper()):
|
||||||
|
break
|
||||||
|
|
||||||
retVal = retVal.replace(word, _)
|
retVal = retVal.replace(word, _)
|
||||||
|
|
||||||
return retVal
|
return retVal
|
||||||
|
|
Loading…
Reference in New Issue
Block a user