This post was originally inspired by this thread on the Gentoo Support Forums.

It seems that SPAM is forever on the increase. Daily, our inboxes are flooded with offers of riches, pills, or other such junk. Dealing with SPAM can take a long time – time that would be better used on something more productive (like Unreal Tournament 2004…)

There are tools for helping to automate the task. Nearly all mail clients allow you to setup filters to direct messages that match certain patterns to certain mailboxes. With the all the different tricks used by spammers, this can lead to a lot of filters having to be setup! Some clients (such as Mozilla Thunderbird) have built-in anti-spam filtering. Depending on the level of mail that you receive, these might be perfectly adequate for your needs.

Sometimes though, you just need a little bit more power…

SpamAssassin is a powerful program for filtering SPAM from your mailbox. I’ve seen it used a lot on the server-side – filtering messages as they come into a mail server. It can also be used client-side, which is the method we’re going to setup today.

Evolution is the mail client/calendar/task list program from Ximian (now part of Novell). It’s a pretty powerful app, on a par with Outlook in most respects, but with none of the flub. It offers a lot of options for filtering your mail, including one very useful option in particular: “pipe message to shell command”.

Can you guess what we’re gonna do? That’s right. Use Evolution’s filters to pass incoming mail to SpamAssassin, then decide what to do with the message based on its spam score. Ready? Then lets begin.

emerge evolution

Let it churn away…

emerge SpamAssassin

More churning…

When all the compiling is done, add the spamassassin daemon (spamd) to the default run level so it starts at bootup:
rc-update add spamd default

If you haven’t already done so, set up Evolution with your e-mail account(s). Next comes the laborious part – setting up the quarantine area, the training area and the filter.

Create a new folder in Evolution, called Quarantine. This will be where messages marked as spam will be put. Now create a subfolder under Quarantine called SPAM Training. This is where we will manually place SPAM mail that SpamAssassin misses and later use it to train SpamAssassin to catch it next time.

With the folders setup, lets create our filter. Filter options can be accessed under Tools > Filters. Create a new filter called “SPAM” (or similar). The settings for this filter should be:

pipe message to shell command spamc -c returns greater than 0
move to folder "Quarantine" in "Local Folders"

That should be it. Instantly, you’ll find less spam in your inbox as it gets filtered into your quarantine folder instead. You could set it to delete spam instead of quarantining it, but there’s always the chance of false positives, so I like to double-check the quarantine area every couple of days in case there’s something there that I might want to keep.

Inevitably, some spam will get through. To deal with this, we need to train SpamAssassin into a lean, mean, spam-eating machine. Remember the “Spam Training” folder we set up? Now’s when it comes in useful. When SpamAssassin misses a message, manually move it into the training folder. Then, type the following command, changing @@ with the path to your home directory: sa-learn --spam --mbox "<home dir>/evolution/local/Inbox/subfolders/Quarantine/subfolders/SPAM Training". This command tells SpamAssassin to look in the folder and that everything in it should be classed as spam from now on. After a few days/weeks of training, the amount of spam in your inbox should drop to next to zero!

The RIAA is sueing a 12 year old girl, for “massive copyright infringements through file-swapping”. Under legislation, this could mean her paying “damages” of upto $150,000 per song.

Just when you thought they could go now lower, they pull this one… I hope they get seriously nailed to the wall for it. Surely it can’t be long now before they get investigated by the feds, for what they’re doing?

Either that, or people should wake up and Boycott the RIAA.

I’m in mourning. My DVD player decided to blow itself up last night 🙁 . One minute, my girlfriend is watching “Miss Congeniality”, the next minute there’s a few funny noises, some popping, a bang and a burning smell. At first I thought it was the speaker system – I’d thought there was something wrong with them for months now and I was still recieving a picture, but upon noticing the garbage that the players LCD was spewing out and that the burnt smell was coming from the player, I had to conclude that something had blown inside the player unit itself. So it was a case of power off and unplug, before anything caught fire.

It was less than 6 months old.

I suppose it’s possibly a case of “you get what you pay for”. It was a cheapo Bush brand player, bought as bundle with the speakers, for £99 just after Christmas. Still, you would expect it to last more than 5 and three quarter months…

Personally, I blame the crap film for all this trouble 😉

So why am I not tearing down the walls of the Curry’s store that I bought it from? Well, cos quite frankly they suck at customer care. All the major high-street electronics retailers do. I would take the entire system – player + speakers – back to them (fully repackaged, as per their requirements), along with the reciept and warranty slips. I’d then explain several times what happenerd. After a few attempts to explain what happened, I’d either be told that:
a) it’s not eligable to be repaired;
b) it is eligable, but it might cost a fair bit
After that (if they take it), it’ll take a number of weeks – possibly months – to get returned to me. Most likely, it’ll fail again within 5 months.

For a £99 system, the hassle just isn’t worth it, IMO. If the customer care was decent, I might consider it… but I know it’s not. I’ve heard too many horror stories (here’s a now famous example…), and have had a few iffy experiences with high street electronics retailers myself. Instead, I’ll mutter under my breath, grumble a bit, then buy a decent player to replace the dead one. I’ve got my eye on one of these, which I’ve been told are the dogs wotsits.

Ah, modern technology… can’t live with it, can’t live without it…