Re: [exim] variables at acls

Pàgina inicial
Delete this message
Reply to this message
Autor: Marten Lehmann
Data:  
A: exim-users
Assumpte: Re: [exim] variables at acls
Hello,

> with every recipient, set an acl_c* variable if and only if there is
> some spamcheck action to be performed. pass the mail to spamd if it's
> set.


I'm trying to do this, but I couldn't figure out how to do it yet. This
is a part of my configure-file (acl_check_rcpt):

   accept  domains       = +local_domains
           endpass
           verify        = recipient
           set acl_c0    = ${if or { \
                                    {or { \


{eq{${lookup{$local_part@$domain}lsearch*@{/mailin/conf/antispam.txt}}}{subject-rewrite}}
\

{eq{${lookup{$local_part@$domain}lsearch*@{/mailin/conf/antispam.txt}}}{junk-folder}} 
\
                                    }} \
                                    {eq{$acl_c0}{yes}} \
                                } \
                           } {yes}{no}}


During the test I'm receiving this:

lookup{$local_part@$domain}lsearch*@{/vrmd/mailin/conf/antispam.txt}}}{junk-folder}}
}} {eq{$acl_c0}{yes}} } } {yes}{no}}
 >>>                  = true {yes}{no}}
 >>> accept: condition test succeeded

250 Accepted

This looks good. But acl_c0 doesn't seem to be set. Here is another part
of my config (acl_check_data):

   warn    spam      = nobody
           condition = ${if and { \
                                  {<{$message_size}{100K}} \
                                  {eq{$acl_c0}{yes}} \
                            } \
                       }
           message = X-Spamcheck: $acl_c0


Thus returns:

>>> using ACL "acl_check_data"
>>> processing "warn"
>>> check spam = nobody
>>> check condition = ${if and { {<{$message_size}{100K}}

{eq{$acl_c0}{yes}} } }
 >>>                 =
 >>> warn: condition test failed
 >>> processing "accept"


The message is 100K and actually I expected this condition to succeed.

And what I'm still wondering about is that the spamcheck is done somehow
anyway, because according to the transport a subject-rewrite takes place
and it really takes place although the spam-condition was failing:

address_directory:
[...]
headers_add = ${if and { \

{eq{${lookup{$local_part@$domain}lsearch*@{/vrmd/mailin/conf/antispam.txt}}}{subject-rewrite}} 
\
                         {eq{$spam_score_int}{10}} \
                     } {Subject: [SPAM?] $h_Subject:}{}}


It seems that I missed some details of the spamfilter and
acl-functioning. Any ideas?

Regards
Marten