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

Skip to content

Commit e90846b

Browse files
committed
Fixes #3670
1 parent 0a67f0f commit e90846b

2 files changed

Lines changed: 11 additions & 2 deletions

File tree

lib/core/common.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3900,9 +3900,18 @@ def normalizeUnicode(value):
39003900
39013901
>>> normalizeUnicode(u'\u0161u\u0107uraj') == u'sucuraj'
39023902
True
3903+
>>> normalizeUnicode(getUnicode(codecs.decode("666f6f00626172", "hex"))) == u'foobar'
3904+
True
39033905
"""
39043906

3905-
return getUnicode(unicodedata.normalize("NFKD", value).encode("ascii", "ignore")) if isinstance(value, six.text_type) else value
3907+
retVal = value
3908+
3909+
if isinstance(value, six.text_type):
3910+
charset = string.printable[:string.printable.find(' ') + 1]
3911+
retVal = unicodedata.normalize("NFKD", value)
3912+
retVal = "".join(_ for _ in retVal if _ in charset)
3913+
3914+
return retVal
39063915

39073916
def safeSQLIdentificatorNaming(name, isTable=False):
39083917
"""

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
from thirdparty.six import unichr as _unichr
1919

2020
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
21-
VERSION = "1.3.5.97"
21+
VERSION = "1.3.5.98"
2222
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
2323
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
2424
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

0 commit comments

Comments
 (0)