Re: Reputation database

From: Murray S. Kucherawy <msk_at_blackops.org>
Date: Sun, 28 Oct 2012 22:33:04 -0700 (PDT)

On Sun, 28 Oct 2012, Christian R??ner wrote:
> As you can see, there is a TODO block and I am stuck at the moment, what
> to do. If I enable the LUA script, opendkim won't start telling me:
>
> opendkim: /etc/opendkim/opendkim-verify.conf: [string
> "/var/lib/opendkim/stats.lua"]:22: attempt to call field 'stats' (a nil
> value)

Can you attach your stats.lua file?

> And yet I do not understand how opendkim connects to the database. I
> don't understand the architecture. What do I have to put in the
> Reputation* lines? I can not find stuff in the man page, even I am sure
> I built with reputation support.

The reputation stuff is still experimental, so it doesn't appear in the
man page. Rather, it's documented in READMEs until it's live code. There
are examples of the Reputation* lines in reputation/README.

When you go through the steps to set up the statistics part of the system
(see stats/README), you've already got it importing data about your mail
feed into the SQL database via periodic execution of opendkim-importstats.
That's where the database connection occurs; opendkim never connects
directly to SQL to do inserts. That first README gets you to the point of
collecting data about the mail you see, but does nothing about processing
the data; it's simply available for you to generate your own reports.

The second part is to follow the steps in reputation/README, which adds
additional tables and cron steps that compute reputations based on the
data collected above. It also gives you the steps you need to follow to
add the REPUTE service to your web server. With a few additional
configuration items, your opendkim filter can then query your REPUTE
service to get reputation information based on DKIM results.

> Also not sure, if OpenDKIM should come before or after Amavis.

I think that's probably a matter of local policy at your site.

> What about the cron jobs? Are there any examples? I saw something
> concerning opendkim-importstats. But if calling this binary with -p
> <mypassword> it does not come back. I am pretty sure, I am totally wrong
> to understand how things work together :)

The man page for opendkim-importstats tells you it reads from standard
input. You're thus expected to pipe the contents of your statistics file
to it. I do it with a short shell script here.

-MSK
Received on Mon Oct 29 2012 - 05:33:21 PST

This archive was generated by hypermail 2.3.0 : Mon Oct 29 2012 - 23:20:44 PST