mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-01-23 14:49:03 +00:00
Moving binary to textual file openings
This commit is contained in:
@@ -254,7 +254,7 @@ def storeResultsToFile(results):
|
||||
infoMsg = "writing crawling results to a temporary file '%s' " % filename
|
||||
logger.info(infoMsg)
|
||||
|
||||
with openFile(filename, "w+b") as f:
|
||||
with openFile(filename, "w+") as f:
|
||||
if conf.forms:
|
||||
f.write("URL,POST\n")
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ def purge(directory):
|
||||
for filepath in filepaths:
|
||||
try:
|
||||
filesize = os.path.getsize(filepath)
|
||||
with openFile(filepath, "w+b") as f:
|
||||
with openFile(filepath, "w+") as f:
|
||||
f.write("".join(_unichr(random.randint(0, 255)) for _ in xrange(filesize)))
|
||||
except:
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user