procmail
[Top] [All Lists]

procmail bounce handling

2008-02-12 10:35:11
Hello list!

I have what seems to be a simple request that is causing me great deals
of problems. If what I am trying to accomplish in procmail/formail is
better handled differently, please tell me so.

I'm creating a dumb bounce handler that will log to a file the original
recipient of a bounce, the date we received it, the Diagnostic-Code and
a special X header that we add to outgoing newsletters. That output then
gets processed by our db team and users are removed. 

What I have so far is a procmailrc with:

FROM=`formail -xFrom:`
DATE=`formail -xDate:`
REASON=`formail -xDiagnostic-Code:`
TODO=`formail -xX-todo_id:`
TO=`formail -xTo:`
:0w:
|/home/www/bounce-thing "$FROM" "$DATE" "$REASON" "$TODO" "$TO"

bounce-thing is a shell script that takes those variables and echo's
them out to my file. 

The problem I have is that I cannot seem to extract either X-todo_id:
(our x header) or Diagnostic-Code from any of the messages. Is there
something really obvious I'm missing about getting those headers out
with formail? Any thoughts are greatly appreciated, I've read through
the faq, google groups, and a handful of other resources and can't seem
to find an answer.

Thanks in advance!

Matthew
-- 
Matthew Boeckman
Sr. Systems Administrator
303-963-7889
mboeckman(_at_)servicemagic(_dot_)com

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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