diff --git a/lib/core/option.py b/lib/core/option.py index 88b344226..c9a12de98 100644 --- a/lib/core/option.py +++ b/lib/core/option.py @@ -2211,6 +2211,13 @@ def _mergeOptions(inputOptions, overrideOptions): if hasattr(conf, key) and conf[key] is None: conf[key] = value + if conf.unstable: + if key in ("timeSec", "retries", "timeout"): + conf[key] *= 2 + + if conf.unstable: + conf.forcePartial = True + lut = {} for group in optDict.keys(): lut.update((_.upper(), _) for _ in optDict[group]) diff --git a/lib/core/optiondict.py b/lib/core/optiondict.py index 26f6576d2..62a72d6a4 100644 --- a/lib/core/optiondict.py +++ b/lib/core/optiondict.py @@ -239,8 +239,9 @@ optDict = { "offline": "boolean", "purge": "boolean", "tmpDir": "string", - "wizard": "boolean", + "unstable": "boolean", "updateAll": "boolean", + "wizard": "boolean", "verbose": "integer", }, diff --git a/lib/core/settings.py b/lib/core/settings.py index 2092d4e89..c3c7d504c 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -18,7 +18,7 @@ from lib.core.enums import OS from thirdparty.six import unichr as _unichr # sqlmap version (...) -VERSION = "1.3.10.25" +VERSION = "1.3.10.26" 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) diff --git a/lib/parse/cmdline.py b/lib/parse/cmdline.py index 72d204cb2..fbd3727a0 100644 --- a/lib/parse/cmdline.py +++ b/lib/parse/cmdline.py @@ -734,6 +734,9 @@ def cmdLineParser(argv=None): miscellaneous.add_argument("--tmp-dir", dest="tmpDir", help="Local directory for storing temporary files") + miscellaneous.add_argument("--unstable", dest="unstable", action="store_true", + help="Adjust options for unstable connections") + miscellaneous.add_argument("--update", dest="updateAll", action="store_true", help="Update sqlmap") diff --git a/sqlmap.conf b/sqlmap.conf index 96f9c6799..07df2c5af 100644 --- a/sqlmap.conf +++ b/sqlmap.conf @@ -825,14 +825,18 @@ offline = False # Local directory for storing temporary files. tmpDir = -# Simple wizard interface for beginner users. +# Adjust options for unstable connections. # Valid: True or False -wizard = False +unstable = False # Update sqlmap. # Valid: True or False updateAll = False +# Simple wizard interface for beginner users. +# Valid: True or False +wizard = False + # Verbosity level. # Valid: integer between 0 and 6 # 0: Show only error and critical messages