Some fine tuning for #4876

This commit is contained in:
Miroslav Stampar 2021-11-01 22:00:26 +01:00
parent 9e17babe7b
commit 8c904bf73c
4 changed files with 11 additions and 7 deletions

View File

@ -2655,6 +2655,15 @@ def _basicOptionValidation():
errMsg = "invalid regular expression '%s' ('%s')" % (conf.retryOn, getSafeExString(ex))
raise SqlmapSyntaxException(errMsg)
if conf.retries == defaults.retries:
conf.retries = 5 * conf.retries
warnMsg = "increasing default value for "
warnMsg += "option '--retries' to %d because " % conf.retries
warnMsg += "option '--retry-on' was provided"
logger.warn(warnMsg)
if conf.cookieDel and len(conf.cookieDel):
errMsg = "option '--cookie-del' should contain a single character (e.g. ';')"
raise SqlmapSyntaxException(errMsg)

View File

@ -20,7 +20,7 @@ from thirdparty import six
from thirdparty.six import unichr as _unichr
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
VERSION = "1.5.11.0"
VERSION = "1.5.11.1"
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

View File

@ -914,11 +914,6 @@ class Connect(object):
warnMsg = "forced retry of the request because of undesired page content"
logger.warn(warnMsg)
return Connect._retryProxy(**kwargs)
else:
errMsg = "unable to get the page content not matching "
errMsg += "the given regular expression '%s'. Please use as high " % conf.retryOn
errMsg += "value for option '--retries' as possible (e.g. 20 or more)"
raise SqlmapConnectionException(errMsg)
processResponse(page, responseHeaders, code, status)

View File

@ -161,7 +161,7 @@ timeout = 30
retries = 3
# Retry request on regexp matching content.
retries = 3
retryOn =
# Randomly change value for the given parameter.
rParam =