Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e50d645

Browse files
committed
minor fix
1 parent 2b05ded commit e50d645

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

lib/core/agent.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -576,7 +576,7 @@ def forgeInbandQuery(self, query, position, count, comment, prefix, suffix, char
576576
intoRegExp = intoRegExp.group(1)
577577
query = query[:query.index(intoRegExp)]
578578

579-
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and inbandQuery.endswith(FROM_TABLE[Backend.getIdentifiedDbms()]):
579+
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and inbandQuery.endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]):
580580
inbandQuery = inbandQuery[:-len(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()])]
581581

582582
for element in xrange(0, count):
@@ -747,7 +747,7 @@ def forgeCaseStatement(self, expression):
747747
if Backend.getIdentifiedDbms() is not None and hasattr(queries[Backend.getIdentifiedDbms()], "case"):
748748
caseExpression = queries[Backend.getIdentifiedDbms()].case.query % expression
749749

750-
if "(IIF" not in caseExpression and Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and not caseExpression.upper().endswith(FROM_TABLE[Backend.getIdentifiedDbms()]):
750+
if "(IIF" not in caseExpression and Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and not caseExpression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]):
751751
caseExpression += FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]
752752

753753
return caseExpression

lib/request/inject.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ def __goInferenceProxy(expression, fromUser=False, expected=None, batch=False, r
159159
# NOTE: I assume that only queries that get data from a table
160160
# can return multiple entries
161161
if fromUser and " FROM " in expression.upper() and ((Backend.getIdentifiedDbms() \
162-
not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_TABLE and not \
162+
not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and not \
163163
expression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]))) \
164164
and not re.search(SQL_SCALAR_REGEX, expression, re.I):
165165

@@ -215,7 +215,7 @@ def __goInferenceProxy(expression, fromUser=False, expected=None, batch=False, r
215215
stopLimit += startLimit
216216

217217
if not stopLimit or stopLimit <= 1:
218-
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and expression.upper().endswith(FROM_TABLE[Backend.getIdentifiedDbms()]):
218+
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and expression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]):
219219
test = False
220220
else:
221221
test = True

lib/techniques/union/test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ def __unionTestByCharBruteforce(comment, place, parameter, value, prefix, suffix
257257
count = __findUnionCharCount(comment, place, parameter, value, prefix, suffix, PAYLOAD.WHERE.ORIGINAL if isNullValue(kb.uChar) else PAYLOAD.WHERE.NEGATIVE)
258258

259259
if count:
260-
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and query.endswith(FROM_TABLE[Backend.getIdentifiedDbms()]):
260+
if Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and query.endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]):
261261
query = query[:-len(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()])]
262262

263263
if count:

lib/techniques/union/use.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def unionUse(expression, unpack=True, dump=False):
165165
if (kb.injection.data[PAYLOAD.TECHNIQUE.UNION].where == PAYLOAD.WHERE.NEGATIVE or \
166166
(dump and (conf.limitStart or conf.limitStop))) and \
167167
" FROM " in expression.upper() and ((Backend.getIdentifiedDbms() \
168-
not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_TABLE \
168+
not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE \
169169
and not expression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]))) \
170170
and not re.search(SQL_SCALAR_REGEX, expression, re.I):
171171

0 commit comments

Comments
 (0)