Thus spake Sam Varshavchik on Thu, May 13, 2004 at 06:12:06PM CDT > [EMAIL PROTECTED] writes: > > >I found a workaround for this, and it's apparently a bug in Courier. > >Standard policy for mail accounts here is to have the account's > >.mailfilters/rcptfilter exit with an EXITCODE of 99, which causes my virus > >filter to look at the message as well as .mailfilters/smtpfilter. If I > >exit > >rcptfilter with EXITCODE = 0, then the problem doesn't occur. I can safely > >do this if I make it conditional on TCPREMOTEIP being the server's IP, or > >the localhost IP, or some other trusted IP. > > The localmailfilter man page: > > rcptfilter > > The mail filter is invoked initially when the remote mail server > specifies this address as a recipient. FILTER should terminate with one of > the following exit codes: 0 - this sender is acceptable; 99 - this sender > is acceptable, but I want to run the content filter for this the message; > any other non-zero exit code - the sender is not acceptable, reject the > message. Sam, I've read this all over 3 or 4 times, and it's very arcane! - and a bit difficult to get my head around. I understnad that the final result of the DATA command signifies the fate of the email to the sending system. In this case the 412 error is being delivered after the rcpt to envelope directive. Courier allows the session to continue, but I don't know of an SMTP client or peer server out there that won't terminate the session after a 400 class error is emitted by the corresponding server.
Nonetheless, I understand that this is done by design, and because there's an acceptable workaround for it based on TCPREMOTEIP in the mail filters, I'll just let it be and give the issue some more thought. Thanks, as always, for your very technically descriptive reply. I'd far rather have an explanation that I have to spend some time scratching my head over than one that's dismissive or oversimplified :-) > The issue here is that with content filtering, it is possible for one > recipient's mail filter to reject a message, and another recipient's give > it a clean bill of health. In SMTP, the final DATA command has one error > code, and the DATA command rejects the message, the sender will consider > that all recipients are undeliverable, and bounce the message accordingly, > even though some recipients did receive the message. > > So, if things are left as they are, if we're both on the same mailing list, > and I start bouncing its traffic with my filter, both of us will get > bounced off the list. > > As such, mail filtering is done on an opt-in basis. What happens is that > the message's first recipient determines whether Courier will accept the > message only for the filtering recipients' this time, or not, and everyone > else gets a 4xx message, so the sender will simply re-deliver them a little > later. Essentially, the multiple recipients of a given message are split > into two groups: those that will content-filter this message, and those > that won't. Presumably, if you opt-in into mail filtering you accept the > risk of getting bounced off some places. If you don't opt-in into mail > filtering you will not be affected by anything the filtering recipients do. > If you're on a mailing list, you're expected to whitelist the mailing list > sender, by return a 0 exit code, and not filtering it. > > As such, forwarding is treated as a whitelisted address, not subject to > content filtering. > -- Lindsay Haisley | "Everything works | PGP public key FMP Computer Services | if you let it" | available at 512-259-1190 | (The Roadie) | <http://www.fmp.com/pubkeys> http://www.fmp.com | | ------------------------------------------------------- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
