Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 23 Jan 2008 03:25:08 +0200
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        Schiz0 <schiz0phrenic21@gmail.com>
Cc:        Agus <agus.262@gmail.com>, freebsd-questions@freebsd.org
Subject:   Re: Sendmail local only.....
Message-ID:  <20080123012508.GA4036@kobe.laptop>
In-Reply-To: <8d23ec860801221328s601bade5qab86280cd0441ffb@mail.gmail.com>
References:  <fda61bb50801221325p35aae924y116f74c2c026fa1c@mail.gmail.com> <8d23ec860801221328s601bade5qab86280cd0441ffb@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2008-01-22 16:28, Schiz0 <schiz0phrenic21@gmail.com> wrote:
>On Jan 22, 2008 4:25 PM, Agus <agus.262@gmail.com> wrote:
>> Hi guys,
>> Just trying to make sendmail work locally only.....And by that i
>> mean, i dont want sendmail to be able to relay or send mail to any
>> other machine except for localhost....
>>
>> How can i do this? I mean is there a way on rc.conf or i need to
>> touch the cf??
>
> Search the file /etc/defaults/rc.conf for "sendmail"
> It has a bunch of options and explains what they do.
> NOTE: do not edit /etc/defaults/rc.conf - that's just the "Default
> settings" file.
> Make any changes in the /etc/rc.conf file instead.
>
> Basically, you want
>
> sendmail_enable="NO"
>
> And the rest of the sendmail options enabled.

Not all of them, mind you.  I use the following on my laptop:

    sendmail_enable="NO"
    sendmail_outbound_enable="NO"
    sendmail_submit_enable="YES"
    sendmail_msp_queue_enable="YES"

A fairly good explanation of why this setup works only as a 'local MTA',
and doesn't accept incoming SMTP connections from the world can be found
in the manpage of rc.sendmail:

    % man rc.sendmail

To the original poster:

Feel free to use the above sendmail_xxx settings in your `/etc/rc.conf'
file, but please make sure that you also:

    ... understand why these settings make Sendmail only forward locally
    generated email messages, by reading the rc.sendmail manpage.

    ... have configured properly your local `/etc/mail/sendmail.cf' and
    `/etc/mail/submit.cf' files.

    ... read the Handbook section about Sendmail, and let us know if you
    find it difficult to understand, or you would like to see more stuff
    documented.

Cheers,
Giorgos




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080123012508.GA4036>