RE: [Exim] Exim Filter bypass problems

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Chris Sleep
Dátum:  
Címzett: exim-users
Tárgy: RE: [Exim] Exim Filter bypass problems
> ads13@??? said:
> > Could somebody please tell me how to stop exim bypassing the system
> > filter when an e-mail is received from <>. I can't find anything in
> > the docs concerning this effect, but it seems to me (which doesn't
> > mean much) that it's an issue to do with trusted users.


> As Suresh posted, bounce messages with envelope from <> should indeed
> go through the system filter. Thats why the filters I've posted all
> have this stanza quite near the top:-


>     # drop out error messages here
>     if error_message
>     then
>       finish
>     endif


Which was fine until snow white (aka hybris) appeared, which spreads itself
as a bounce message with <> envelope, and thus is passed before the filter
checks. I've now updated my global filter to read (summarised):

if error_message and $message_body matches "my rejection text here"
then
finish
endif

# the above clause will drop out only if an bounce from postmaster is
detected which contains the
# executable filter rejection message, so that these errors are not
refiltered and rebounced back to
# postmaster

[snip some log declararions]

if $header_content-type: matches .... (etc)    # global executable filters
    fail text "my rejection text here"
    seen finish
endif
if $message_body matches .....(etc)            #


# and then the drop out for all other postmaster messages

if error_message
then
finish
endif


- this should mean that all postmaster messages are now checked for
executables, unless they're already bouncing back (without the first clause
any detected executables were failed, and the fail messages were dropped
back into the filter, where the executable filter fired again, bouncing the
error back to postmaster).

As a side note, is there any way to prevent the message generated on a
'fail' from being passed back into the filter?

cheers,

Chris