procmail
[Top] [All Lists]

Re: matching Received

2006-01-06 15:08:34
On Jan 6, 2006, at 11:44 AM, Mr Duck wrote:

   First, it's missing the file locking.

I know.
It's usually not that big a deal, and I use Maildir, so lucking  
is ... so not needed.   :)
YMMV.

   Second, escaping of the @ is not necessary.

I know.
It also doesn't hurt.
Remembering which characters need it, and which don't, in which  
context, makes my head throb.
Which is never a good thing.

I had originally written the recipe w/o the ?? stuff,

Good.

but since that doesn't seem to make
any difference in the effectiveness of the recipe,

It adds a needless level of confusion.
IMHO only, of course.

   Thirdly, adding the square brackets to the Received match
will only complicate the matching process.

Depends.
Sometimes, you really want to match for those brackets, especially if  
someone else is trying something cute.
I just habitually put them in.
Sorry if that disturbs you.

Well, since the
regexp match process is linear, my understanding is that it will
find the first Received line,

Incorrect.
Which was my point.
The un-!-ed rule will match ANY Received: header that contains that  
item.
Negation can become an issue, though.

   I was musing, I think, to determine if it would potentially
try all three Received lines to check for a valid match, or if
once it said "yes this is it - it is a match" then that was all
she wrote..

I think I see the problem.
It's not what you think.
The problem is, the un-negated rule doesn't match the first line it  
sees, so the negation matches.
It's ugly, but there it is.

Aloha mai Nai`a!
-- 
"Please have your Internet License             http://kapu.net/~mjwise/
   and Usenet Registration handy..."



____________________________________________________________
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>