mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
More codestring -> codebytes.
This commit is contained in:
parent
3ed0deb9af
commit
706824f19f
10 changed files with 16 additions and 15 deletions
|
@ -540,7 +540,7 @@ class SMTP:
|
|||
"""
|
||||
|
||||
def encode_cram_md5(challenge, user, password):
|
||||
challenge = base64.decodestring(challenge)
|
||||
challenge = base64.decodebytes(challenge)
|
||||
response = user + " " + hmac.HMAC(password.encode('ascii'),
|
||||
challenge).hexdigest()
|
||||
return encode_base64(response.encode('ascii'), eol='')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue