Using SMTP AUTH with your Smart Relay
(These notes are for RedHat Linux 9. YMMV.)
If you have been assigned a SMTP AUTH username and password for use with your Smart Relay (ie your ISP requires SMTP AUTH when sending email), you'll need to set it up.
For your sendmail configuration, edit your /etc/mail/sendmail.mc
to include these lines:
Don't mess with your submit.mc (like the previous version of this file told you to) -- submit to localhost, then have localhost relay out.
Process them normally into the corresponding .cf files. You will probably have to restart sendmail at this point.
You'll also need an /etc/mail/authinfo
AuthInfo:[220.127.116.11] "U:email@example.com" "P:passwd" "M:DIGEST-MD5"
AuthInfo:jupiter.gridway.net "U:firstname.lastname@example.org" "P:passwd" "M:DIGEST-MD5"
and then process it with
$ makemap hash /etc/mail/authinfo < /etc/mail/authinfo
- Sendmail is anal about ownership/permissions on /etc/mail/authinfo.db, it must be smmsp/smmsp, 640.
- You shouldn't need to put the IP address of your mail server in, the name should be enough, but for me it didn't work for whatever reason.
- The "M:" parameter is optional, and can depend on your local AUTH system's capabilities. PLAIN and LOGIN are not recommended as they are trivial to reverse on the wire; however they may be the only thing available if the sendmail server cannot get access to the unencrypted password (ie if your provider is using LDAP or the system passwd files for authentication). Ideally you should be protecting your session with TLS or something.