mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-26 03:23:48 +03:00
More fix for --technique resume
This commit is contained in:
parent
e96a533a04
commit
2d8408c885
|
@ -80,6 +80,7 @@ def checkSqlInjection(place, parameter, value):
|
|||
if kb.endDetection:
|
||||
break
|
||||
|
||||
proceed = True
|
||||
title = test.title
|
||||
stype = test.stype
|
||||
clause = test.clause
|
||||
|
@ -202,6 +203,21 @@ def checkSqlInjection(place, parameter, value):
|
|||
logger.debug(debugMsg)
|
||||
continue
|
||||
|
||||
if len(kb.injections) > 0:
|
||||
for resumedInj in kb.injections:
|
||||
if resumedInj.place == place and resumedInj.parameter \
|
||||
== parameter and stype in resumedInj.data:
|
||||
debugMsg = "skipping test '%s' because this " % title
|
||||
debugMsg += "technique has already been detected "
|
||||
debugMsg += "in a previous run"
|
||||
logger.debug(debugMsg)
|
||||
|
||||
proceed = False
|
||||
break
|
||||
|
||||
if not proceed:
|
||||
continue
|
||||
|
||||
infoMsg = "testing '%s'" % title
|
||||
logger.info(infoMsg)
|
||||
|
||||
|
|
|
@ -317,9 +317,18 @@ def start():
|
|||
# TODO: consider the following line in __setRequestParams()
|
||||
# __testableParameters = True
|
||||
|
||||
if (len(kb.injections) == 0 or (len(kb.injections) == 1 and kb.injections[0].place is None)) \
|
||||
and (kb.injection.place is None or kb.injection.parameter is None):
|
||||
proceed = False
|
||||
|
||||
if len(kb.injections) > 0:
|
||||
for resumedInj in kb.injections:
|
||||
for tech in conf.tech:
|
||||
if tech not in resumedInj.data:
|
||||
proceed = True
|
||||
break
|
||||
else:
|
||||
proceed = True
|
||||
|
||||
if proceed:
|
||||
if not conf.string and not conf.regexp:
|
||||
# NOTE: this is not needed anymore, leaving only to display
|
||||
# a warning message to the user in case the page is not stable
|
||||
|
|
Loading…
Reference in New Issue
Block a user