diff --git a/plugins/dbms/access/connector.py b/plugins/dbms/access/connector.py index f1025d235..73d6a07bb 100644 --- a/plugins/dbms/access/connector.py +++ b/plugins/dbms/access/connector.py @@ -53,14 +53,14 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except pyodbc.ProgrammingError, msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) return None def execute(self, query): try: self.cursor.execute(query) except (pyodbc.OperationalError, pyodbc.ProgrammingError), msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) except pyodbc.Error, msg: raise sqlmapConnectionException, msg[1] diff --git a/plugins/dbms/db2/connector.py b/plugins/dbms/db2/connector.py index 3e200fb58..b46e241a3 100644 --- a/plugins/dbms/db2/connector.py +++ b/plugins/dbms/db2/connector.py @@ -1,7 +1,7 @@ #!/usr/bin/env python """ -$Id$ +$Id$ Copyright (c) 2006-2012 sqlmap developers (http://www.sqlmap.org/) See the file 'doc/COPYING' for copying permission @@ -45,14 +45,14 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except ibm_db_dbi.ProgrammingError, msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) return None def execute(self, query): try: self.cursor.execute(query) except (ibm_db_dbi.OperationalError, ibm_db_dbi.ProgrammingError), msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) except ibm_db_dbi.InternalError, msg: raise sqlmapConnectionException, msg[1] diff --git a/plugins/dbms/firebird/connector.py b/plugins/dbms/firebird/connector.py index 374c3bcb0..5a29f83a9 100644 --- a/plugins/dbms/firebird/connector.py +++ b/plugins/dbms/firebird/connector.py @@ -50,14 +50,14 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except kinterbasdb.OperationalError, msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) return None def execute(self, query): try: self.cursor.execute(query) except kinterbasdb.OperationalError, msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) except kinterbasdb.Error, msg: raise sqlmapConnectionException, msg[1] diff --git a/plugins/dbms/mssqlserver/connector.py b/plugins/dbms/mssqlserver/connector.py index 53a09f569..ce0e85e7d 100644 --- a/plugins/dbms/mssqlserver/connector.py +++ b/plugins/dbms/mssqlserver/connector.py @@ -52,7 +52,7 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except (pymssql.ProgrammingError, pymssql.OperationalError, _mssql.MssqlDatabaseException), msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) return None def execute(self, query): @@ -62,7 +62,7 @@ class Connector(GenericConnector): self.cursor.execute(utf8encode(query)) retVal = True except (pymssql.OperationalError, pymssql.ProgrammingError), msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) except pymssql.InternalError, msg: raise sqlmapConnectionException, msg diff --git a/plugins/dbms/mysql/connector.py b/plugins/dbms/mysql/connector.py index 5ee413288..05692e704 100644 --- a/plugins/dbms/mysql/connector.py +++ b/plugins/dbms/mysql/connector.py @@ -57,7 +57,7 @@ class Connector(GenericConnector): self.cursor.execute(query) retVal = True except (pymysql.OperationalError, pymysql.ProgrammingError), msg: - logger.warn(msg[1]) + logger.warn("(remote) %s" % msg[1]) except pymysql.InternalError, msg: raise sqlmapConnectionException, msg[1] diff --git a/plugins/dbms/oracle/connector.py b/plugins/dbms/oracle/connector.py index b86c2002b..9002a90d0 100644 --- a/plugins/dbms/oracle/connector.py +++ b/plugins/dbms/oracle/connector.py @@ -56,7 +56,7 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except cx_Oracle.InterfaceError, msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) return None def execute(self, query): @@ -66,7 +66,7 @@ class Connector(GenericConnector): self.cursor.execute(utf8encode(query)) retVal = True except (cx_Oracle.DatabaseError), msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) except cx_Oracle.InternalError, msg: raise sqlmapConnectionException, msg diff --git a/plugins/dbms/postgresql/connector.py b/plugins/dbms/postgresql/connector.py index 942b13c01..b5f99697c 100644 --- a/plugins/dbms/postgresql/connector.py +++ b/plugins/dbms/postgresql/connector.py @@ -61,7 +61,7 @@ class Connector(GenericConnector): self.cursor.execute(query) retVal = True except (psycopg2.OperationalError, psycopg2.ProgrammingError), msg: - logger.warn(msg) + logger.warn(("(remote) %s" % msg).strip()) except psycopg2.InternalError, msg: raise sqlmapConnectionException, msg diff --git a/plugins/dbms/sqlite/connector.py b/plugins/dbms/sqlite/connector.py index 6595843bc..9d1be373d 100644 --- a/plugins/dbms/sqlite/connector.py +++ b/plugins/dbms/sqlite/connector.py @@ -71,14 +71,14 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except self.__sqlite.OperationalError, msg: - logger.warn(msg[0]) + logger.warn("(remote) %s" % msg[0]) return None def execute(self, query): try: self.cursor.execute(utf8encode(query)) except self.__sqlite.OperationalError, msg: - logger.warn(msg[0]) + logger.warn("(remote) %s" % msg[0]) except self.__sqlite.DatabaseError, msg: raise sqlmapConnectionException, msg[0] diff --git a/plugins/dbms/sybase/connector.py b/plugins/dbms/sybase/connector.py index 0c9602b5a..5ffc3d855 100644 --- a/plugins/dbms/sybase/connector.py +++ b/plugins/dbms/sybase/connector.py @@ -52,14 +52,14 @@ class Connector(GenericConnector): try: return self.cursor.fetchall() except (pymssql.ProgrammingError, pymssql.OperationalError, _mssql.MssqlDatabaseException), msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) return None def execute(self, query): try: self.cursor.execute(utf8encode(query)) except (pymssql.OperationalError, pymssql.ProgrammingError), msg: - logger.warn(msg) + logger.warn("(remote) %s" % msg) except pymssql.InternalError, msg: raise sqlmapConnectionException, msg diff --git a/xml/queries.xml b/xml/queries.xml index 72816ff0d..a1a434d69 100644 --- a/xml/queries.xml +++ b/xml/queries.xml @@ -97,9 +97,9 @@ - - - + + +