diff --git a/lib/core/settings.py b/lib/core/settings.py index 988c37df5..0fa57c650 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -18,7 +18,7 @@ from lib.core.enums import OS from thirdparty.six import unichr as _unichr # sqlmap version (...) -VERSION = "1.3.5.155" +VERSION = "1.3.5.156" 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) diff --git a/plugins/dbms/access/enumeration.py b/plugins/dbms/access/enumeration.py index a20c59ddf..fed692ae8 100644 --- a/plugins/dbms/access/enumeration.py +++ b/plugins/dbms/access/enumeration.py @@ -23,7 +23,7 @@ class Enumeration(GenericEnumeration): warnMsg = "on Microsoft Access it is not possible to get name of the current database" logger.warn(warnMsg) - def isDba(self): + def isDba(self, *args, **kwargs): warnMsg = "on Microsoft Access it is not possible to test if current user is DBA" logger.warn(warnMsg) @@ -39,7 +39,7 @@ class Enumeration(GenericEnumeration): return {} - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on Microsoft Access it is not possible to enumerate the user privileges" logger.warn(warnMsg) diff --git a/plugins/dbms/h2/enumeration.py b/plugins/dbms/h2/enumeration.py index 23ee0dfff..e72cb36bb 100644 --- a/plugins/dbms/h2/enumeration.py +++ b/plugins/dbms/h2/enumeration.py @@ -29,7 +29,7 @@ class Enumeration(GenericEnumeration): return kb.data.banner - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on H2 it is not possible to enumerate the user privileges" logger.warn(warnMsg) diff --git a/plugins/dbms/hsqldb/enumeration.py b/plugins/dbms/hsqldb/enumeration.py index 2b4dcd589..91ad3d734 100644 --- a/plugins/dbms/hsqldb/enumeration.py +++ b/plugins/dbms/hsqldb/enumeration.py @@ -29,7 +29,7 @@ class Enumeration(GenericEnumeration): return kb.data.banner - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on HSQLDB it is not possible to enumerate the user privileges" logger.warn(warnMsg) diff --git a/plugins/dbms/maxdb/enumeration.py b/plugins/dbms/maxdb/enumeration.py index 53fd81c84..120e8447e 100644 --- a/plugins/dbms/maxdb/enumeration.py +++ b/plugins/dbms/maxdb/enumeration.py @@ -217,7 +217,7 @@ class Enumeration(GenericEnumeration): return kb.data.cachedColumns - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on SAP MaxDB it is not possible to enumerate the user privileges" logger.warn(warnMsg) diff --git a/plugins/dbms/mssqlserver/enumeration.py b/plugins/dbms/mssqlserver/enumeration.py index e7a195640..b39b9d7d4 100644 --- a/plugins/dbms/mssqlserver/enumeration.py +++ b/plugins/dbms/mssqlserver/enumeration.py @@ -33,7 +33,7 @@ from plugins.generic.enumeration import Enumeration as GenericEnumeration from thirdparty import six class Enumeration(GenericEnumeration): - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on Microsoft SQL Server it is not possible to fetch " warnMsg += "database users privileges, sqlmap will check whether " warnMsg += "or not the database users are database administrators" diff --git a/plugins/dbms/sqlite/enumeration.py b/plugins/dbms/sqlite/enumeration.py index 4812f57a0..60a6afbd5 100644 --- a/plugins/dbms/sqlite/enumeration.py +++ b/plugins/dbms/sqlite/enumeration.py @@ -18,7 +18,7 @@ class Enumeration(GenericEnumeration): warnMsg = "on SQLite it is not possible to get name of the current database" logger.warn(warnMsg) - def isDba(self): + def isDba(self, *args, **kwargs): warnMsg = "on SQLite the current user has all privileges" logger.warn(warnMsg) @@ -36,7 +36,7 @@ class Enumeration(GenericEnumeration): return {} - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on SQLite it is not possible to enumerate the user privileges" logger.warn(warnMsg) diff --git a/plugins/dbms/sybase/enumeration.py b/plugins/dbms/sybase/enumeration.py index 19e3532f8..78b1113f8 100644 --- a/plugins/dbms/sybase/enumeration.py +++ b/plugins/dbms/sybase/enumeration.py @@ -53,7 +53,7 @@ class Enumeration(GenericEnumeration): return kb.data.cachedUsers - def getPrivileges(self, *args): + def getPrivileges(self, *args, **kwargs): warnMsg = "on Sybase it is not possible to fetch " warnMsg += "database users privileges, sqlmap will check whether " warnMsg += "or not the database users are database administrators" diff --git a/plugins/generic/custom.py b/plugins/generic/custom.py index ccee31a5b..7fb200d30 100644 --- a/plugins/generic/custom.py +++ b/plugins/generic/custom.py @@ -54,11 +54,11 @@ class Custom(object): return output elif not isStackingAvailable() and not conf.direct: - warnMsg = "execution of non-query SQL statements is only " - warnMsg += "available when stacked queries are supported" - logger.warn(warnMsg) + warnMsg = "execution of non-query SQL statements is only " + warnMsg += "available when stacked queries are supported" + logger.warn(warnMsg) - return None + return None else: if sqlType: debugMsg = "executing %s query: '%s'" % (sqlType if sqlType is not None else "SQL", query) diff --git a/tamper/bluecoat.py b/tamper/bluecoat.py index 4b88a3985..0ec2af80c 100644 --- a/tamper/bluecoat.py +++ b/tamper/bluecoat.py @@ -43,7 +43,7 @@ def tamper(payload, **kwargs): retVal = payload if payload: - retVal = re.sub(r"\b(?P[A-Z_]+)(?=[^\w(]|\Z)", lambda match: process(match), retVal) + retVal = re.sub(r"\b(?P[A-Z_]+)(?=[^\w(]|\Z)", process, retVal) retVal = re.sub(r"\s*=\s*", " LIKE ", retVal) retVal = retVal.replace("%09 ", "%09") diff --git a/tamper/halfversionedmorekeywords.py b/tamper/halfversionedmorekeywords.py index 7a40f9f4c..3d4f91d2a 100644 --- a/tamper/halfversionedmorekeywords.py +++ b/tamper/halfversionedmorekeywords.py @@ -49,7 +49,7 @@ def tamper(payload, **kwargs): retVal = payload if payload: - retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", lambda match: process(match), retVal) + retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", process, retVal) retVal = retVal.replace(" /*!0", "/*!0") return retVal diff --git a/tamper/space2morehash.py b/tamper/space2morehash.py index 614a3c224..ad10c6eea 100644 --- a/tamper/space2morehash.py +++ b/tamper/space2morehash.py @@ -54,7 +54,7 @@ def tamper(payload, **kwargs): retVal = "" if payload: - payload = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", lambda match: process(match), payload) + payload = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", process, payload) for i in xrange(len(payload)): if payload[i].isspace(): diff --git a/tamper/versionedkeywords.py b/tamper/versionedkeywords.py index af27d4cbe..e2c3fcc4d 100644 --- a/tamper/versionedkeywords.py +++ b/tamper/versionedkeywords.py @@ -46,7 +46,7 @@ def tamper(payload, **kwargs): retVal = payload if payload: - retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=[^\w(]|\Z)", lambda match: process(match), retVal) + retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=[^\w(]|\Z)", process, retVal) retVal = retVal.replace(" /*!", "/*!").replace("*/ ", "*/") return retVal diff --git a/tamper/versionedmorekeywords.py b/tamper/versionedmorekeywords.py index 4f9263442..035a05a79 100644 --- a/tamper/versionedmorekeywords.py +++ b/tamper/versionedmorekeywords.py @@ -47,7 +47,7 @@ def tamper(payload, **kwargs): retVal = payload if payload: - retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", lambda match: process(match), retVal) + retVal = re.sub(r"(?<=\W)(?P[A-Za-z_]+)(?=\W|\Z)", process, retVal) retVal = retVal.replace(" /*!", "/*!").replace("*/ ", "*/") return retVal