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

Skip to content

Commit 1f3a141

Browse files
committed
Fixes #4727
1 parent 69c679c commit 1f3a141

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

lib/core/settings.py

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

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

lib/utils/safe2bin.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
import string
1111
import sys
1212

13-
if sys.version_info >= (3, 0):
13+
PY3 = sys.version_info >= (3, 0)
14+
15+
if PY3:
1416
xrange = range
1517
text_type = str
1618
string_types = (str,)
@@ -92,7 +94,7 @@ def safechardecode(value, binary=False):
9294

9395
if binary:
9496
if isinstance(retVal, text_type):
95-
retVal = retVal.encode("utf8")
97+
retVal = retVal.encode("utf8", errors="surrogatepass" if PY3 else "strict")
9698

9799
elif isinstance(value, (list, tuple)):
98100
for i in xrange(len(value)):

0 commit comments

Comments
 (0)