customizing spamassassin

From: Will Trillich (will_at_serensoft.com)
Date: 04/14/04

  • Next message: Michael Bellears: "RE: Dynamically increase/reduce hardware raid partition?"
    Date: Wed, 14 Apr 2004 00:30:18 -0500
    To: debian-user@lists.debian.org
    
    

    okay, we've got spamassassin running, and Mail::SpamAssassin
    perl paraphernalia is available as well.

    since spamassassin seems to be an instance of Mail::SpamAssassin
    that's invoked to scan email as it arrives, what's the procedure
    for customizing the spam-recognition routines? not sure what to
    google for in this instance -- we get hits on spamassassin's
    features and the manpages for Mail::SpamAssassin, but not how to
    customize the filters themselves.

    we'd like to create our own tests (which look to belong in the
    EvalTests arena) such as

            # ratio of non-alpha to alpha in the subject: field
            sub alpha_ratio_subject
                    {
                    my $self = shift;
                    my $subj = $self->get('Subject');
                    $subj =~ s/\s+//;
                    my @alpha = ($subj =~ s/(\w)//g);
                    my $alpha = scalar @alpha;
                    my $punc = length($subj);
                    return 0
                            unless $punc;
                    return $punc / $alpha
                            if $alpha;
                    return 2**31;
                    }

    this test is probably not very international-friendly but being
    in the torso of the american midwest, we don't have that issue.
    :(

    what's the approved approach for this kind of customization?

    -- 
    I use Debian/GNU Linux version 3.0;
    Linux boss 2.4.18-bf2.4 #1 Son Apr 14 09:53:28 CEST 2002 i586 unknown
     
    DEBIAN NEWBIE TIP #43 from Guy Geens <ggeens@iname.com> 
    :
    Wondering how to SELECT YOUR DEFAULT TEXT EDITOR?  You can set
    your prefered editor with:
    	update-alternatives --config editor
    Also it helps to set your EDITOR environment variable:
    	export EDITOR=`which vim`
    Also see http://newbieDoc.sourceForge.net/ ...
    -- 
    To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org 
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
    

  • Next message: Michael Bellears: "RE: Dynamically increase/reduce hardware raid partition?"