Deployment:Linux:MTA:Sendmail
From Main
[edit]
Setting up Sendmail with PLAINTEXT auth against a smarthost
[edit]
The Problem
I have a Rogers @HOME connection and wanted to setup sendmail to act as a client but rogers requries plaintext auth, and these MTAs refuse to do plaintext without a secure connection (which is the way it should be!!!!!)
Part 1 - The Smarthost part (fairly straight forward)
define(`SMART_HOST',`smtp.broadband.rogers.com')
Part 2 - The Auth Part
Google it and you'll see stuff like:
How to use the sendmail authinfo:
(in sendmail.mc)
FEATURE(`authinfo', `hash /etc/mail/auth/client-info')
Also, not sure whether this is necessary, it may be
define(`confAUTH_OPTIONS', `c ')dnl
(in /etc/mail/auth/client-info)
AuthInfo:smtp.broadband.rogers.com "U:email@rogers.com" "P:mysecretpassword" "M:LOGIN PLAIN"
The M:LOGIN PLAIN part is very important
- So, you're suppose to edit sendmail.mc and then generate the sendmail.cf you do that with these commands
Backup sendmail.cf before you start cp /etc/mail/sendmail.cf /etc/mail/sendmail_before_messing_around.old m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf
- If you stop there with authinfo it won't work, you got the generate a .db file as follows (i don't exactly know what that does)
$ makemap hash client-info < client-info $ chmod 600 client-info client-info.db $ service sendmail restart #This only works for Redhat based linux. Other flavors try typing: /etc/init.d/sendmail restart $ # If you have stuff stuck in you queue (ie, type mailq) then you can process it with this $ /usr/lib/sendmail -v -q
- If things don't work, check your maillog (/var/log/maillog) to see the exact error.

