Spamassassin

Discussion in 'Installation/Configuration' started by hagel, Aug 20, 2005.

  1. hagel

    hagel New Member

    Hi, I'm wondering abit about spamassassin, I've used it to rewrite subjects to ***SPAM*** and it works like a charm, but now after having seen that it works as it is supposed to I thought I'd change it to reject SPAM mail instead, but nothing happends when I do so, am I supposed to restart something or what??

    Regards
    Torbjörn
     
  2. falko

    falko Super Moderator ISPConfig Developer

    In the homedir of that user there is a file called .spamassassin.rc (with a dot at the beginning!).

    Can you post that file here?
     
  3. hagel

    hagel New Member

    Code:
    # SpamAssassin sample procmailrc
    #
    # Pipe the mail through spamassassin (replace 'spamassassin' with 'spamc'
    # if you use the spamc/spamd combination)
    # The condition line ensures that only messages smaller than 250 kB
    # (250 * 1024 = 256000 bytes) are processed by SpamAssassin. Most spam
    # isn't bigger than a few k and working with big messages can bring
    # SpamAssassin to its knees.
    :0fw
    * < 256000
    | /home/admispconfig/ispconfig/tools/spamassassin/usr/bin/spamassassin --prefs-file=/var/www/web15/user/web15_th/.user_prefs
    
    # Mails with a score of 15 or higher are almost certainly spam (with 0.05%
    # false positives according to rules/STATISTICS.txt). Let's put them in a
    # different mbox. (This one is optional.)
    #:0:
    #* ^X-Spam-Level: \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
    #/dev/null
    
    # All mail tagged as spam (eg. with a score higher than the set threshold)
    # is moved to "/dev/null".
    :0:
    * ^X-Spam-Status: Yes
    /dev/null
    
    # Work around procmail bug: any output on stderr will cause the "F" in "From"
    # to be dropped.  This will re-add it.
    :0
    * ^^rom[ ]
    {
      LOG="*** Dropped F off From_ header! Fixing up. "
    
      :0 fhw
      | sed -e '1s/^/F/'
    }
    
     
  4. falko

    falko Super Moderator ISPConfig Developer

    Looks correct. All spam should be sent to /dev/null.
     
  5. hagel

    hagel New Member

    Well I agree, but it doesn't... :(

    All spam is still getting through with the subject rewritten
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Have you checked the header of the mails, if it contains the
    Code:
    X-Spam-Status: Yes
    part?
     
  7. hagel

    hagel New Member

    All spam mail headers contain :
    Code:
    X-Spam-Flag: YES
    But no mail is deleted, anyone has any idéa??
     
    Last edited: Aug 24, 2005
  8. tlgwat

    tlgwat New Member

    Try adding this too maybe...

    Code:
    * ^X-Spam-Flag: YES
    /dev/null
     
  9. falko

    falko Super Moderator ISPConfig Developer

    @hagel: Do your mail headers contain
    Code:
    X-Spam-Status: Yes
    or
    Code:
    X-Spam-Flag: YES
    ? That's an important difference! :)
     

Share This Page