Hello,

    Does anyone know of a way to log basic information about messages processed 
by Spamassassin to a database (ideally mysql)?

    The fields i'm interested in logging are:

        ip address of remote smtp server
        score assigned to message by spamassassin
        date and time message was received (processed by spamassassin)

    Optionally I'd also like to be able to log:

        host name of remote smtp server that was sent in HELO/ELHO command
        host name of remote smtp server resolved for remote smtp servers PTR 
DNS record
        email address of sender in smtp envelope
        email address of recipient in smtp envelope
        original message subject

    This would make it easier to create and maintain a black list of remote ip 
addresses that are not allowed to establish a tcp connection to the SMTP server 
and thereby reduce the bandwidth and server resources used to process spam, i.e 
 address that have sent a lot messages receiving a score over a threshold value 
and haven't sent any messages below the threshold during a specified time 
period could be added to hosts.deny or a firewall acl.

Thanks,

J.T.

Reply via email to