OT Trying to setup a inbox for autolearning

Tony Enderby tenderby at VHIA.COM.AU
Tue Jul 19 17:01:36 IST 2005


Hi there,

Try attached script to purge your spam mbox.



Can be run from cron daily before your fetchmail / sa-learn scripts run.

Tony.




"Billy A. Pumphrey" <bpumphrey at WOODMACLAW.COM>
Sent by: MailScanner mailing list <MAILSCANNER at JISCMAIL.AC.UK>

07/20/2005 01:51 AM
                               Please respond to
             MailScanner mailing list <MAILSCANNER at JISCMAIL.AC.UK>


To
MAILSCANNER at JISCMAIL.AC.UK
cc
Subject
OT Trying to setup a inbox for autolearning




Hello everyone!

I am continuing to try to setup this:
For my exchange users to be able to put spam in a folder and have the
MailScanner machine learn it in the bayes database.  I have gotten a
distance so far but I am stuck.

Here is what I have so far.  These scripts are ran as the user spam in
the cronjob.

Fetch command to get the exchange messages:
.fetchmailrc file =
Poll servername proto imap user spam pass ***

Script file:
(retrieves exchange spam box email successfully into the spam (linux
user named spam) inbox on the MailScanner machine

Fetchmail --folder Spam -all

(for bayes learning)
Sa-learn --spam -p /etc/MailScanner/spam.assassin.prefs.conf --mbox
/var/spool/mail/spam


So.....The steps of the script should be =
1. Pull mail from exchange and into the user name spam on the linux
machine mailbox = SUCCESSFUL

2. Emptying out the spam inbox after a learning takes place -NOT
SUCCESSFUL- I don't know how

3. Bayes learning, seems to be SUCCESSFUL

So what I cannot figure out is how do I clear the spam in box from the
script?  Pine doesn't seem to have a straight command to do it, and
neither does mail.  

I thought about changing the permissions so that the spam user can
delete the /var/spool/mail/spam/ file, but that doesn't seem like a good
idea.

Does anyone see anything wrong with doing it like I am doing it?  (as
far as the scripts, which are small)

Billy Pumphrey
IT Manager
Wooden & McLaughlin

------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the Wiki (http://wiki.mailscanner.info/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).

Support MailScanner development - buy the book off the website!



    [ Part 2, Application/OCTET-STREAM (Name: "expire_mail.pl")  17KB. ]
    [ Unable to print this part. ]




More information about the MailScanner mailing list