1. Does action_tempfail affects all recipients?
Yes.
2. Is delete_recipient needed? If not, wouldn't tempfailed recipient receive a copy of the message?
No, and no.
action_tempfail halts delivery of the message and issues an error code to the sending system. It's just like action_bounce, except that the error code indicates the problem is temporary (overloaded server, down for maintenance, greylisting, whatever) instead of permanent (blacklisted sender, unknown user, etc.).
foreach $recip (@Recipients) {
if (should_greylist($sender, $recip)) {
md_syslog('warning', "Filter Recipient:$sender:$recip");
#delete_recipient($recip);
return action_tempfail("Tempfailed as anti-spam measure. Please try again.");
delete_recipient($recip);
}
}
Remember, any time you call return, it'll stop processing the subroutine. So in this case, it will *never* call delete_recipient, and it will only run up to the first recipient that triggers should_greylist().
Kelson Vibber
SpeedGate Communications <www.speed.net>
_______________________________________________ Visit http://www.mimedefang.org and http://www.canit.ca MIMEDefang mailing list [EMAIL PROTECTED] http://lists.roaringpenguin.com/mailman/listinfo/mimedefang

