mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-02-19 21:10:36 +03:00
Minor bug fix for counting of entries for error-based and partial UNION query SQL injection techs
This commit is contained in:
parent
3cb0ca4b63
commit
d8a76ebe34
|
@ -227,8 +227,7 @@ def errorUse(expression, expected=None, resumeValue=True, dump=False):
|
||||||
stopLimit = conf.limitStop
|
stopLimit = conf.limitStop
|
||||||
|
|
||||||
# Count the number of SQL query entries output
|
# Count the number of SQL query entries output
|
||||||
countFirstField = queries[Backend.getIdentifiedDbms()].count.query % expressionFieldsList[0]
|
countedExpression = expression.replace(expressionFields, "COUNT(*)", 1)
|
||||||
countedExpression = expression.replace(expressionFields, countFirstField, 1)
|
|
||||||
|
|
||||||
if re.search(" ORDER BY ", expression, re.I):
|
if re.search(" ORDER BY ", expression, re.I):
|
||||||
untilOrderChar = countedExpression.index(" ORDER BY ")
|
untilOrderChar = countedExpression.index(" ORDER BY ")
|
||||||
|
|
|
@ -198,8 +198,7 @@ def unionUse(expression, unpack=True, dump=False):
|
||||||
stopLimit = conf.limitStop
|
stopLimit = conf.limitStop
|
||||||
|
|
||||||
# Count the number of SQL query entries output
|
# Count the number of SQL query entries output
|
||||||
countFirstField = queries[Backend.getIdentifiedDbms()].count.query % expressionFieldsList[0]
|
countedExpression = expression.replace(expressionFields, "COUNT(*)", 1)
|
||||||
countedExpression = expression.replace(expressionFields, countFirstField, 1)
|
|
||||||
|
|
||||||
if re.search(" ORDER BY ", expression, re.I):
|
if re.search(" ORDER BY ", expression, re.I):
|
||||||
untilOrderChar = countedExpression.index(" ORDER BY ")
|
untilOrderChar = countedExpression.index(" ORDER BY ")
|
||||||
|
|
Loading…
Reference in New Issue
Block a user