Minor refactoring

This commit is contained in:
Miroslav Stampar
2017-01-02 15:14:59 +01:00
parent e0eeed0a96
commit c29db43bfa
5 changed files with 26 additions and 27 deletions

View File

@@ -43,7 +43,6 @@ from lib.core.settings import NULL
from lib.request import inject
from lib.utils.hash import attackDumpedTable
from lib.utils.pivotdumptable import pivotDumpTable
from lib.utils.pivotdumptable import whereQuery
class Entries:
"""
@@ -190,7 +189,7 @@ class Entries:
else:
query = rootQuery.inband.query % (colString, conf.db, tbl)
query = whereQuery(query)
query = agent.whereQuery(query)
if not entries and query:
entries = inject.getValue(query, blind=False, time=False, dump=True)
@@ -244,7 +243,7 @@ class Entries:
else:
query = rootQuery.blind.count % (conf.db, tbl)
query = whereQuery(query)
query = agent.whereQuery(query)
count = inject.getValue(query, union=False, error=False, expected=EXPECTED.INT, charsetType=CHARSET_TYPE.DIGITS)
@@ -329,7 +328,7 @@ class Entries:
elif Backend.isDbms(DBMS.INFORMIX):
query = rootQuery.blind.query % (index, agent.preprocessField(tbl, column), conf.db, tbl, sorted(colList, key=len)[0])
query = whereQuery(query)
query = agent.whereQuery(query)
value = NULL if column in emptyColumns else inject.getValue(query, union=False, error=False, dump=True)
value = '' if value is None else value