Setup help: UW-imap and default folders (RH 9)

Chris Wilkes cwilkes-bf at ladro.com
Mon Nov 8 04:59:14 CET 2004


On Sun, Nov 07, 2004 at 08:30:26PM -0500, Todd Slater wrote:
> Greetings,
> 
> I've been searching the archives trying to come up with a system using
> bogofilter for system-wide use. I'm using the default imap, which I
> believe is UW, procmail, and SquirrelMail.
>
> I had planned on just tagging mails with the X-Bogosity header and
> having users bounce misclassified mails to special accounts. However, a
> few users' MUA's don't offer a bounce feature.

Yep, and its a real pain to say "forward this email to this special
address" and have them forget it.  Not that I can blame them, I wouldn't
want to go through the steps either.

> My next thought was to set up a series of folders:
> 
> Junk
>  -Junk
>  -Junk-NOT (tagged as spam, but it's not)
>  -Good-NOT (tagged as ham, but it's not)

I've created a similiar structure except using the folder names
  spam
  makespam
  makegood
as its pretty self-explainatory.

> And something similar for Unsure.  Then I'd write a script to retrain
> misclassified mails and mails bogofilter wasn't sure about, assuming
> users were responsible enough to drop mails in the proper place.

This job would be great if it weren't for the customers :)

What I've run into is that people drop stuff that was labeled as spam
into the "makespam" folder -- and so I wrote a check to say "If this
email is scored as a spam, don't try and fix its classification"

> After a couple of hours googling I can't figure out how to set up this
> mail folder structure in /etc/skel, which I'd like so as to create
> everything with new user accounts.

I don't know about your particular mail setup, but I use qmail-ldap
where you tell it to run a script to create a user's directory.  In there
I make the .qmail file and all the necessary directories.

Not being familiar with non-maildir (that's where every email is its own
individual file, and every IMAP folder is a subdirectory off of the
INBOX with a period in front of it, ie '.spam') what I would do is:
  * create a new user
  * as that user create those new IMAP folders
  * see what the directory and file structure is like
  * recreate that under /etc/skel/
I think this would be under the directory "Mail/" but I'm not sure.

> Can anybody offer a hint, or suggest a better solution?

When your cronjob runs over the "junk-not" and "junk-yes" directories to
do the reclassification you're going to have to concern yourself with
file locking and removing of the email.  Perhaps the library (ie
perl's MailBox module) you're going to use takes care of that.

You might also encounter some resistance with the "unsure" directory --
I have enough trouble having people check their spam folders daily
(24 hours after they check it those emails get moved into an oldspam
directory) as its "too much trouble."  I can't imagine asking them to
check another directory.

Chris



More information about the Bogofilter mailing list