mirror of
https://github.com/python/cpython.git
synced 2024-11-24 10:24:35 +08:00
patch #624180 (part 2 of 2):
use unquote on authentication strings, to allow users to embed @ and : in user names and passwords (from Phillip Eby)
This commit is contained in:
parent
218c5f9691
commit
768c98bb0b
@ -1065,7 +1065,7 @@ class Transport:
|
||||
|
||||
if auth:
|
||||
import base64
|
||||
auth = base64.encodestring(auth)
|
||||
auth = base64.encodestring(urllib.unquote(auth))
|
||||
auth = string.join(string.split(auth), "") # get rid of whitespace
|
||||
extra_headers = [
|
||||
("Authorization", "Basic " + auth)
|
||||
|
Loading…
Reference in New Issue
Block a user