diff --git a/plugins/dbms/hsqldb/__init__.py b/plugins/dbms/hsqldb/__init__.py index b63d81400..e882eee52 100644 --- a/plugins/dbms/hsqldb/__init__.py +++ b/plugins/dbms/hsqldb/__init__.py @@ -17,17 +17,11 @@ from plugins.generic.misc import Miscellaneous class HSQLDBMap(Syntax, Fingerprint, Enumeration, Filesystem, Miscellaneous, Takeover): """ - This class defines MySQL methods + This class defines HyperSQL methods """ def __init__(self): self.excludeDbsList = HSQLDB_SYSTEM_DBS - self.sysUdfs = { - # UDF name: UDF return data-type - "sys_exec": { "return": "int" }, - "sys_eval": { "return": "string" }, - "sys_bineval": { "return": "int" } - } Syntax.__init__(self) Fingerprint.__init__(self) diff --git a/plugins/dbms/hsqldb/filesystem.py b/plugins/dbms/hsqldb/filesystem.py index 30765817d..b83675c1b 100644 --- a/plugins/dbms/hsqldb/filesystem.py +++ b/plugins/dbms/hsqldb/filesystem.py @@ -13,9 +13,9 @@ class Filesystem(GenericFilesystem): GenericFilesystem.__init__(self) def readFile(self, rFile): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to read files" raise SqlmapUnsupportedFeatureException(errMsg) def writeFile(self, wFile, dFile, fileType=None, forceCheck=False): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to read files" raise SqlmapUnsupportedFeatureException(errMsg) diff --git a/plugins/dbms/hsqldb/fingerprint.py b/plugins/dbms/hsqldb/fingerprint.py index c76e0e716..0949b44db 100644 --- a/plugins/dbms/hsqldb/fingerprint.py +++ b/plugins/dbms/hsqldb/fingerprint.py @@ -146,5 +146,5 @@ class Fingerprint(GenericFingerprint): return False def getHostname(self): - warnMsg = "on HSQLDB it is not possible to enumerate the hostname" + warnMsg = "on HyperSQL it is not possible to enumerate the hostname" logger.warn(warnMsg) diff --git a/plugins/dbms/hsqldb/syntax.py b/plugins/dbms/hsqldb/syntax.py index 1d0eefcb3..c0b934359 100644 --- a/plugins/dbms/hsqldb/syntax.py +++ b/plugins/dbms/hsqldb/syntax.py @@ -5,9 +5,6 @@ Copyright (c) 2006-2013 sqlmap developers (http://sqlmap.org/) See the file 'doc/COPYING' for copying permission """ -import binascii - -from lib.core.convert import utf8encode from plugins.generic.syntax import Syntax as GenericSyntax class Syntax(GenericSyntax): @@ -20,6 +17,7 @@ class Syntax(GenericSyntax): >>> Syntax.escape("SELECT 'abcdefgh' FROM foobar") 'SELECT CHAR(97)||CHAR(98)||CHAR(99)||CHAR(100)||CHAR(101)||CHAR(102)||CHAR(103)||CHAR(104) FROM foobar' """ + def escaper(value): return "||".join("CHAR(%d)" % ord(value[i]) for i in xrange(len(value))) diff --git a/plugins/dbms/hsqldb/takeover.py b/plugins/dbms/hsqldb/takeover.py index 6685883b7..65cfe4c31 100644 --- a/plugins/dbms/hsqldb/takeover.py +++ b/plugins/dbms/hsqldb/takeover.py @@ -13,17 +13,19 @@ class Takeover(GenericTakeover): GenericTakeover.__init__(self) def osCmd(self): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to execute commands" raise SqlmapUnsupportedFeatureException(errMsg) def osShell(self): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to execute commands" raise SqlmapUnsupportedFeatureException(errMsg) def osPwn(self): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to establish an " + errMsg += "out-of-band connection" raise SqlmapUnsupportedFeatureException(errMsg) def osSmb(self): - errMsg = "Not implemented in HSQLDB" + errMsg = "on HyperSQL it is not possible to establish an " + errMsg += "out-of-band connection" raise SqlmapUnsupportedFeatureException(errMsg)