mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-11-19 22:50:54 +00:00
Minor patches
This commit is contained in:
parent
39d22d26c3
commit
3a680be4eb
11 changed files with 42 additions and 28 deletions
|
|
@ -875,7 +875,8 @@ def download(taskid, target, filename):
|
|||
|
||||
if os.path.isfile(path):
|
||||
logger.debug("(%s) Retrieved content of file %s" % (taskid, target))
|
||||
content = openFile(path, "rb").read()
|
||||
with openFile(path, "rb") as f:
|
||||
content = f.read()
|
||||
return jsonize({"success": True, "file": encodeBase64(content, binary=False)})
|
||||
else:
|
||||
logger.warning("[%s] File does not exist %s" % (taskid, target))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue