On 13 Nov, Errol Casey wrote:
| [...]
|
| Here is my first attempt which doesn't seem to be working.
|
| :0
| * ^From: MAILER-DAEMON(_at_)amr(_dot_)boo-bear(_dot_)com
| * ^Subject: failure notice
| {
| :0
| * ^Subject: Please confirm your message
| | $FORMAIL -I "Subject:[TMDA Bounce] " >> ${MAILDIR}/bounces
| }
|
| Here is full sample bounce message that I want to filter:
|
| >From MAILER-DAEMON(_at_)amr(_dot_)boo-bear(_dot_)com Tue Nov 13 12:16:00
2001
| Return-Path: <#(_at_)[]>
| Delivered-To: errol(_at_)amr(_dot_)boo-bear(_dot_)com
| Received: (qmail 20157 invoked by alias); 13 Nov 2001 17:15:48 -0000
| Delivered-To: postmaster(_at_)amr(_dot_)boo-bear(_dot_)com
| Received: (qmail 20152 invoked for bounce); 13 Nov 2001 17:15:48 -0000
| Date: 13 Nov 2001 17:15:48 -0000
| From: MAILER-DAEMON(_at_)amr(_dot_)boo-bear(_dot_)com
| To: postmaster(_at_)amr(_dot_)boo-bear(_dot_)com
| Subject: failure notice
| X-SpamBouncer: 1.5 beta (8/24/01)
| X-SBNote: MAILER-DAEMON
| X-SBNote: FROM_DAEMON/Listserv
| X-SBRule: Pattern Match (Numeric or Obscured URL) (Score: 2100)
| X-SBRule: Pattern Match (Disclaimer) (Score: 1700)
| X-SBRule: Pattern Match (HTML) (Score: 8000)
| X-SBRule: Pattern Match (Other Patterns) (Score: 1700)
| X-SBPass: No Freemail Filtering
| X-SBClass: Blocked
| Content-Length: 6972
| Lines: 192
|
| Hi. This is the qmail-send program at amr.boo-bear.com.
| I tried to deliver a bounce message to this address, but the bounce bounced!
|
| <cnrh9r7mpdr(_at_)hotmail(_dot_)com>:
| 64.4.49.7 does not like recipient.
| Remote host said: 550 Requested action not taken:user account inactive
| Giving up on 64.4.49.7.
|
| --- Below this line is the original bounce.
|
| Return-Path: <>
| Received: (qmail 19775 invoked by uid 501); 13 Nov 2001 16:49:05 -0000
| Date: 13 Nov 2001 16:49:05 -0000
| Message-ID:
<20011113164905(_dot_)19773(_dot_)qmail(_at_)amr(_dot_)boo-bear(_dot_)com>
| From: errol(_at_)amr(_dot_)homeip(_dot_)net
| Subject: Please confirm your message
|
| [snipped 179 lines of crap]
Don't copy unnecessary stuff. Especially that crap. It took me 2
seconds to snip it. You should've done the same and saved *everyone* on
the list the grief. I came "" far from not answering because of it.
The second ^Subject: is in the body, not the headers, so the inner
recipe never matches. You want something like:
:0
* ^From: MAILER-DAEMON(_at_)amr(_dot_)boo-bear(_dot_)com
* ^Subject: failure notice
* B ?? ^Subject: Please confirm your message
| $FORMAIL -I "Subject:[TMDA Bounce] " >> ${MAILDIR}/bounces
You also might want a lock file on that. I don't think you can use an
implicit one so didn't included it, but I may be wrong.
--
Reply to list please, or append "6" to "procmail" in address if you must.
Spammers' unrelenting address harvesting forces me to this...reluctantly.
/"\
Don Hammond \ / ASCII Ribbon Campaign
Raleigh, NC US X Against HTML Mail,
/ \ and News Too
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail