Skip to content

Commit 8c904bf

Browse files
committed
Some fine tuning for #4876
1 parent 9e17bab commit 8c904bf

File tree

4 files changed

+11
-7
lines changed

4 files changed

+11
-7
lines changed

lib/core/option.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2655,6 +2655,15 @@ def _basicOptionValidation():
26552655
errMsg = "invalid regular expression '%s' ('%s')" % (conf.retryOn, getSafeExString(ex))
26562656
raise SqlmapSyntaxException(errMsg)
26572657

2658+
if conf.retries == defaults.retries:
2659+
conf.retries = 5 * conf.retries
2660+
2661+
warnMsg = "increasing default value for "
2662+
warnMsg += "option '--retries' to %d because " % conf.retries
2663+
warnMsg += "option '--retry-on' was provided"
2664+
logger.warn(warnMsg)
2665+
2666+
26582667
if conf.cookieDel and len(conf.cookieDel):
26592668
errMsg = "option '--cookie-del' should contain a single character (e.g. ';')"
26602669
raise SqlmapSyntaxException(errMsg)

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
from thirdparty.six import unichr as _unichr
2121

2222
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
23-
VERSION = "1.5.11.0"
23+
VERSION = "1.5.11.1"
2424
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
2525
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
2626
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

lib/request/connect.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -914,11 +914,6 @@ class _(dict):
914914
warnMsg = "forced retry of the request because of undesired page content"
915915
logger.warn(warnMsg)
916916
return Connect._retryProxy(**kwargs)
917-
else:
918-
errMsg = "unable to get the page content not matching "
919-
errMsg += "the given regular expression '%s'. Please use as high " % conf.retryOn
920-
errMsg += "value for option '--retries' as possible (e.g. 20 or more)"
921-
raise SqlmapConnectionException(errMsg)
922917

923918
processResponse(page, responseHeaders, code, status)
924919

sqlmap.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ timeout = 30
161161
retries = 3
162162

163163
# Retry request on regexp matching content.
164-
retries = 3
164+
retryOn =
165165

166166
# Randomly change value for the given parameter.
167167
rParam =

0 commit comments

Comments
 (0)