Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f389bd7

Browse files
committed
Implementation for an Issue #2224
1 parent 1126ff8 commit f389bd7

6 files changed

Lines changed: 27 additions & 15 deletions

File tree

lib/core/optiondict.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,12 @@
3838
"authType": "string",
3939
"authCred": "string",
4040
"authFile": "string",
41+
"ignore401": "boolean",
42+
"ignoreProxy": "boolean",
43+
"ignoreTimeouts": "boolean",
4144
"proxy": "string",
4245
"proxyCred": "string",
4346
"proxyFile": "string",
44-
"ignoreProxy": "boolean",
4547
"tor": "boolean",
4648
"torPort": "integer",
4749
"torType": "string",
@@ -234,7 +236,6 @@
234236
"disablePrecon": "boolean",
235237
"profile": "boolean",
236238
"forceDns": "boolean",
237-
"ignore401": "boolean",
238239
"murphyRate": "integer",
239240
"smokeTest": "boolean",
240241
"liveTest": "boolean",

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from lib.core.enums import OS
2020

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

lib/parse/cmdline.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,12 @@ def cmdLineParser(argv=None):
152152
request.add_option("--ignore-401", dest="ignore401", action="store_true",
153153
help="Ignore HTTP Error 401 (Unauthorized)")
154154

155+
request.add_option("--ignore-proxy", dest="ignoreProxy", action="store_true",
156+
help="Ignore system default proxy settings")
157+
158+
request.add_option("--ignore-timeouts", dest="ignoreTimeouts", action="store_true",
159+
help="Ignore connection timeouts")
160+
155161
request.add_option("--proxy", dest="proxy",
156162
help="Use a proxy to connect to the target URL")
157163

@@ -162,9 +168,6 @@ def cmdLineParser(argv=None):
162168
request.add_option("--proxy-file", dest="proxyFile",
163169
help="Load proxy list from a file")
164170

165-
request.add_option("--ignore-proxy", dest="ignoreProxy", action="store_true",
166-
help="Ignore system default proxy settings")
167-
168171
request.add_option("--tor", dest="tor",
169172
action="store_true",
170173
help="Use Tor anonymity network")

lib/request/connect.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ def getPage(**kwargs):
251251
timeout = kwargs.get("timeout", None) or conf.timeout
252252
auxHeaders = kwargs.get("auxHeaders", None)
253253
response = kwargs.get("response", False)
254-
ignoreTimeout = kwargs.get("ignoreTimeout", False) or kb.ignoreTimeout
254+
ignoreTimeout = kwargs.get("ignoreTimeout", False) or kb.ignoreTimeout or conf.ignoreTimeouts
255255
refreshing = kwargs.get("refreshing", False)
256256
retrying = kwargs.get("retrying", False)
257257
crawling = kwargs.get("crawling", False)

sqlmap.conf

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,18 @@ authCred =
9898
# Syntax: key_file
9999
authFile =
100100

101+
# Ignore HTTP Error 401 (Unauthorized).
102+
# Valid: True or False
103+
ignore401 = False
104+
105+
# Ignore system default proxy settings.
106+
# Valid: True or False
107+
ignoreProxy = False
108+
109+
# Ignore connection timeouts.
110+
# Valid: True or False
111+
ignoreTimeouts = False
112+
101113
# Use a proxy to connect to the target URL.
102114
# Syntax: (http|https|socks4|socks5)://address:port
103115
proxy =
@@ -110,10 +122,6 @@ proxyCred =
110122
# Load proxy list from a file
111123
proxyFile =
112124

113-
# Ignore system default proxy settings.
114-
# Valid: True or False
115-
ignoreProxy = False
116-
117125
# Use Tor anonymity network.
118126
# Valid: True or False
119127
tor = False

txt/checksum.md5

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,14 @@ e4ca0fd47f20cf7ba6a5f5cbf980073c lib/core/decorators.py
3838
e4aec2b11c1ad6039d0c3dbbfbc5eb1a lib/core/exception.py
3939
cc9c82cfffd8ee9b25ba3af6284f057e lib/core/__init__.py
4040
91c514013daa796e2cdd940389354eac lib/core/log.py
41-
5b079749c50240602ea92637e268ed31 lib/core/optiondict.py
41+
468ca9a68a5a40a1cb8395602083ba32 lib/core/optiondict.py
4242
d63e7749935f8ab323baaf5b425977ef lib/core/option.py
4343
7af487340c138f7b5dbd443161cbb428 lib/core/profiling.py
4444
e60456db5380840a586654344003d4e6 lib/core/readlineng.py
4545
5ef56abb8671c2ca6ceecb208258e360 lib/core/replication.py
4646
99a2b496b9d5b546b335653ca801153f lib/core/revision.py
4747
7c15dd2777af4dac2c89cab6df17462e lib/core/session.py
48-
2f3e42f732f34fc56d046f8753eca3a2 lib/core/settings.py
48+
bb5bbbea41c5204fa605973dcae71a84 lib/core/settings.py
4949
7af83e4f18cab6dff5e67840eb65be80 lib/core/shell.py
5050
23657cd7d924e3c6d225719865855827 lib/core/subprocessng.py
5151
c3ace7874a536d801f308cf1fd03df99 lib/core/target.py
@@ -56,7 +56,7 @@ d43f059747ffd48952922c94152e2a07 lib/core/testing.py
5656
8485a3cd94c0a5af2718bad60c5f1ae5 lib/core/wordlist.py
5757
cc9c82cfffd8ee9b25ba3af6284f057e lib/__init__.py
5858
c1288bc4ce5651dbdd82d4a9435fdc03 lib/parse/banner.py
59-
2debb66e5bd9cf9207b067189402e1e6 lib/parse/cmdline.py
59+
cbca40e76a5a6e93c9fb523f69a99d88 lib/parse/cmdline.py
6060
8ec4d4f02634834701f8258726f2e511 lib/parse/configfile.py
6161
fe4e2152292587928edb94c9a4d311ff lib/parse/handler.py
6262
8e6bfb13e5a34b2610f3ff23467a34cf lib/parse/headers.py
@@ -67,7 +67,7 @@ b40a4c5d91770d347df36d3065b63798 lib/parse/sitemap.py
6767
9299f21804033f099681525bb9bf51c0 lib/request/basicauthhandler.py
6868
083e7f446909b12009e72ae8e5e5737c lib/request/basic.py
6969
c48285682a61d49982cb508351013cb4 lib/request/comparison.py
70-
ab1cc5a69002306db2fd24d71cd0e606 lib/request/connect.py
70+
5d6906483ef57032e28dcc6a9fcfd545 lib/request/connect.py
7171
49b4c583af68689de5f9acb162de2939 lib/request/direct.py
7272
1a46f7bb26b23ec0c0d9d9c95828241b lib/request/dns.py
7373
70ceefe39980611494d4f99afb96f652 lib/request/httpshandler.py

0 commit comments

Comments
 (0)