Mail filtering at server
kdk at daleco.biz
Sun Jan 15 18:17:44 PST 2006
Frank Staals wrote:
> I'm running FreeBSD 5-stable and I'm using the
> system as mailserver, so I set up sendmail using
> this guide:
> as imap server I'm using imap-uw. Now I would like to do the following:
> 1) I would like to get all mail from questions at freebsd.org
> in a seperate directory. Currently I do this by filtering my
> mail in the mailclient ( Thunderbird ). The directory it uses
> for this is currently ~/mail/Questions/ so I would like to keep
> that, how can I do this ? Can I add this to /etc/mail/access ?
> what would then be the syntax ?
> 2) I would also like to filter my mail for spam, again:
> currently I set up thunderbird to do this: the mail
> marked as spam/junk dissapears into the junk folder:
> ( ~/mail/junk ) What is the best way to set this up ?
> can this be done by sendmail itself or should I install
> an other program from the portstree
> Thanks in advance,
First question: what's wrong with the way TBird does it?
(Sorry, that's the "consultant" in me coming out....) It does
seem like you want whatever you use to do it in the same
way that it's currently being done, so why change?
In particular, your (2) above is an area of little consensus;
about the only thing most people agree on is that spammers
should have *some* body part removed, but we can't even
agree which one, much less exactly how to handle their
Some argue that spam should not be processed by your
MTA at all; this has resulted in "blacklisting" and "greylisting".
Others figure that an automatic "trashing" of the spam after
receipt is OK. First, decide which you are/want to be.
Sendmail has, IIRC, a built in way to check RealTime blackhole
DNS lists. Any farther than that, you get into Milter (Mail
fILTER) or SpamAssassin (as mentioned previously) or Amavis
+SpamAssassin, or ..., or ... (there are several ways to skin
Quite possibly, the best question for you ATM is: are you
protecting just yourself from spam, or are others going to
be affected by what you do to your SendMail?
Then, do some research and reading on the problem.
I've tried SendMail+Amavis+SpamAssassin with some success.
One big issue for me: time to administer the server, in particular
the "learning curve" phase.
I've also done some other tricks, like listing IP blocks against
sendmail in /etc/hosts.allow; but this has gotten me into trouble
as, occasionally, international correspondents (like here on the
lists) ended up "blocked" by my MTA.
So, good luck! and, "to each his own".
Love is the delusion that one woman differs from another.
-- H. L. Mencken
More information about the freebsd-questions