procmail
[Top] [All Lists]

Re: Procmail Bounce Back? Script Question

2001-07-12 14:22:33
At 10:35 2001-07-12 -0700, Joe Sena wrote:
I was wondering how I would go about writing a Procmail script that
would send back a message to someone who emailed my mail server, but the
person they emailed no longer existed.  This would replace the typical
mailer daemon thing, instead giving a message like "The person you have
emailed is no longer employed here. Please update your address book
accordingly."

If you're running sendmail, the virtusertable facility provides an easy way to accomplish this (which ironically, is probably the mechanism you'd have to use to direct all the closed accounts to one account where the script resides).

someusernolongerhere(_at_)somedomain(_dot_)com ERROR: 550 The person you have emailed is no longer employed by somecompany. Please update your address book accordingly.

Without at least a virtusertable or alias directing individual old addresses to an account where you're running the procmail script, you've got to redirect a wildcard (after having any other accounts specified), which means that you'd bounce this sort of message for all bad addresses (including misspellings of people still employed).

So, before we all get into something which by all rights should be covered in the FAQ, it'd be a good idea to evaluate how it is you're going to have the server direct the mail to a procmail script in the first place.

---
 Sean B. Straw / Professional Software Engineering

 Procmail disclaimer: <http://www.professional.org/procmail/disclaimer.html>
 Please DO NOT carbon me on list replies.  I'll get my copy from the list.

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>