[issue43871] urllib.parse.urlparse doesn't check port

2021-04-17 Thread Alexei Pastuchov
Alexei Pastuchov added the comment: Thank you for your swift response and your willingness to add port validation to _checknetloc. I think the validation itself should compound both exceptional branches implemented in port[3] * port is an int * port is in the range [3] https://github.com

[issue43871] urllib.parse.urlparse doesn't check port

2021-04-16 Thread Alexei Pastuchov
New submission from Alexei Pastuchov : It is possible to get valid ParseResult from the urlparse function even for a non-numeric port value. Only by requesting the port it fails[1]. Would it be an improvement if _checknetloc[2] validates the value of port properly? // code snippet Python