It probably is a boneheaded error along those lines, but the name of the
server is correct in my actual recipe. We do have external domain filters (so
somebody can't come in a "borrow" our fax server, but why test things
unnecessarily. It does confuse the post, though!
I lifted the RE that expands from the ^TO_ macro and stuck it into a perl
script and it worked beautifully. I'm now wondering whether there is some -ah-
uniqeness in the manner that procmail handles this regular expression.
$line = $_ if(/(^((Original-)?(Resent-)?(To|Cc|Bcc)|(X-Envelope|Apparen
tly(-Resent)?)-To):(.*[^-a-zA-Z0-9_.])?).*[0-9].*fax/i) ;
------------------------
From: Stan Ryckman <stanr(_at_)sunspot(_dot_)tiac(_dot_)net>
Subject: Re: Detecting alpha address -- a regular expression question
Date: Wed, 05 Nov 1997 23:26:00 -0500
To: cknox(_at_)us(_dot_)dhl(_dot_)com
Cc: procmail(_at_)Informatik(_dot_)RWTH-Aachen(_dot_)DE
At 10:23 AM 11/5/97 -0700, cknox(_at_)us(_dot_)dhl(_dot_)com wrote:
We are implementing a (shudder) mail-to-fax gateway. The syntax is
<faxnum>@server.domain.com
^^^^^^^^^^^^^^^^^^
The rather head-injured fax beast gleefully passes alphabetic characters to
the fax modem.
I'm using the following recipe to attempt to filter out alpha characters.
:0
* ^To:(_dot_)*[a-zA-Z](_dot_)*(_at_)fax(_dot_)*
^^^^^
Looks great, but the trouble is that stuff sails right through it.
Typo? Try replacing "@fax" with "@server" (or even just "@"). Also,
there's no point to the trailing ".*".
Cheers,
Stan
---------------End of Original Message-----------------
-------------------------------------------------------------------
Chris Knox |
cknox(_at_)us(_dot_)dhl(_dot_)com
DHL Airways, Inc. | (602) 350-2026
1900 West University Drive |
Tempe, Arizona 85281 |
-------------------------------------------------------------------