Tim Rice schreef:
:0
* ^From:(_dot_)*z(_at_)somewhereXcom
* ^To:.*(a|b)@domainXcom
{
:0 c
|$SENDMAIL -oi a(_at_)domainXcom \
b(_at_)domainXcom
}
The above should not loop
But will deliver multiple copies.
$SENDMAILFLAGS is often "-oi".
It is always much better to add an X-Loop: header field.
And to not use real domain names, registered or not, for examples.
H_XLOOP = "X-Loop: $LOGNAME!$HOST"
:0
* ^From:.*\<z(_at_)example\(_dot_)com\>
* ^To:.*\<(a|b)@example\.com\>
*!$ ^$\H_XLOOP
{
:0 fhw
| formail -I"${H_XLOOP}"
:0
! a(_at_)example(_dot_)com b(_at_)example(_dot_)com
}
(untested)
The From: and To: conditions are not very secure!
--
Groet, Ruud
____________________________________________________________
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