mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-10-20 18:54:02 +00:00
Minor optimization
This commit is contained in:
parent
1a7538ae0f
commit
870e11a38e
3 changed files with 11 additions and 5 deletions
|
|
@ -45,6 +45,7 @@ from lib.core.exception import SqlmapGenericException
|
|||
from lib.core.exception import SqlmapSystemException
|
||||
from lib.core.exception import SqlmapValueException
|
||||
from lib.core.replication import Replication
|
||||
from lib.core.settings import CHECK_SQLITE_TYPE_THRESHOLD
|
||||
from lib.core.settings import DUMP_FILE_BUFFER_SIZE
|
||||
from lib.core.settings import HTML_DUMP_CSS_STYLE
|
||||
from lib.core.settings import IS_WIN
|
||||
|
|
@ -509,7 +510,8 @@ class Dump(object):
|
|||
if column != "__infos__":
|
||||
colType = Replication.INTEGER
|
||||
|
||||
for value in tableValues[column]['values']:
|
||||
for i in xrange(min(CHECK_SQLITE_TYPE_THRESHOLD, len(tableValues[column]['values']))):
|
||||
value = tableValues[column]['values'][i]
|
||||
try:
|
||||
if not value or value == " ": # NULL
|
||||
continue
|
||||
|
|
@ -522,7 +524,8 @@ class Dump(object):
|
|||
if colType is None:
|
||||
colType = Replication.REAL
|
||||
|
||||
for value in tableValues[column]['values']:
|
||||
for i in xrange(min(CHECK_SQLITE_TYPE_THRESHOLD, len(tableValues[column]['values']))):
|
||||
value = tableValues[column]['values'][i]
|
||||
try:
|
||||
if not value or value == " ": # NULL
|
||||
continue
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ from lib.core.enums import OS
|
|||
from thirdparty import six
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.9.12.9"
|
||||
VERSION = "1.9.12.10"
|
||||
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
|
||||
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
|
||||
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)
|
||||
|
|
@ -790,6 +790,9 @@ VALID_TIME_CHARS_RUN_THRESHOLD = 100
|
|||
# Check for empty columns only if table is sufficiently large
|
||||
CHECK_ZERO_COLUMNS_THRESHOLD = 10
|
||||
|
||||
# Threshold for checking types of columns in case of SQLite dump format
|
||||
CHECK_SQLITE_TYPE_THRESHOLD = 100
|
||||
|
||||
# Boldify all logger messages containing these "patterns"
|
||||
BOLD_PATTERNS = ("' injectable", "provided empty", "leftover chars", "might be injectable", "' is vulnerable", "is not injectable", "does not seem to be", "test failed", "test passed", "live test final result", "test shows that", "the back-end DBMS is", "created Github", "blocked by the target server", "protection is involved", "CAPTCHA", "specific response", "NULL connection is supported", "PASSED", "FAILED", "for more than", "connection to ")
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue