SMTP AUTH with Exim

Posted by Ceri Davies Tue, 22 Nov 2005 00:01:00 GMT

Although I am unsure of both the wisdom and utility of dragging my laptop to EuroBSDcon, I’m also sure that I don’t want to get laughed at for using mutt again. Kmail seems a little more stable than a year ago, and my IMAP setup is seeing the benefit of experience too.

Not reading your mail from the same command line all the time brings another problem though: how to send outbound mail?

The obvious solution is SMTP AUTH, but I’ve always shied away from actually looking at how to do it. Turns out that Exim makes it an utter piece of cake.

Simply add an authenticator for the AUTH mechanism of your choice:

lookup_cram:
  driver = cram_md5
  public_name = CRAM-MD5
  server_secret = ${lookup{$1}lsearch{/usr/local/etc/exim/authpwd}{$value}fail}
  server_set_id = $1

(Note that I previously added an authenticators section to my exim configuration; if you don’t already have one, you’ll need to add it.)

You’ll also need to edit your acl_smtp_rcpt ACL and add:

 accept  authenticated = *

at an appropriate point.

Then create /usr/local/etc/exim/authpwd which contains a username:password pair on each line, separated by a comma. Make sure that this file has appropriate permissions, of course. Easy.

Posted in ,  | no comments | no trackbacks

Comments

Trackbacks

Use the following link to trackback from your own site:
http://typo.submonkey.net/articles/trackback/53

Comments are disabled