Skip to content

[2.7] bpo-30500: urllib: Simplify splithost by calling into urlparse. (#1849) #2294

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 20, 2017
Merged

[2.7] bpo-30500: urllib: Simplify splithost by calling into urlparse. (#1849) #2294

merged 1 commit into from
Jun 20, 2017

Conversation

vstinner
Copy link
Member

The current regex based splitting produces a wrong result. For example::

http://abc#@def

Web browsers parse that URL as http://abc/#@def, that is, the host
is abc, the path is /, and the fragment is #@def.
(cherry picked from commit 90e01e5)

The current regex based splitting produces a wrong result. For example::

  http://abc#@def

Web browsers parse that URL as ``http://abc/#@def``, that is, the host
is ``abc``, the path is ``/``, and the fragment is ``#@def``.
(cherry picked from commit 90e01e5)
@vstinner vstinner changed the title [2.7] urllib: Simplify splithost by calling into urlparse. (#1849) [2.7] bpo-30500: urllib: Simplify splithost by calling into urlparse. (#1849) Jun 20, 2017
@vstinner vstinner merged commit d4324ba into python:2.7 Jun 20, 2017
@vstinner vstinner deleted the splithost27 branch June 20, 2017 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-security A security issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants