Skip to content

Commit a4ac1fa

Browse files
committed
update util.base_url to handle python 3.9.17 change to urllib.parse.urlsplit
https://docs.python.org/release/3.9.17/whatsnew/changelog.html#changelog > gh-102153: urllib.parse.urlsplit() now strips leading C0 control and space characters following the specification for URLs defined by WHATWG in response to CVE-2023-24329. Patch by Illia Volochii. python/cpython#102153
1 parent 4abf3b0 commit a4ac1fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

util.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ def base_url(url):
586586
Args:
587587
url: string
588588
"""
589-
return urllib.parse.urljoin(url, ' ')[:-1] if url else None
589+
return urllib.parse.urljoin(url, 'x')[:-1] if url else None
590590

591591

592592
def is_web(url):

0 commit comments

Comments
 (0)