emacs-devel
[Top][All Lists]
Advanced

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

Re: smtpmail and ~/.authinfo


From: Lars Magne Ingebrigtsen
Subject: Re: smtpmail and ~/.authinfo
Date: Sun, 21 Aug 2011 06:39:12 +0200
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux)

Eli Zaretskii <address@hidden> writes:

> It turned out that ~/.authinfo _must_ have Unix EOLs, or else sending
> mail with smtpmail not work.  This happens because auth-source-search
> is called from smtpmail inside a form that let-binds
> coding-system-for-read to `binary'.  That binding is there for reasons
> that have nothing to do with auth-source-search, and a cursory search
> finds no similar bindings in other users of auth-source-search.

Yes, that sounds like an accident.  Perhaps that let binding should be
narrowed dramatically?  It's bad practise to bind variables like that
over non-relevant function calls.

> It should be easy to fix this, but I need to know what can be in Netrc
> files to do this correctly.  Can these files include non-ASCII
> characters, or do all fields in these files have to be strict 7-bit
> ASCII?

There can basically be anything in the files, I think, and the encoding
is local.  But it's unusual to put non-ASCII into the file for most
protocols, since so many protocols developed their auth schemes before
anybody had considered the problem of coding systems.

> Also, is there any need to do something special with non-ASCII
> characters (if they are allowed) when communicating with the SMTP
> server, like encode them in some particular way?

It...  varies.  :-)  SMTP allows using several AUTH methods, and I'm
actually not sure whether any of them actually specify what charset to
use.  DIGEST-MD5 does, I think?  But smtpmail.el doesn't support it,
anyway.

I think AUTH PLAIN, for instance, is basically essentially a binary
thing, where you're allowed to use any blob of bytes as user name and
password.  Except NULs.

This is just from memory, so if somebody knows better, please correct
me... 

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



reply via email to

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