On Tue, 2003-08-19 at 04:20, James Hatridge wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hi all...
Ok, I really really want to stop the hot girl ads etc. So I installed Spamassassin. But now what? I don't see anyway of getting the damn thing to start working! I use KDE and Kmail, but no where does the how-to's talk about Kmail. SO, would one of you kind people out there give me a 1,2,3 list of how to get this working?
Thanks
JIM
I just got spamassassin working here on evolution, so I may be able to provide some direction for you. First, how do you receive your mail? Most of the instructions for using spamassassin assume that you are using some combination of sendmail, fetchmail, qmail, postfix, etc. to retreive your mail and that your mail client (KMail) receives the mail from a local directory. If this is true in your case, then the recent archives of the SuSE list will provide a wealth of information about setting up procmail and spamassassin. However, if your Kmail is set up to fetch email directly from your ISP (pop3, etc.) then you have a bit of a problem. Your mail is going directly from the ISP to the mail client and there is no place for spamassassin to interact. I have absolutely no idea about the capabilities of KMail to execute external commands. Using Evolution I have a filter that can pipe the mail to a shell command. The filter I use pipes to "spamc -c". If there is ANY output from this command (spamassassin declaring that the email message is spam) then the message is filtered to a spam directory. If there is no output from this command then the message is filtered normally through evolution. An alternative command would be "spamassassin -e" instead of "spamc -c", but that command would not gain the advantages of the spamd/spamc scripts. This filter is placed after the filters that routinely deal with messages that are not spam, such as mailing lists or other known correspondents. Using spamassassin through the Evolution filter there is no spam modification to the message and therefore no reason or advantage to pass every message through that filter. This set-up does not generate spam headers or modify the incoming mail in any way. It is a very simplistic binary type filter (spam/ham). Spamassassin makes the determination if the message is spam based on the user_prefs file. I have not found a way to grade the spam into "definitely spam" and "possibly spam", or any other subtleties of spamassassion/procmail. But in the 48 hours that this method has been working on 2 computers the results have been phenomenal. I had saved spam from the last 2 months and had 3,100 email messages of spam to use with "sa-learn --spam" plus I activated blacklist filters from www.stearns.org. To activate spamassassin, go to runlevel editor and turn on "spamd" in runlevels 3 and 5. In /home/user mkdir ".spamassassin". Then cp "user_prefs.template" from /usr/share/spamassassin to your new .spamassassin directory. Rename the file to "user_prefs" and modify the preferences to suit (see man spamassassin). As a minimum uncomment the required number of hits. As root restart spamassassin "rcspamd restart". At this point spamassassin will be working. If you have enough saved messages (spamassassin should really have 1000 spam and 1000 spam messages for learning) then run sa-learn. The commands I used are; sa-learn --spam --mbox /home/ralph/evolution/local/Inbox/subfolders/spam/mbox (all on 1 line) sa-learn --ham --mbox /home/ralph/evolution/local/Inbox/subfolders/personal/mbox Hope this helps you get spamassassin set up and running with KMail. Not really a 1, 2, 3 guide on how to set up KMail (more of a 1, 4, 6), but as mentioned I have no idea of the capabilities of KMail in this method. -- Ralph Sanford - If your government does not trust you, rsanford@telusplanet.net - should you trust your government? DH/DSS Key - 0x7A1BEA01