Rejecting email with an informative message
Rick Cooper
rcooper at DWFORD.COM
Mon Nov 28 12:28:03 GMT 2005
> -----Original Message-----
> From: MailScanner mailing list [mailto:MAILSCANNER at JISCMAIL.AC.UK]On
> Behalf Of Peter Bates
> Sent: Monday, November 28, 2005 6:18 AM
> To: MAILSCANNER at JISCMAIL.AC.UK
> Subject: Rejecting email with an informative message
>
>
> Hello all...
>
> I'm not sure which bit of MailScanner is best suited to this task,
> so apologies for asking here.
>
> We're getting complaints about a 'persistent offender' sending
> emails to a variety of recipients here, that said recipients want
> blocking.
>
> Normally I'd do this at the MTA, but the Postfix errors are more of
> the
> '550 No thanks' or '550 Please see http://blah/blah' order.
>
> The actual recipients would like to return a nicely formatted
> 'thanks, but no thanks' to this particular sender.
>
> What is the quickest way to do this in MailScanner, to deliver
> some custom message from the reports directory?
>
> Thanks.
>
> P.S. I know the sender could easily sign up with 101 different Hotmail
> addresses, but I'll cross that bridge when I come to it!
>
>
[...]
I am not a postfix expert (Exim) but it's my guess this can still be handle
by the MTA (it could with Exim). I googled some things up and it would
appear that procmail can handle this. A link to an example of doing exactly
what you want with procmail is:
http://acs.ucsd.edu/email/procmail.php
Look at the section heading "Return to sender with "reject" notice (not for
spam!)" and it describes a recipe for discarding mail and sending an e-mail
message back to sender. You would, of course, have to change some things
regarding domain name and such but this works based on sender address and
can be a list or regular expression, apparently.
Rick
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the Wiki (http://wiki.mailscanner.info/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).
Support MailScanner development - buy the book off the website!
More information about the MailScanner
mailing list