Subject: Re: newbie ^FROM_MAILER puzzle

From: [email-masked] (David W. Tamkin)
Date: Tue, 24 Jan 1995 17:02:36 -0600 (CST)

John Martin wondered,

| I must be missing something.  How come
| 
| :0hf
| * ^FROM_MAILER.*procmail
| | formail -A "Status: O"
|   :0A:
|   procmail
| 
| :0hf
| * ^Resent-From:.*procmail
| | formail -A "Status: O"
|   :0A:
|   procmail
| 
| gives
| 
| procmail: No match on "(^(((Resent-)?(From|Sender)|X-Envelope-From):|>?From )(.*[^(.%@a-z0-9])?(Post(ma(st(er)?|n)|office)|(send)?Mail(er)?|daemon|mmdf|root|n?uucp|smtp|response|serv(ices?|er)|Admin(istrator)?)([^).!:a-z0-9].*)?$[^>]).*procmail"
| procmail: Match on "^Resent-From:.*procmail"
| procmail: Executing "formail,-A,Status: O"
| procmail: Locking "procmail.lock"
| procmail: Assigning "LASTFOLDER=procmail"
| procmail: Opening "procmail"
| procmail: Acquiring kernel-lock
| procmail: [3253] Mon Jan 23 17:54:59 1995
| procmail: Unlocking "procmail.lock"
| >From [email-masked]  Mon Jan 23 17:54:58 1995
|  Subject: Re: new mail warning
|   Folder: procmail							   1719

That's exactly right.  ^FROM_MAILER is meant to stand on its own, not to
get something appended to it as ^TO does.  It doesn't match on just 
^Resent-From: but rather on
((some version of From)(something a mailer would call itself)).

If you want to match on either ^FROM_MAILER or on ^Resent-From:.*procmail,
you need a condition like this:

 * ^FROM_MAILER|^Resent-From:.*procmail

David W. Tamkin  Box 3284  Skokie, Illinois  60076-6284
[email-masked]    MCI Mail: 426-1818   +1 312 714 5610