procmail
[Top] [All Lists]

Re: "formail -D" but without updating the cache

2005-11-26 12:13:05
On 11/26/05, Google Kreme <gkreme(_at_)gmail(_dot_)com> wrote:
On 25 Nov 2005, at 23:22 , Bart Schaefer wrote:
So what I'd like to do is cache a signature (the Message-Id for
purposes of example) when the message is first recognized as a virus

No you don't.

Actually, yes, I do.

What you want to do is add a header when a message is  
caught and check for it, much like you do when you forward a message

That won't work.  Sendmail (via the aliases database) has already created 
multiple copies of the message.  I can't insert anything into any one copy and 
have it show up in all the other copies.  I have to work with something that 
already appears in all copies of the message.

(This is an /etc/procmailrc item, in case that wasn't obvious, so it runs for 
all recipients but in some indeterminate sequence.)

And no, for other reasons it won't work to remove the aliases from the database 
and instead have a single copy of procmail that resends to all the desired 
recipients.

Shuffling around copies of the cache as suggested by Ruud and Dallman is in 
fact what I'm already doing.  I've also considered

:0 :virus$LOCKEXT
{
:0
* ? grep -qawe "`formail -x message-id:`" virus.cache
{ ... }
:0E
{ ... }
}

but that depends on message-ids not being proper substrings of one another 
(though the -w makes that less likely to be an issue).


____________________________________________________________
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