Sendmail as client via smarthost and ssl
Vincent Hoffman
vince at unsane.co.uk
Fri Oct 29 12:18:14 UTC 2010
On 29/10/2010 11:19, Christopher Illies wrote:
>
> I added "U:smmsp" and "M:PLAIN" to my /etc/mail/auth/client-info file, but
> that did not change anything. When I left out the square brackets around the
> server name in that file, I got another error message in /val/log/maillog:
>
> Oct 29 12:05:22 muck sm-mta[42252]: o9TA5Mtt042250: to=<christopher.illies at web.de>, ctladdr=<chris at muck.ks.se> (1001/1001), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30466, relay=send.ki.se. [130.229.20.28], dsn=4.0.0, stat=Deferred: Name server: send.ki.se.: host name lookup failure
>
> <...>
odd http://www.sendmail.org/~ca/email/sm-812.html#812AUTH has an
example with no square brackets. Not sure why this would break it for you.
>> (I also set up SSL separately as i'm using plain method but you seem to
>> have that covered.)
> Could you explain this a bit further, please? I am not clear on how this works.
> Setting up SSL is done by compiling sendmail with sasl, isn't it? Or is there
> something else to do? Also, the term "plain method" confuses me: This does
> not refer to whether or not you are using ssl?
>
Sorry wrong terminology. That should have been plain mechanism not method.
PLAIN mechanism mean that i'm sending the password/user in plain rather
than using something like DIGEST-MD5 or any of the other possible
mechanisms that can be listed in confAUTH_MECHANISMS in your sendmail
.mc file
to get a list of whats supported by your relay telnet to it on port 25
and issue an EHLO command. the supported mechanisms are listed following
the AUTH keyword.
for example for me
(11:59:59 <~>) 1 $ telnet RELAY.ISP.net 25
Trying 213.xxx.xxx.53...
Connected to RELAY.ISP.net.
Escape character is '^]'.
220 RELAY.ISP.net ESMTP Sendmail 8.13.8/8.13.8; Fri, 29 Oct 2010
12:00:08 +0100
ehlo unsane.co.uk
250-RELAY.ISP.net Hello foo.ISP.net [195.x.x.102], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-AUTH LOGIN PLAIN ---THIS ONE.
250-STARTTLS
250-DELIVERBY
250 HELP
Ignore the ssl comment, I was obviously half asleep, the ssl config I
have is for receiving mail over ssl (server side) not sending (client side)
I have tried copying your steps for testing,
dnl define(`SMART_HOST', `RELAY.ISP.net')dnl
FEATURE(`authinfo',`hash /etc/mail/auth/client-info')dnl
to ostracod.unsane.co.uk.mc (my machines mc file)
[root at ostracod /etc/mail]# make all
/usr/bin/m4 -D_CF_DIR_=/usr/local/share/sendmail/cf/
/usr/local/share/sendmail/cf/m4/cf.m4 ostracod.unsane.co.uk.mc >
ostracod.unsane.co.uk.cf
[root at ostracod /etc/mail]# make install
install -m 444 ostracod.unsane.co.uk.cf /etc/mail/sendmail.cf
install -m 444 ostracod.unsane.co.uk.submit.cf /etc/mail/submit.cf
[root at ostracod /etc/mail]#
then created
/etc/mail/auth/client-info
with
[root at ostracod /etc/mail]# cat /etc/mail/auth/client-info
AuthInfo:RELAY.ISP.net "U:smmsp" "I:USER" "P:PASSWORD" "M:PLAIN"
and then
makemap hash client-info <client-info
restarted sendmail
echo "This is a test " | mail -s "Smarthost test"
vhoffman at domainitdoesntrelayfor.co.uk
and it worked.
If I made the entry in client-info
AuthInfo:[RELAY.ISP.net] "U:smmsp" "I:USER" "P:PASSWORD" "M:PLAIN"
it stopped working.
> Sorry to bother you with all these questions.
Thats fine, what sendmail I do know will be forgotten if i dont use it..
hope these data-points help but it looks like a bit of a "works for me"
without solving your issue.
Vince
> Christopher
More information about the freebsd-questions
mailing list