requests
requests copied to clipboard
Use hostname for netrc instead split netloc
This patch uses the "hostname" attribute from the parsed url to get the host, instead of trying to calculate the host from netloc that can produce errors when "http://username:[email protected]" format is used.
This should fix the security issue reported here: CVE-2024-47081: Netrc credential leak in PSF requests library