mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-02-02 20:54:13 +03:00
Added some comments
This commit is contained in:
parent
d0d6632c22
commit
afbd66f6d9
|
@ -306,6 +306,8 @@ def checkStability():
|
|||
condition &= secondPage == thirdPage
|
||||
|
||||
if condition == False:
|
||||
# Prepare for the comparison algorithm based on Content-Length
|
||||
# header value
|
||||
contentLengths = []
|
||||
requestsHeaders = ( firstHeaders, secondHeaders, thirdHeaders )
|
||||
|
||||
|
@ -328,6 +330,8 @@ def checkStability():
|
|||
# TODO: go ahead here with the technique to compare True/False
|
||||
# based upon clAverage discard (conf.contentLengths)
|
||||
|
||||
# Prepare for the comparison algorithm based on page content's
|
||||
# stable lines subset
|
||||
counter = 0
|
||||
firstLines = firstPage.split("\n")
|
||||
secondLines = secondPage.split("\n")
|
||||
|
|
|
@ -71,7 +71,13 @@ def comparison(page, headers=None, content=False):
|
|||
if not conf.equalLines and not conf.contentLengths:
|
||||
return md5.new(page).hexdigest()
|
||||
|
||||
# TODO: ahead here
|
||||
# TODO: go ahead from here
|
||||
|
||||
# Comparison algorithm based on Content-Length header value
|
||||
elif conf.contentLengths:
|
||||
pass
|
||||
|
||||
# Comparison algorithm based on page content's stable lines subset
|
||||
elif conf.equalLines:
|
||||
counter = 0
|
||||
trueLines = 0
|
||||
|
@ -87,8 +93,8 @@ def comparison(page, headers=None, content=False):
|
|||
counter += 1
|
||||
|
||||
# TODO: just debug prints
|
||||
print "trueLines:", trueLines, "len(conf.equalLines):", len(conf.equalLines)
|
||||
print "result:", ( trueLines * 100 ) / len(conf.equalLines)
|
||||
#print "trueLines:", trueLines, "len(conf.equalLines):", len(conf.equalLines)
|
||||
#print "result:", ( trueLines * 100 ) / len(conf.equalLines)
|
||||
|
||||
if ( trueLines * 100 ) / len(conf.equalLines) >= 98:
|
||||
return True
|
||||
|
|
Loading…
Reference in New Issue
Block a user