mirror of
https://github.com/sqlmapproject/sqlmap
synced 2025-12-06 16:32:23 +01: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
2 changed files with 2 additions and 4 deletions
|
|
@ -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 a new issue