mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-08-04 14:55:40 +00:00
Another update related to the #1539
This commit is contained in:
parent
c1e3431877
commit
94639d11a3
6 changed files with 20 additions and 3 deletions
|
|
@ -8,6 +8,7 @@ See the file 'doc/COPYING' for copying permission
|
|||
import binascii
|
||||
|
||||
from lib.core.convert import utf8encode
|
||||
from lib.core.settings import DEFAULT_MYSQL_CHARACTER_SET
|
||||
from plugins.generic.syntax import Syntax as GenericSyntax
|
||||
|
||||
class Syntax(GenericSyntax):
|
||||
|
|
@ -26,7 +27,7 @@ class Syntax(GenericSyntax):
|
|||
try:
|
||||
retVal = "0x%s" % binascii.hexlify(value)
|
||||
except UnicodeEncodeError:
|
||||
retVal = "CONVERT(0x%s USING utf8)" % "".join("%.2x" % ord(_) for _ in utf8encode(value))
|
||||
retVal = "CONVERT(0x%s USING %s)" % ("".join("%.2x" % ord(_) for _ in utf8encode(value)), DEFAULT_MYSQL_CHARACTER_SET)
|
||||
return retVal
|
||||
|
||||
return Syntax._escape(expression, quote, escaper)
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ class Enumeration(Custom, Databases, Entries, Search, Users):
|
|||
kb.data.banner = None
|
||||
kb.data.hostname = ""
|
||||
kb.data.processChar = None
|
||||
kb.data.characterSet = None
|
||||
|
||||
Custom.__init__(self)
|
||||
Databases.__init__(self)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue