Patch to prevent problems like Issue #381

This commit is contained in:
Miroslav Stampar 2013-01-31 13:58:39 +01:00
parent cfcf8a3abb
commit d6606a8f31

View File

@ -324,6 +324,10 @@ def _feedTargetsDict(reqFile, addedTargetUrls):
scheme = "https" scheme = "https"
port = port or "443" port = port or "443"
if not host:
errMsg = "invalid format of a request file"
raise SqlmapSyntaxException, errMsg
if not url.startswith("http"): if not url.startswith("http"):
url = "%s://%s:%s%s" % (scheme or "http", host, port or "80", url) url = "%s://%s:%s%s" % (scheme or "http", host, port or "80", url)
scheme = None scheme = None