fix for 'No such file or directory' OSError exception

This commit is contained in:
Miroslav Stampar 2010-01-27 17:00:54 +00:00
parent 00002eeb38
commit f4b8ce5c72

View File

@ -158,6 +158,7 @@ class Web:
backdoorName = "backdoor.%s" % self.webApi backdoorName = "backdoor.%s" % self.webApi
backdoorStream = NamedTemporaryFile() backdoorStream = NamedTemporaryFile()
originalTempName = backdoorStream.name
backdoorStream.name = backdoorName backdoorStream.name = backdoorName
backdoorStream.write(decloak(os.path.join(paths.SQLMAP_SHELL_PATH, backdoorName + '_'))) backdoorStream.write(decloak(os.path.join(paths.SQLMAP_SHELL_PATH, backdoorName + '_')))
backdoorStream.seek(0) backdoorStream.seek(0)
@ -203,3 +204,5 @@ class Web:
logger.info(infoMsg) logger.info(infoMsg)
break break
backdoorStream.name = originalTempName