Spamassassin Quickstart for whoopis.com Users

by Marion Bates <mbates at whoopis.com>

Intro: This is for users who wish to configure their email accounts on whoopis.com (or on another domain hosted on the whoopis.com server) to flag spam for easy filtering later. This is just a "what to type" recipe, culled from Bill Stearns's excellent and comprehensive Spamassassin Intro, Setup, and Advanced Techniques document. Please at least skim that, before you implement this recipe.

  1. Log in to your account via ssh.
  2. Copy and paste the following block of text into your terminal window:
    mkdir .spamassassin
    cd .spamassassin
    cp -p /usr/share/spamassassin/user_prefs.template user_prefs
    cat <<EOF >>user_prefs 
    rewrite_header Subject ****SPAM****
    report_header 1
    use_terse_report 1
    defang_mime 0
    report_safe 0
    use_bayes 1
    auto_learn 1
    ok_locales en
    EOF
    cd
    mkdir .procmail
    touch .procmail/proclog
    touch .procmailrc
    cat <<EOF >>.procmailrc
    SHELL=/bin/sh
    PATH=/bin:/usr/bin
    PMDIR=$HOME/.procmail
    LOGABSTRACT=all
    MAILDIR=$HOME/mail       #you'd better make sure it exists
    LOGFILE=$PMDIR/proclog   #recommended
    VERBOSE=off
    
    #Spamassassin start
    :0fw: spamassassin.lock
    | /usr/bin/spamc
    #Spamassassin end
    EOF
    
    Hit return once after you paste all that, just to be sure.

  3. If you want your mail to be forwarded to a different email address, type this in as well BUT change "user.name@domain.com" to the email address that you want your mail forwarded to:
    cd
    cat <<EOF >>.procmailrc
    
    # Forwarding section start
    :0
    ! user.name@domain.com
    # Forwarding section end
    EOF
    

  4. If you don't already have a "mail" directory, also type:
    mkdir mail
    
  5. If you have a .forward file, remove or rename it.



References: