diff --git a/extra/cloak/cloak.py b/extra/cloak/cloak.py
index 79d42dba0..4883342c8 100644
--- a/extra/cloak/cloak.py
+++ b/extra/cloak/cloak.py
@@ -7,6 +7,8 @@ Copyright (c) 2006-2019 sqlmap developers (http://sqlmap.org/)
See the file 'LICENSE' for copying permission
"""
+from __future__ import print_function
+
import os
import sys
import zlib
@@ -38,7 +40,7 @@ def decloak(inputFile=None, data=None):
try:
data = zlib.decompress(hideAscii(data))
except:
- print 'ERROR: the provided input file \'%s\' does not contain valid cloaked content' % inputFile
+ print('ERROR: the provided input file \'%s\' does not contain valid cloaked content' % inputFile)
sys.exit(1)
finally:
f.close()
@@ -63,7 +65,7 @@ def main():
parser.error(e)
if not os.path.isfile(args.inputFile):
- print 'ERROR: the provided input file \'%s\' is non existent' % args.inputFile
+ print('ERROR: the provided input file \'%s\' is non existent' % args.inputFile)
sys.exit(1)
if not args.decrypt:
diff --git a/extra/dbgtool/dbgtool.py b/extra/dbgtool/dbgtool.py
index fa65d448b..72403b2fd 100644
--- a/extra/dbgtool/dbgtool.py
+++ b/extra/dbgtool/dbgtool.py
@@ -7,6 +7,8 @@ Copyright (c) 2006-2019 sqlmap developers (http://sqlmap.org/)
See the file 'LICENSE' for copying permission
"""
+from __future__ import print_function
+
import os
import sys
import struct
@@ -19,7 +21,7 @@ def convert(inputFile):
fileSize = fileStat.st_size
if fileSize > 65280:
- print "ERROR: the provided input file '%s' is too big for debug.exe" % inputFile
+ print("ERROR: the provided input file '%s' is too big for debug.exe" % inputFile)
sys.exit(1)
script = "n %s\nr cx\n" % os.path.basename(inputFile.replace(".", "_"))
@@ -59,7 +61,7 @@ def convert(inputFile):
def main(inputFile, outputFile):
if not os.path.isfile(inputFile):
- print "ERROR: the provided input file '%s' is not a regular file" % inputFile
+ print("ERROR: the provided input file '%s' is not a regular file" % inputFile)
sys.exit(1)
script = convert(inputFile)
@@ -70,7 +72,7 @@ def main(inputFile, outputFile):
sys.stdout.write(script)
sys.stdout.close()
else:
- print script
+ print(script)
if __name__ == "__main__":
usage = "%s -i [-o