Path: utzoo!utgpu!attcan!uunet!lll-winken!arisia!trenco!boaz
From: boaz@trenco.uucp (Boaz Ben-Zvi)
Newsgroups: comp.unix.questions
Subject: Re: Mail
Summary: mh,mhook,filter,mail
Keywords: mh,mail,filter
Message-ID: <2398@arisia.Xerox.COM>
Date: 11 Aug 89 22:36:38 GMT
References: <26653@amdcad.AMD.COM>
Sender: news@arisia.Xerox.COM
Reply-To: boaz.pa@xerox.com (Boaz Ben-Zvi)
Organization: Xerox Palo Alto Research Center
Lines: 29

In article <26653@amdcad.AMD.COM> srini@diablo.amd.com () writes:
>
> I would like to know if it is possible to filter outa person's
> mail from reaching me keeping all other things intact.
> That is, say, I don't wish to receive the mails from a person
> X. I know X's address. Now how do I see that even if X attempts
> to send me a mail, i don't receive it. Precisely, what I would
> like to do is send it back to person X with a message saying
> "Not received."

The MH (message handling) system comes with a command called   mhook
(MH receive-mail hooks), and you can do "man mhook" to know more.

The idea behind it is setting your .forward file to have the line:
"| "
where  is a program to which the incoming mail is streamed via
the standard input. You can try and write your program or use MH's. MH
comes with a program named "slocal" that checks fields (like To:, Cc:)
in the message and decides what to do based on some configuration you
give it.


-- Boaz.


Boaz Ben-Zvi

Boaz.pa@xerox.com
(415) 494-4839