TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [TCLUG:11223] Any Ideas about Refusing mail



>
> --------- Forwarded message ----------
> Date: Thu, 16 Dec 1999 10:56:35 -0600
> From: Mark Blaubach <mblaubach@sabis.net>
> To: jonathankl@ism-sabis.net
> Subject: Refusing mail
>
> Jon,
>
> Do you know of any way to put in a user's profile a way to refuse
> mail from specific addresses?  We have a student who is getting
> mail from outside the school that is disturbing to her.  I think
> there is some way to stop its delivery.  Let me know if you have any info.


The best way to do this would be via the 'procmail' mail filtering
program -- a lot of Linux dists already come with procmail installed &
running, you just need to set up rules in /etc/procmailrc or
~user/.procmailrc (look for lines in /etc/sendmail.cf like:

Mprocmail,      P=/usr/bin/procmail, F=DFMSPhnu9, S=11/31, R=21/31,
T=DNS/RFC822/X-Unix,
                A=procmail -Y -m $h $f $u
Mlocal,         P=/usr/bin/procmail, F=lsDFMAw5:/|@qSPfhn9, S=10/30,
R=20/40,
                A=procmail -Y -a $h -d $u
)

Otherwise, the install is a little tricky (especially if you're not to
familiar w/ sendmail) but well worthwhile.  Procmail should work on pretty
much any UNIX system running sendmail or a similar SMTP-compatible MTA.