Cosmetics and a missing param

This commit is contained in:
Bernardo Damele 2011-06-08 14:40:42 +00:00
parent 4a9640160e
commit 0d3e8a76d8
2 changed files with 4 additions and 3 deletions

View File

@ -505,7 +505,7 @@ def checkSqlInjection(place, parameter, value):
# Return the injection object # Return the injection object
if injection.place is not None and injection.parameter is not None: if injection.place is not None and injection.parameter is not None:
if not conf.dropSetCookie and PAYLOAD.TECHNIQUE.BOOLEAN in injection.data and injection.data[PAYLOAD.TECHNIQUE.BOOLEAN].vector.startswith('OR'): if not conf.dropSetCookie and PAYLOAD.TECHNIQUE.BOOLEAN in injection.data and injection.data[PAYLOAD.TECHNIQUE.BOOLEAN].vector.startswith('OR'):
warnMsg = "in OR boolean-based injections please consider usage " warnMsg = "in OR boolean-based injections, please consider usage "
warnMsg += "of switch --drop-set-cookie if you experience any " warnMsg += "of switch --drop-set-cookie if you experience any "
warnMsg += "problems during data retrieval" warnMsg += "problems during data retrieval"
logger.warn(warnMsg) logger.warn(warnMsg)
@ -532,11 +532,11 @@ def checkFalsePositives(injection):
kb.injection = injection kb.injection = injection
randInt1, randInt2 = int(randomInt(2)) + 1, int(randomInt(2)) + 1 randInt1, randInt2 = int(randomInt(2)) + 1, int(randomInt(2)) + 1
# just in case (also, they have to be different than 0 because of the last test) # Just in case (also, they have to be different than 0 because of the last test)
while randInt1 == randInt2: while randInt1 == randInt2:
randInt2 = int(randomInt(2)) + 1 randInt2 = int(randomInt(2)) + 1
# simple arithmetic operations which should show basic # Simple arithmetic operations which should show basic
# arithmetic ability of the backend if it's really injectable # arithmetic ability of the backend if it's really injectable
if not checkBooleanExpression("(%d+%d)=%d" % (randInt1, randInt2, randInt1 + randInt2)): if not checkBooleanExpression("(%d+%d)=%d" % (randInt1, randInt2, randInt1 + randInt2)):
retVal = None retVal = None

View File

@ -25,6 +25,7 @@ optDict = {
"Request": { "Request": {
"data": "string", "data": "string",
"cookie": "string", "cookie": "string",
"cDel": "string",
"cookieUrlencode": "boolean", "cookieUrlencode": "boolean",
"dropSetCookie": "boolean", "dropSetCookie": "boolean",
"agent": "string", "agent": "string",