fix for skipping non-GET urls

This commit is contained in:
Miroslav Stampar 2010-10-15 09:54:29 +00:00
parent 207bef7f19
commit 0f48dd6f73

View File

@ -118,10 +118,10 @@ def start():
conf.data = targetData conf.data = targetData
conf.cookie = targetCookie conf.cookie = targetCookie
injData = [] injData = []
initTargetEnv() initTargetEnv()
parseTargetUrl() parseTargetUrl()
testSqlInj = False testSqlInj = False
if "GET" in conf.parameters: if "GET" in conf.parameters:
for parameter in re.findall(r"([^=]+)=[^&]+&?", conf.parameters["GET"]): for parameter in re.findall(r"([^=]+)=[^&]+&?", conf.parameters["GET"]):
@ -129,6 +129,11 @@ def start():
if paramKey not in kb.testedParams: if paramKey not in kb.testedParams:
testSqlInj = True testSqlInj = True
break break
else:
paramKey = (conf.hostname, conf.path, None, None)
if paramKey not in kb.testedParams:
testSqlInj = True
if not testSqlInj: if not testSqlInj:
infoMsg = "skipping '%s'" % targetUrl infoMsg = "skipping '%s'" % targetUrl
logger.info(infoMsg) logger.info(infoMsg)