Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4fb33bb

Browse files
committed
Some more cleanup (Issue #475)
1 parent b5e6446 commit 4fb33bb

5 files changed

Lines changed: 11 additions & 17 deletions

File tree

plugins/dbms/hsqldb/__init__.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,11 @@
1717

1818
class HSQLDBMap(Syntax, Fingerprint, Enumeration, Filesystem, Miscellaneous, Takeover):
1919
"""
20-
This class defines MySQL methods
20+
This class defines HyperSQL methods
2121
"""
2222

2323
def __init__(self):
2424
self.excludeDbsList = HSQLDB_SYSTEM_DBS
25-
self.sysUdfs = {
26-
# UDF name: UDF return data-type
27-
"sys_exec": { "return": "int" },
28-
"sys_eval": { "return": "string" },
29-
"sys_bineval": { "return": "int" }
30-
}
3125

3226
Syntax.__init__(self)
3327
Fingerprint.__init__(self)

plugins/dbms/hsqldb/filesystem.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ def __init__(self):
1313
GenericFilesystem.__init__(self)
1414

1515
def readFile(self, rFile):
16-
errMsg = "Not implemented in HSQLDB"
16+
errMsg = "on HyperSQL it is not possible to read files"
1717
raise SqlmapUnsupportedFeatureException(errMsg)
1818

1919
def writeFile(self, wFile, dFile, fileType=None, forceCheck=False):
20-
errMsg = "Not implemented in HSQLDB"
20+
errMsg = "on HyperSQL it is not possible to read files"
2121
raise SqlmapUnsupportedFeatureException(errMsg)

plugins/dbms/hsqldb/fingerprint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,5 +146,5 @@ def checkDbms(self):
146146
return False
147147

148148
def getHostname(self):
149-
warnMsg = "on HSQLDB it is not possible to enumerate the hostname"
149+
warnMsg = "on HyperSQL it is not possible to enumerate the hostname"
150150
logger.warn(warnMsg)

plugins/dbms/hsqldb/syntax.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,6 @@
55
See the file 'doc/COPYING' for copying permission
66
"""
77

8-
import binascii
9-
10-
from lib.core.convert import utf8encode
118
from plugins.generic.syntax import Syntax as GenericSyntax
129

1310
class Syntax(GenericSyntax):
@@ -20,6 +17,7 @@ def escape(expression, quote=True):
2017
>>> Syntax.escape("SELECT 'abcdefgh' FROM foobar")
2118
'SELECT CHAR(97)||CHAR(98)||CHAR(99)||CHAR(100)||CHAR(101)||CHAR(102)||CHAR(103)||CHAR(104) FROM foobar'
2219
"""
20+
2321
def escaper(value):
2422
return "||".join("CHAR(%d)" % ord(value[i]) for i in xrange(len(value)))
2523

plugins/dbms/hsqldb/takeover.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,19 @@ def __init__(self):
1313
GenericTakeover.__init__(self)
1414

1515
def osCmd(self):
16-
errMsg = "Not implemented in HSQLDB"
16+
errMsg = "on HyperSQL it is not possible to execute commands"
1717
raise SqlmapUnsupportedFeatureException(errMsg)
1818

1919
def osShell(self):
20-
errMsg = "Not implemented in HSQLDB"
20+
errMsg = "on HyperSQL it is not possible to execute commands"
2121
raise SqlmapUnsupportedFeatureException(errMsg)
2222

2323
def osPwn(self):
24-
errMsg = "Not implemented in HSQLDB"
24+
errMsg = "on HyperSQL it is not possible to establish an "
25+
errMsg += "out-of-band connection"
2526
raise SqlmapUnsupportedFeatureException(errMsg)
2627

2728
def osSmb(self):
28-
errMsg = "Not implemented in HSQLDB"
29+
errMsg = "on HyperSQL it is not possible to establish an "
30+
errMsg += "out-of-band connection"
2931
raise SqlmapUnsupportedFeatureException(errMsg)

0 commit comments

Comments
 (0)