mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-22 09:36:35 +03:00
Renaming conf.oDir to conf.outputDir
This commit is contained in:
parent
7cc4159316
commit
053b0fd0e9
|
@ -1507,8 +1507,8 @@ def _cleanupOptions():
|
||||||
if conf.torType:
|
if conf.torType:
|
||||||
conf.torType = conf.torType.upper()
|
conf.torType = conf.torType.upper()
|
||||||
|
|
||||||
if conf.oDir:
|
if conf.outputDir:
|
||||||
paths.SQLMAP_OUTPUT_PATH = conf.oDir
|
paths.SQLMAP_OUTPUT_PATH = conf.outputDir
|
||||||
setPaths()
|
setPaths()
|
||||||
|
|
||||||
if conf.string:
|
if conf.string:
|
||||||
|
|
|
@ -191,7 +191,7 @@ optDict = {
|
||||||
"forms": "boolean",
|
"forms": "boolean",
|
||||||
"freshQueries": "boolean",
|
"freshQueries": "boolean",
|
||||||
"hexConvert": "boolean",
|
"hexConvert": "boolean",
|
||||||
"oDir": "string",
|
"outputDir": "string",
|
||||||
"parseErrors": "boolean",
|
"parseErrors": "boolean",
|
||||||
"pivotColumn": "string",
|
"pivotColumn": "string",
|
||||||
"saveCmdline": "boolean",
|
"saveCmdline": "boolean",
|
||||||
|
|
|
@ -611,7 +611,7 @@ def cmdLineParser():
|
||||||
action="store_true",
|
action="store_true",
|
||||||
help="Use DBMS hex function(s) for data retrieval")
|
help="Use DBMS hex function(s) for data retrieval")
|
||||||
|
|
||||||
general.add_option("--output-dir", dest="oDir",
|
general.add_option("--output-dir", dest="outputDir",
|
||||||
action="store",
|
action="store",
|
||||||
help="Custom output directory path")
|
help="Custom output directory path")
|
||||||
|
|
||||||
|
|
|
@ -144,20 +144,20 @@ class Task(object):
|
||||||
self.options = AttribDict(self._original_options)
|
self.options = AttribDict(self._original_options)
|
||||||
|
|
||||||
def set_output_directory(self):
|
def set_output_directory(self):
|
||||||
if self.get_option("oDir"):
|
if self.get_option("outputDir"):
|
||||||
if os.path.isdir(self.get_option("oDir")):
|
if os.path.isdir(self.get_option("outputDir")):
|
||||||
self.output_directory = self.get_option("oDir")
|
self.output_directory = self.get_option("outputDir")
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
os.makedirs(self.get_option("oDir"))
|
os.makedirs(self.get_option("outputDir"))
|
||||||
self.output_directory = self.get_option("oDir")
|
self.output_directory = self.get_option("outputDir")
|
||||||
except OSError:
|
except OSError:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
if not self.output_directory or not os.path.isdir(self.output_directory):
|
if not self.output_directory or not os.path.isdir(self.output_directory):
|
||||||
self.output_directory = tempfile.mkdtemp(prefix="sqlmapoutput-")
|
self.output_directory = tempfile.mkdtemp(prefix="sqlmapoutput-")
|
||||||
self.temporary_directory = True
|
self.temporary_directory = True
|
||||||
self.set_option("oDir", self.output_directory)
|
self.set_option("outputDir", self.output_directory)
|
||||||
|
|
||||||
def clean_filesystem(self):
|
def clean_filesystem(self):
|
||||||
if self.output_directory and self.temporary_directory:
|
if self.output_directory and self.temporary_directory:
|
||||||
|
|
|
@ -664,7 +664,7 @@ freshQueries = False
|
||||||
hexConvert = False
|
hexConvert = False
|
||||||
|
|
||||||
# Custom output directory path.
|
# Custom output directory path.
|
||||||
oDir =
|
outputDir =
|
||||||
|
|
||||||
# Parse and display DBMS error messages from responses.
|
# Parse and display DBMS error messages from responses.
|
||||||
# Valid: True or False
|
# Valid: True or False
|
||||||
|
|
Loading…
Reference in New Issue
Block a user