Extra check on --union-cols value

This commit is contained in:
Bernardo Damele 2010-11-19 16:39:26 +00:00
parent da7eb329bb
commit 99a23e23cf

View File

@ -522,6 +522,11 @@ def __setUnion():
conf.uColsStart = int(conf.uColsStart)
conf.uColsStop = int(conf.uColsStop)
if conf.uColsStart > conf.uColsStop:
errMsg = "--union-cols range has to be from lower to "
errMsg += "higher number of columns"
raise sqlmapSyntaxException, errMsg
if isinstance(conf.uChar, basestring) and conf.uChar != "NULL":
debugMsg = "setting the UNION query SQL injection character to '%s'" % conf.uChar
logger.debug(debugMsg)