Re: [exim] Log Spamassassin Rejects

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Todd Lyons
Date:  
À: Brian Spraker
CC: exim-users
Sujet: Re: [exim] Log Spamassassin Rejects
On Sat, May 19, 2012 at 2:33 PM, Brian Spraker <spraker@???> wrote:
> I've increasingly been rejecting good messages and am trying to find out
> why.  However, when looking at the rejectlog, it mentions why it was
> rejected (spam points) - but it doesn't show me how the e-mail qualified
> with that many points.
>
> Is there a way in Exim to set it so that it will log all of the rules that
> matched the e-mail into the rejectlog - indicating how the message got to
> that point level?


I do it like this. Watch for Gmail client auto-wrapping long lines.

  # Always add X-Spam-Score and X-Spam-Report headers
  # using SA system-wide settings (user "exim")
  # no matter if over threshold or not.
  warn    condition      = ${if >{$message_size}{500K}{no}{yes}}
          !authenticated = *
          spam           = exim:true
          add_header     = X-Spam-Score: $spam_score
          add_header     = X-Spam-Report: $spam_report
          message        = X-Spam-Score: $spam_score\n\
                           X-Spam-Report: $spam_report


  # Add X-Spam-Flag if spam is over system-wide threshold
  warn    condition      = ${if >{$message_size}{500K}{no}{yes}}
          !authenticated = *
          message        = X-Spam-Flag: Yes
          spam           = exim
          add_header     = X-Spam-Flag: Yes


  # Reject spams with score over 6
  deny    condition      = ${if >{$message_size}{500K}{no}{yes}}
          !authenticated = *
          message        = This message scored $spam_score points.  Rejected.
          spam           = exim:true
          condition      = ${if >{$spam_score_int}{60}{1}{0}}



I have a second stanza which is basically the same but is for
authenticated users and it's called by a different local user (has
RBL's disabled, RDNS checks disabled, etc).

...Todd

--
Always code as if the guy who ends up maintaining your code will be a
violent psychopath who knows where you live. -- Martin Golding