SMTP authentication uses bytes, not unicode, fixes #126
Encode configuration variables as ascii, ignoring non-ascii characters (Python's smtplib is not yet able to support the UTF8SMTP).
This commit is contained in:
parent
ad1fdfdb32
commit
6a3a9ea114
@ -4,7 +4,8 @@ Changelog for Isso
|
|||||||
0.9.7 (unreleased)
|
0.9.7 (unreleased)
|
||||||
------------------
|
------------------
|
||||||
|
|
||||||
- Nothing changed yet.
|
- fix SMTP authentication using CRAM-MD5 (incorrect usage of
|
||||||
|
`smtplib`), #126
|
||||||
|
|
||||||
|
|
||||||
0.9.6 (2014-08-18)
|
0.9.6 (2014-08-18)
|
||||||
|
@ -66,8 +66,8 @@ class SMTP(object):
|
|||||||
self.client.starttls();
|
self.client.starttls();
|
||||||
|
|
||||||
if self.conf.get('username') and self.conf.get('password'):
|
if self.conf.get('username') and self.conf.get('password'):
|
||||||
self.client.login(self.conf.get('username'),
|
self.client.login(self.conf.get('username').encode('ascii', errors='ignore'),
|
||||||
self.conf.get('password'))
|
self.conf.get('password').encode('ascii', errors='ignore'))
|
||||||
|
|
||||||
return self.client
|
return self.client
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user