Implementation for an Issue #70

This commit is contained in:
Miroslav Stampar
2012-07-26 12:06:02 +02:00
parent 57f2fccc24
commit 30f8d09651
8 changed files with 31 additions and 8 deletions

View File

@@ -2362,7 +2362,7 @@ def setOptimize():
#conf.predictOutput = True
conf.keepAlive = True
conf.threads = 3 if conf.threads < 3 else conf.threads
conf.nullConnection = not any([conf.data, conf.textOnly, conf.titles, conf.string, conf.regexp, conf.tor])
conf.nullConnection = not any([conf.data, conf.textOnly, conf.titles, conf.string, conf.notString, conf.regexp, conf.tor])
if not conf.nullConnection:
debugMsg = "turning off --null-connection switch used indirectly by switch -o"

View File

@@ -1865,6 +1865,14 @@ def __basicOptionValidation():
errMsg = "option '--string' is incompatible with switch '--null-connection'"
raise sqlmapSyntaxException, errMsg
if conf.notString and conf.nullConnection:
errMsg = "option '--not-string' is incompatible with switch '--null-connection'"
raise sqlmapSyntaxException, errMsg
if conf.string and conf.notString:
errMsg = "option '--string' is incompatible with switch '--not-string'"
raise sqlmapSyntaxException, errMsg
if conf.regexp and conf.nullConnection:
errMsg = "option '--regexp' is incompatible with switch '--null-connection'"
raise sqlmapSyntaxException, errMsg

View File

@@ -76,6 +76,7 @@ optDict = {
"level": "integer",
"risk": "integer",
"string": "string",
"notString": "notString",
"regexp": "string",
"code": "integer",
"textOnly": "boolean",