You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by #Ronan McGlue <r....@qub.ac.uk> on 2007/02/27 15:02:34 UTC
per user scanning
I currently use exim on the MTAs and have SA using MySQL with the
following data_acl entry
warn message = X-Spam-Score: $spam_bar ($spam_score)\n\
X-Spam-Score-Int: $spam_score_int
condition = ${if <{$message_size}{80k}{1}{0}}
set acl_m9 = 1
spam = nobody:true
set acl_m9 = 0
# defer if spamd has not responded
defer message = Unable to scan message - please try later
condition = $acl_m9
I am looking to move to peruser scanning, so I would need to change only
one line of the above to
spam = $local_part:true
which will use the local part of the email address as the username.
Is this all that needs done IIUC, from the server mail side for users to
start using personal preferences.
Obviously I need to cobble together a wepage front end which
authenticates users and then lets them edit their entries in the MySQL...
i see the 3 projects on the WIKI for peruser/mysql, but they appear to
be unmaintained.
Anything else I need to know, or any other docs would be helpful to me!?
in SA local.cf do i need to make any changes to ether
user_awl_sql_username
bayes_sql_username
etc
R
--
Regards
Ronan McGlue
===================
Analyst / Programmer
Queens University Belfast
Re: per user scanning
Posted by Tony Finch <do...@dotat.at>.
On Tue, 27 Feb 2007, #Ronan McGlue wrote:
>
> what information is available during the DATA_ACL eg to perform lookups on to
> get the username to use for SA?
The only thing that Exim provides is the list of all recipients,
$recipients (plural). What I would recommend that you do is use an ACL
variable, $acl_m* (the * part is chosen by you), which you set in the RCPT
ACL depending on the recipient. You can add some logic to detect if the
variable is already set (i.e. a message with multiple recipients) and
adjust it accordingly - e.g. choose a default user.
Tony.
--
f.a.n.finch <do...@dotat.at> http://dotat.at/
HEBRIDES: CYCLONIC 6 TO GALE 8, OCCASIONALLY SEVERE GALE 9, PERHAPS STORM 10
LATER. ROUGH INCREASING HIGH. RAIN THEN SQUALLY SHOWERS. MODERATE OR POOR.
Re: per user scanning
Posted by #Ronan McGlue <r....@qub.ac.uk>.
Tony Finch wrote:
> On Tue, 27 Feb 2007, #Ronan McGlue wrote:
>> I am looking to move to peruser scanning, so I would need to change only one
>> line of the above to
>>
>> spam = $local_part:true
>> which will use the local part of the email address as the username.
>
> This won't work because there may be multiple recipients for a single
> message. Therefore Exim doesn't define the per-recipient variables (like
> $local_part) in situations when you are dealing with the whole message,
> including the DATA ACL.
>
> The first thing you must do is decide what policy you want for messages
> with multiple recipients, then hack around to implement it. Unfortunately
> there's no easy solution, even for common policies.
>
> Tony.
Tony ,
slightly OT for SA-list, but I've jsut read
http://www.exim.org/exim-html-4.66/doc/html/spec_html/ch41.html#SECTscanspamass
what information is available during the DATA_ACL eg to perform lookups
on to get the username to use for SA?
R
--
Regards
Ronan McGlue
===================
Analyst / Programmer
Queens University Belfast
Re: per user scanning
Posted by Tony Finch <do...@dotat.at>.
On Tue, 27 Feb 2007, #Ronan McGlue wrote:
>
> I am looking to move to peruser scanning, so I would need to change only one
> line of the above to
>
> spam = $local_part:true
> which will use the local part of the email address as the username.
This won't work because there may be multiple recipients for a single
message. Therefore Exim doesn't define the per-recipient variables (like
$local_part) in situations when you are dealing with the whole message,
including the DATA ACL.
The first thing you must do is decide what policy you want for messages
with multiple recipients, then hack around to implement it. Unfortunately
there's no easy solution, even for common policies.
Tony.
--
<fa...@exim.org> <do...@dotat.at> http://dotat.at/ ${sg{\N${sg{\
N\}{([^N]*)(.)(.)(.*)}{\$1\$3\$2\$1\$3\n\$2\$3\$4\$3\n\$3\$2\$4}}\
\N}{([^N]*)(.)(.)(.*)}{\$1\$3\$2\$1\$3\n\$2\$3\$4\$3\n\$3\$2\$4}}