mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-01-10 16:49:02 +00:00
Minor refactoring
This commit is contained in:
@@ -2097,11 +2097,11 @@ def _useWizardInterface():
|
||||
choice = readInput(message, default='1')
|
||||
|
||||
if choice == '2':
|
||||
map(lambda x: conf.__setitem__(x, True), WIZARD.INTERMEDIATE)
|
||||
map(lambda _: conf.__setitem__(_, True), WIZARD.INTERMEDIATE)
|
||||
elif choice == '3':
|
||||
map(lambda x: conf.__setitem__(x, True), WIZARD.ALL)
|
||||
map(lambda _: conf.__setitem__(_, True), WIZARD.ALL)
|
||||
else:
|
||||
map(lambda x: conf.__setitem__(x, True), WIZARD.BASIC)
|
||||
map(lambda _: conf.__setitem__(_, True), WIZARD.BASIC)
|
||||
|
||||
logger.debug("muting sqlmap.. it will do the magic for you")
|
||||
conf.verbose = 0
|
||||
|
||||
@@ -19,7 +19,7 @@ from lib.core.enums import DBMS_DIRECTORY_NAME
|
||||
from lib.core.enums import OS
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.1.11.15"
|
||||
VERSION = "1.1.11.16"
|
||||
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)
|
||||
|
||||
@@ -278,7 +278,7 @@ def columnExists(columnFile, regex=None):
|
||||
|
||||
kb.data.cachedColumns[conf.db] = {conf.tbl: columns}
|
||||
|
||||
for _ in map(lambda x: (conf.db, conf.tbl, x[0], x[1]), columns.items()):
|
||||
for _ in ((conf.db, conf.tbl, item[0], item[1]) for item in columns.items()):
|
||||
if _ not in kb.brute.columns:
|
||||
kb.brute.columns.append(_)
|
||||
|
||||
|
||||
@@ -153,7 +153,7 @@ def mssql_passwd(password, salt, uppercase=False):
|
||||
"""
|
||||
|
||||
binsalt = hexdecode(salt)
|
||||
unistr = "".join(map(lambda c: ("%s\0" if ord(c) < 256 else "%s") % utf8encode(c), password))
|
||||
unistr = "".join(("%s\0" if ord(_) < 256 else "%s") % utf8encode(_) for _ in password)
|
||||
|
||||
retVal = "0100%s%s" % (salt, sha1(unistr + binsalt).hexdigest())
|
||||
|
||||
@@ -171,7 +171,7 @@ def mssql_old_passwd(password, salt, uppercase=True): # prior to version '2005'
|
||||
"""
|
||||
|
||||
binsalt = hexdecode(salt)
|
||||
unistr = "".join(map(lambda c: ("%s\0" if ord(c) < 256 else "%s") % utf8encode(c), password))
|
||||
unistr = "".join(("%s\0" if ord(_) < 256 else "%s") % utf8encode(_) for _ in password)
|
||||
|
||||
retVal = "0100%s%s%s" % (salt, sha1(unistr + binsalt).hexdigest(), sha1(unistr.upper() + binsalt).hexdigest())
|
||||
|
||||
@@ -187,7 +187,7 @@ def mssql_new_passwd(password, salt, uppercase=False):
|
||||
"""
|
||||
|
||||
binsalt = hexdecode(salt)
|
||||
unistr = "".join(map(lambda c: ("%s\0" if ord(c) < 256 else "%s") % utf8encode(c), password))
|
||||
unistr = "".join(("%s\0" if ord(_) < 256 else "%s") % utf8encode(_) for _ in password)
|
||||
|
||||
retVal = "0200%s%s" % (salt, sha512(unistr + binsalt).hexdigest())
|
||||
|
||||
|
||||
Reference in New Issue
Block a user