emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

smtpmail support of unicode passwords


From: Garreau\, Alexandre
Subject: smtpmail support of unicode passwords
Date: Sun, 13 Apr 2014 20:27:49 +0200
User-agent: Gnus (5.13), GNU Emacs 24.3.50.1 (x86_64-pc-linux-gnu)

Hello, smtpmail fails to send mails when the SMTP user password contain
utf8 chars, since it seems base64-encode-string doesn’t support
multibyte encoding, it prevented me to start using Gnus for some months
before I understood what was happening.

Here’s attached the patch.

diff -Naur emacs-old/lisp/mail/smtpmail.el emacs/lisp/mail/smtpmail.el
--- emacs-old/lisp/mail/smtpmail.el     2014-04-13 18:08:54.210814676 +0000
+++ emacs/lisp/mail/smtpmail.el 2014-04-13 18:06:07.502802860 +0000
@@ -580,7 +580,7 @@
       (smtpmail-command-or-throw
        process
        (concat "AUTH PLAIN "
-              (base64-encode-string (concat "\0" user "\0" password) t))
+              (base64-encode-string (string-as-unibyte (concat "\0" user "\0" 
password)) t))
        235))
      (t
       (error "Mechanism %s not implemented" mech)))))

Attachment: signature.asc
Description: PGP signature

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]