Skip to content

pythongh-96035: Make urllib.parse.urlparse reject non-numeric ports #98271

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

Closed
wants to merge 1 commit into from
Closed

Conversation

kenballus
Copy link
Contributor

@kenballus kenballus commented Oct 15, 2022

urllib.parse.urlparse uses int to parse port numbers, which means they can contain '+', '-', '_', and whitespace. This patch adds a check that ensures that only numeric port numbers parse without error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants