Skip to content

Commit eed8d7e

Browse files
committed
finalizing support for IPv6
1 parent b6d37d7 commit eed8d7e

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

lib/core/common.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3056,7 +3056,9 @@ def getHostHeader(url):
30563056

30573057
retVal = urlparse.urlparse(url).netloc
30583058

3059-
if any(retVal.endswith(':%d' % _) for _ in [80, 443]):
3059+
if re.search("http(s)?://\[.+\]", url, re.I):
3060+
retVal = extractRegexResult("http(s)?://\[(?P<result>.+)\]", url)
3061+
elif any(retVal.endswith(':%d' % _) for _ in [80, 443]):
30603062
retVal = retVal.split(':')[0]
30613063

30623064
return retVal

0 commit comments

Comments
 (0)