[Exim] Allow message to work with accept in ACLs?

Pàgina inicial
Delete this message
Reply to this message
Autor: Eli
Data:  
A: exim-users
Assumpte: [Exim] Allow message to work with accept in ACLs?
I was wondering if anyone else has though of having this feature or not?

Currently I have my spam scanning ACL do this at the top:

        warn    message         = X-Spam-Error: Message too big, scan
skipped
                condition       = ${if > {$message_size}{5M} {yes}{no}}


        accept  condition       = ${if > {$message_size}{5M} {yes}{no}}


So that it can bypass any emails that are too large for scanning. I don't
like having to duplicate an identical condition in two places since I later
plan to use MySQL to get the message size limit, so I'd be doing 2 queries
when it would be nice to reduce it to just 1.

Being able to use message with an accept would allow you to insert headers
and accept things at the same time, as well as provide additional message
info when accepting things. For my example, it could be rewritten like
this:

        accept  message         = X-Spam-Error: Message too big, scan
skipped
                condition       = ${if > {$message_size}{5M} {yes}{no}}


Which would be rather nice. Other uses would be say, if you had an accept
which accepted email even though it had a high spam rating - you could
accept it, but also provide some kind of additional header/message stating
that you accepted it, but with some protest. Of course that wouldn't do
anything to prevent spammers, but the idea could be applied elsewhere.

First I'm wondering if anyone knows how easy/complicated it would be to make
a patch that would allow this (is it hard to set what statements "message"
can be used with?), and I'm also wondering if this would be a useful idea or
not - comments?

Or maybe I'm missing something that would allow me to do this without
mucking with how things work already? :)

Eli.