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

Skip to content

Commit 703b707

Browse files
committed
Fixes #3319
1 parent ef52ee9 commit 703b707

3 files changed

Lines changed: 12 additions & 3 deletions

File tree

lib/core/option.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1367,6 +1367,14 @@ def _setHTTPCookies():
13671367

13681368
conf.httpHeaders.append((HTTP_HEADER.COOKIE, conf.cookie))
13691369

1370+
def _setHostname():
1371+
"""
1372+
Set value conf.hostname
1373+
"""
1374+
1375+
if conf.url:
1376+
conf.hostname = urlparse.urlsplit(conf.url).netloc.split(':')[0]
1377+
13701378
def _setHTTPTimeout():
13711379
"""
13721380
Set the HTTP timeout
@@ -2479,6 +2487,7 @@ def init():
24792487
parseTargetDirect()
24802488

24812489
if any((conf.url, conf.logFile, conf.bulkFile, conf.sitemapUrl, conf.requestFile, conf.googleDork, conf.liveTest)):
2490+
_setHostname()
24822491
_setHTTPTimeout()
24832492
_setHTTPExtraHeaders()
24842493
_setHTTPCookies()

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.2.10.37"
22+
VERSION = "1.2.10.38"
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)

txt/checksum.md5

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,14 @@ cada93357a7321655927fc9625b3bfec lib/core/exception.py
4242
1e5532ede194ac9c083891c2f02bca93 lib/core/__init__.py
4343
458a194764805cd8312c14ecd4be4d1e lib/core/log.py
4444
7d6edc552e08c30f4f4d49fa93b746f1 lib/core/optiondict.py
45-
18f33e43a09f5d682b92ca63baacd531 lib/core/option.py
45+
d6dace6468ed5d2bbd500b0a244a9650 lib/core/option.py
4646
c8c386d644d57c659d74542f5f57f632 lib/core/patch.py
4747
6783160150b4711d02c56ee2beadffdb lib/core/profiling.py
4848
6f654e1715571eff68a0f8af3d62dcf8 lib/core/readlineng.py
4949
0c3eef46bdbf87e29a3f95f90240d192 lib/core/replication.py
5050
a7db43859b61569b601b97f187dd31c5 lib/core/revision.py
5151
fcb74fcc9577523524659ec49e2e964b lib/core/session.py
52-
07e1402306b18144c9a4d2e1e43ce9d0 lib/core/settings.py
52+
dc1382ae6b5899619d11d972435c6bd2 lib/core/settings.py
5353
dd68a9d02fccb4fa1428b20e15b0db5d lib/core/shell.py
5454
a7edc9250d13af36ac0108f259859c19 lib/core/subprocessng.py
5555
721198b5be72c8015a02acb116532a1f lib/core/target.py

0 commit comments

Comments
 (0)