Skip to content

Commit a8a6dce

Browse files
committed
1 parent f542e82 commit a8a6dce

File tree

3 files changed

+16
-12
lines changed

3 files changed

+16
-12
lines changed

lib/core/option.py

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -899,18 +899,22 @@ def _setTamperingFunctions():
899899

900900
script = script.strip().encode(sys.getfilesystemencoding() or UNICODE_ENCODING)
901901

902-
if not script:
903-
continue
902+
try:
903+
if not script:
904+
continue
904905

905-
elif os.path.exists(os.path.join(paths.SQLMAP_TAMPER_PATH, script if script.endswith(".py") else "%s.py" % script)):
906-
script = os.path.join(paths.SQLMAP_TAMPER_PATH, script if script.endswith(".py") else "%s.py" % script)
906+
elif os.path.exists(os.path.join(paths.SQLMAP_TAMPER_PATH, script if script.endswith(".py") else "%s.py" % script)):
907+
script = os.path.join(paths.SQLMAP_TAMPER_PATH, script if script.endswith(".py") else "%s.py" % script)
907908

908-
elif not os.path.exists(script):
909-
errMsg = "tamper script '%s' does not exist" % script
910-
raise SqlmapFilePathException(errMsg)
909+
elif not os.path.exists(script):
910+
errMsg = "tamper script '%s' does not exist" % script
911+
raise SqlmapFilePathException(errMsg)
911912

912-
elif not script.endswith(".py"):
913-
errMsg = "tamper script '%s' should have an extension '.py'" % script
913+
elif not script.endswith(".py"):
914+
errMsg = "tamper script '%s' should have an extension '.py'" % script
915+
raise SqlmapSyntaxException(errMsg)
916+
except UnicodeDecodeError:
917+
errMsg = "invalid character provided in option '--tamper'"
914918
raise SqlmapSyntaxException(errMsg)
915919

916920
dirname, filename = os.path.split(script)

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from lib.core.enums import OS
2020

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

txt/checksum.md5

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ a8143dab9d3a27490f7d49b6b29ea530 lib/core/data.py
3939
310efc965c862cfbd7b0da5150a5ad36 lib/core/__init__.py
4040
9ba39bf66e9ecd469446bdbbeda906c3 lib/core/log.py
4141
e544108e2238d756c94a240e8a1ce061 lib/core/optiondict.py
42-
44a61841bcd0bafc4151e31d5a14287d lib/core/option.py
42+
796eb85d5f6e7657e40d584c018d6f5b lib/core/option.py
4343
5f2f56e6c5f274408df61943f1e080c0 lib/core/profiling.py
4444
40be71cd774662a7b420caeb7051e7d5 lib/core/readlineng.py
4545
d8e9250f3775119df07e9070eddccd16 lib/core/replication.py
4646
785f86e3f963fa3798f84286a4e83ff2 lib/core/revision.py
4747
40c80b28b3a5819b737a5a17d4565ae9 lib/core/session.py
48-
2ce52e30cd8111887675e4b847b0a076 lib/core/settings.py
48+
615c9fe6c1ce36972c77f313d8d331e1 lib/core/settings.py
4949
d91291997d2bd2f6028aaf371bf1d3b6 lib/core/shell.py
5050
2ad85c130cc5f2b3701ea85c2f6bbf20 lib/core/subprocessng.py
5151
afd0636d2e93c23f4f0a5c9b6023ea17 lib/core/target.py

0 commit comments

Comments
 (0)