File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -870,7 +870,7 @@ def __decrypt_assertion(self, xml):
870870 def __normalize_url (self , url ):
871871 """
872872 Returns normalized URL for comparison.
873- This method converts the hostname to lowercase, as it should be case-insensitive (per RFC 4343)
873+ This method converts the netloc to lowercase, as it should be case-insensitive (per RFC 4343, RFC 7617 )
874874 If standardization fails, the original URL is returned
875875 Python documentation indicates that URL split also normalizes query strings if empty query fields are present
876876
@@ -882,6 +882,8 @@ def __normalize_url(self, url):
882882 """
883883 try :
884884 parsed = list (urlsplit (url ))
885+ #scheme and hostname converted to lowercase
886+ parsed [0 ] = parsed [0 ].lower ()
885887 parsed [1 ] = parsed [1 ].lower ()
886888 normalized_url = urlunsplit (parsed )
887889 return normalized_url
You can’t perform that action at this time.
0 commit comments