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

Skip to content

Commit 3434a22

Browse files
committed
HTTP header HOST is now mandatory in a HTTP request file
1 parent a193205 commit 3434a22

1 file changed

Lines changed: 2 additions & 14 deletions

File tree

lib/core/option.py

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -365,21 +365,9 @@ def __setRequestFromFile():
365365

366366
if host:
367367
conf.url = "%s%s" % (host, page)
368-
elif conf.url: #insert page into here
369-
index = conf.url.find("://")
370-
if index != -1:
371-
index += len("://")
372-
else:
373-
index = 0
374-
375-
index = conf.url.find("/", index)
376-
if index != -1:
377-
conf.url = "%s%s" % (conf.url[:conf.url.find("/", index)], page)
378-
else:
379-
conf.url = "%s%s" % (conf.url, page)
380-
pass #mirek
381368
else:
382-
errMsg = "target url is not known"
369+
errMsg = "mandatory HTTP header HOST is missing in "
370+
errMsg += "the HTTP request file"
383371
raise sqlmapFilePathException, errMsg
384372

385373
def __setMetasploit():

0 commit comments

Comments
 (0)