misc: remove port from host when it's https and 443 (#18092)
This commit is contained in:
parent
1210c43ce0
commit
4a12044671
|
@ -160,7 +160,15 @@ def skeleton(request):
|
|||
raise PermissionDenied()
|
||||
source = request.GET['source']
|
||||
|
||||
netloc = urlparse.urlparse(source).netloc
|
||||
parsed_source = urlparse.urlparse(source)
|
||||
netloc = parsed_source.netloc
|
||||
if parsed_source.scheme == 'https' and netloc.endswith(':443'):
|
||||
# somme HTTP client (like Mozilla/1.1 (compatible; MSPIE 2.0; Windows
|
||||
# CE)) will make request with an explicit :443 port in the Host header;
|
||||
# it will then be used in constructing page URL and will end up in the
|
||||
# ?source= parameter of this call. Remove it.
|
||||
netloc = netloc.replace(':443', '')
|
||||
|
||||
selected_page = None
|
||||
same_domain_pages = []
|
||||
|
||||
|
|
Loading…
Reference in New Issue