mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-02-09 08:00:36 +03:00
Minor code restyle
This commit is contained in:
parent
cbdd9e921e
commit
03fac62592
|
@ -57,6 +57,7 @@ def __findUnionCharCount(comment, place, parameter, value, prefix, suffix, where
|
||||||
upperCount = lowerCount + MIN_UNION_RESPONSES
|
upperCount = lowerCount + MIN_UNION_RESPONSES
|
||||||
|
|
||||||
min_, max_ = MAX_RATIO, MIN_RATIO
|
min_, max_ = MAX_RATIO, MIN_RATIO
|
||||||
|
|
||||||
for count in range(lowerCount, upperCount+1):
|
for count in range(lowerCount, upperCount+1):
|
||||||
query = agent.forgeInbandQuery('', -1, count, comment, prefix, suffix, conf.uChar)
|
query = agent.forgeInbandQuery('', -1, count, comment, prefix, suffix, conf.uChar)
|
||||||
payload = agent.payload(place=place, parameter=parameter, newValue=query, where=where)
|
payload = agent.payload(place=place, parameter=parameter, newValue=query, where=where)
|
||||||
|
@ -75,8 +76,8 @@ def __findUnionCharCount(comment, place, parameter, value, prefix, suffix, where
|
||||||
return None
|
return None
|
||||||
|
|
||||||
lower, upper = average(ratios) - UNION_STDEV_COEFF * deviation, average(ratios) + UNION_STDEV_COEFF * deviation
|
lower, upper = average(ratios) - UNION_STDEV_COEFF * deviation, average(ratios) + UNION_STDEV_COEFF * deviation
|
||||||
|
|
||||||
minItem, maxItem = None, None
|
minItem, maxItem = None, None
|
||||||
|
|
||||||
for item in items:
|
for item in items:
|
||||||
if item[1] == min_:
|
if item[1] == min_:
|
||||||
minItem = item
|
minItem = item
|
||||||
|
@ -163,7 +164,7 @@ def __unionConfirm(comment, place, parameter, value, prefix, suffix, count):
|
||||||
# Assure that the above function found the exploitable full inband
|
# Assure that the above function found the exploitable full inband
|
||||||
# SQL injection position
|
# SQL injection position
|
||||||
if not validPayload:
|
if not validPayload:
|
||||||
validPayload, vector = __unionPosition(comment, place, parameter, value, prefix, suffix, count, where=2)
|
validPayload, vector = __unionPosition(comment, place, parameter, value, prefix, suffix, count, where=PAYLOAD.WHERE.NEGATIVE)
|
||||||
|
|
||||||
return validPayload, vector
|
return validPayload, vector
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user