Hi

After emerging sendmail i first configured it by adding the line
Code:
DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl
to /etc/mail/sendmail.mc, hoping to allow only localhost to send mails.
After starting sendmail i couldn't send any mails :
Code:
aim-nano ~ # sendmail testuser@ifi.unizh.ch
testing

sendmail: Cannot open aim-nano.unizh.ch:25
Following some advice found on the web, i added the following line to hosts.allow:
Code:
sendmail: localhost : allow
This didn't change the ability to send mails (still "cannot open...") but
telnet worked over the smtp port:
Code:
aim-nano ~ # telnet localhost smtp
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 aim-nano.unizh.ch ESMTP Sendmail 8.14.0/8.14.0; Wed, 12 Sep 2007 12:02:01 +0200
ehlo aim-nano.unizh.ch
250-aim-nano.unizh.ch Hello localhost [127.0.0.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-EXPN
250-VERB
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-DELIVERBY
250 HELP
quit
221 2.0.0 aim-nano.unizh.ch closing connection
Connection closed by foreign host.
If however i remove the DAEMON_OPTIONS line from sendmail.mc
and reconfigure, and set
Code:
sendmail: 130.60.49.130 : allow
in hosts.allow, i can send mails. But then it seems the port is somehow
open from outside. I can
Code:
telnet aim-nano smtp
from another machine and do an "ehlo" (although other commands give me an
"550 5.0.0 Access denied")

Question: is this (sendmail: 130.60.49.130 : allow) a secure setup?
If not, how do i have to configure things to have a secure localhost-sendmail
situation?

Thank You
Jody