mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-25 19:13:48 +03:00
Bug fix (--forms with --url without protocol)
This commit is contained in:
parent
c7c7e30130
commit
f544554475
|
@ -4116,7 +4116,12 @@ def checkSameHost(*urls):
|
|||
elif len(urls) == 1:
|
||||
return True
|
||||
else:
|
||||
return all(re.sub(r"(?i)\Awww\.", "", urlparse.urlparse(url or "").netloc.split(':')[0]) == re.sub(r"(?i)\Awww\.", "", urlparse.urlparse(urls[0] or "").netloc.split(':')[0]) for url in urls[1:])
|
||||
def _(value):
|
||||
if value and not re.search(r"\A\w+://", value):
|
||||
value = "http://%s" % value
|
||||
return value
|
||||
|
||||
return all(re.sub(r"(?i)\Awww\.", "", urlparse.urlparse(_(url) or "").netloc.split(':')[0]) == re.sub(r"(?i)\Awww\.", "", urlparse.urlparse(_(urls[0]) or "").netloc.split(':')[0]) for url in urls[1:])
|
||||
|
||||
def getHostHeader(url):
|
||||
"""
|
||||
|
|
|
@ -1511,6 +1511,8 @@ def _cleanupOptions():
|
|||
|
||||
if conf.url:
|
||||
conf.url = conf.url.strip()
|
||||
if not re.search(r"\A\w+://", conf.url):
|
||||
conf.url = "http://%s" % conf.url
|
||||
|
||||
if conf.fileRead:
|
||||
conf.fileRead = ntToPosixSlashes(normalizePath(conf.fileRead))
|
||||
|
|
|
@ -19,7 +19,7 @@ from lib.core.enums import DBMS_DIRECTORY_NAME
|
|||
from lib.core.enums import OS
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.2.12.16"
|
||||
VERSION = "1.2.12.17"
|
||||
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)
|
||||
|
|
|
@ -29,7 +29,7 @@ ad968ee04e93f6f850d6b7e5ac0073c5 lib/controller/controller.py
|
|||
1e5532ede194ac9c083891c2f02bca93 lib/controller/__init__.py
|
||||
e62309b22a59e60b270e62586f169441 lib/core/agent.py
|
||||
c347f085bd561adfa26d3a9512e5f3b9 lib/core/bigarray.py
|
||||
cf84ff84891b7f51620a457b0bff28c5 lib/core/common.py
|
||||
a78c563bbaeebd958b25303d83dfe3f2 lib/core/common.py
|
||||
0d082da16c388b3445e656e0760fb582 lib/core/convert.py
|
||||
9f87391b6a3395f7f50830b391264f27 lib/core/data.py
|
||||
72016ea5c994a711a262fd64572a0fcd lib/core/datatype.py
|
||||
|
@ -42,14 +42,14 @@ cada93357a7321655927fc9625b3bfec lib/core/exception.py
|
|||
1e5532ede194ac9c083891c2f02bca93 lib/core/__init__.py
|
||||
458a194764805cd8312c14ecd4be4d1e lib/core/log.py
|
||||
7d6edc552e08c30f4f4d49fa93b746f1 lib/core/optiondict.py
|
||||
ecf9879967182e6402f3cab6840f5b75 lib/core/option.py
|
||||
b3ffa34552b4594bbba54513069c642b lib/core/option.py
|
||||
c8c386d644d57c659d74542f5f57f632 lib/core/patch.py
|
||||
6783160150b4711d02c56ee2beadffdb lib/core/profiling.py
|
||||
6f654e1715571eff68a0f8af3d62dcf8 lib/core/readlineng.py
|
||||
0c3eef46bdbf87e29a3f95f90240d192 lib/core/replication.py
|
||||
a7db43859b61569b601b97f187dd31c5 lib/core/revision.py
|
||||
fcb74fcc9577523524659ec49e2e964b lib/core/session.py
|
||||
0070ff829f953549bd7a8a65090fa09d lib/core/settings.py
|
||||
380daa313fda2c14c88b69c3461f0e54 lib/core/settings.py
|
||||
a971ce157d04de96ba6e710d3d38a9a8 lib/core/shell.py
|
||||
a7edc9250d13af36ac0108f259859c19 lib/core/subprocessng.py
|
||||
1581be48127a3a7a9fd703359b6e7567 lib/core/target.py
|
||||
|
|
Loading…
Reference in New Issue
Block a user