mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-04 06:50:14 +00:00
adding --invalid-bignum (Havij like bignum style for invalidating/negating values); renaming --logical-negate to --invalid-logical
This commit is contained in:
parent
4da03d898e
commit
6f67dc85ee
5 changed files with 38 additions and 25 deletions
|
|
@ -87,15 +87,17 @@ class Agent:
|
|||
if where == PAYLOAD.WHERE.ORIGINAL:
|
||||
value = origValue
|
||||
elif where == PAYLOAD.WHERE.NEGATIVE:
|
||||
if not conf.logicalNegate:
|
||||
if conf.invalidLogical:
|
||||
match = re.search(r'\A[^ ]+', newValue)
|
||||
newValue = newValue[len(match.group() if match else ""):]
|
||||
value = "%s%s AND %s=%s" % (origValue, match.group() if match else "", randomInt(2), randomInt(2))
|
||||
elif conf.invalidBignum:
|
||||
value = "%d.%d" % (randomInt(6), randomInt(1))
|
||||
else:
|
||||
if newValue.startswith("-"):
|
||||
value = ""
|
||||
else:
|
||||
value = "-%s" % randomInt()
|
||||
else:
|
||||
match = re.search(r'\A[^ ]+', newValue)
|
||||
newValue = newValue[len(match.group() if match else ""):]
|
||||
value = "%s%s AND %s=%s" % (origValue, match.group() if match else "", randomInt(2), randomInt(2))
|
||||
elif where == PAYLOAD.WHERE.REPLACE:
|
||||
value = ""
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue