mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-22 09:36:35 +03:00
quick fix
This commit is contained in:
parent
05cb65b106
commit
1e182e6c72
|
@ -48,13 +48,22 @@ def setInjection(inj):
|
|||
session file.
|
||||
"""
|
||||
|
||||
condition = ( not kb.resumedQueries
|
||||
or ( kb.resumedQueries.has_key(conf.url) and
|
||||
not kb.resumedQueries[conf.url].has_key("Injection data"))
|
||||
or ( kb.resumedQueries[conf.url].has_key("Injection data")
|
||||
and intersect(base64unpickle(kb.resumedQueries[conf.url]["Injection data"][:-1]).data.keys(),\
|
||||
inj.data.keys()) != inj.data.keys()
|
||||
) )
|
||||
try:
|
||||
condition = ( not kb.resumedQueries
|
||||
or ( kb.resumedQueries.has_key(conf.url) and
|
||||
not kb.resumedQueries[conf.url].has_key("Injection data"))
|
||||
or ( kb.resumedQueries[conf.url].has_key("Injection data")
|
||||
and intersect(base64unpickle(kb.resumedQueries[conf.url]["Injection data"][:-1]).data.keys(),\
|
||||
inj.data.keys()) != inj.data.keys()
|
||||
) )
|
||||
except AttributeError:
|
||||
warnMsg = "there were some changes in data model "
|
||||
warnMsg += "preventing normal resume of previously stored "
|
||||
warnMsg += "injection data. please use the --flush-session "
|
||||
warnMsg += "to have it fixed"
|
||||
singleTimeWarnMessage(warnMsg)
|
||||
|
||||
condition = False
|
||||
|
||||
if condition:
|
||||
dataToSessionFile("[%s][%s][%s][Injection data][%s]\n" % (conf.url, inj.place, safeFormatString(conf.parameters[inj.place]), base64pickle(inj)))
|
||||
|
@ -169,7 +178,7 @@ def resumeConfKb(expression, url, value):
|
|||
if expression == "Injection data" and url == conf.url:
|
||||
try:
|
||||
injection = base64unpickle(value[:-1])
|
||||
except:
|
||||
except AttributeError:
|
||||
warnMsg = "there were some changes in data model "
|
||||
warnMsg += "preventing normal resume of previously stored "
|
||||
warnMsg += "injection data. please use the --flush-session "
|
||||
|
|
Loading…
Reference in New Issue
Block a user