[Mimedefang] I'm going crazy

Jason Gurtz jason at jasongurtz.com
Tue Nov 2 18:06:36 EST 2004

On 11/2/2004 17:30, Yang Xiao wrote:

> X-Spam-Score: ****** (6.309)
> X-Spam-Status: No, score=3.1 required=5.0 tests=ALL_TRUSTED,BILLION_DOLLARS,
> 	RCVD_BY_IP autolearn=no version=3.0.1
> X-Spam-Level: ***
> X-Spam-Checker-Version: SpamAssassin 3.0.1 (2004-10-22) on mail.domain.com

I found that I had this happening to me because I had spamd running in
addition to running mimedefang.  Disabling spamd fixed this for me.

Also, all the spamassassin rules and whatnot should go in
/etc/mail/sa-mimedefang.cf instead of that local.cf file.  All my score
alterations, whitelisting, custom rules, and options like enabling flock
locking are in there.

I do my header adding by adding a few `action_change_header()' lines to
/etc/mail/mimedefang-filter like this:

if ($Features{"SpamAssassin"}) {

    # Only scan messages smaller than 100kB.  Larger messages
    # are extremely unlikely to be spam, and SpamAssassin is
    # dreadfully slow on very large messages.
    if (-s "./INPUTMSG" < 100*1024) {

      # Add SA version and score
      my $SAver = $Mail::SpamAssassin::VERSION;
      action_change_header("X-SpamAssassin", "Version: $SAver");

      # Do the SA thing
      my($hits, $req, $names, $report) = spam_assassin_check();

      # Add SpamAssassin Score and mini-Report
                  "X-SpamAssassin", "Version: $SAver Score: " .
                  "$hits Required: $req Tests: $names"

I do this so I can track how well I'm doing compared to most other people
using spamassassin WRT the accuracy of the score it comes up with.  I also
find it easier to muck about with the mimedefang stuff then editing the
spamassassin stuff  :)



More information about the MIMEDefang mailing list