E-mail Spam Filter
SpamAssasin
All e-mail sent to the Math Department is now filtered by a program called
SpamAssassin.
The way the spam filter works is that each incoming e-mail is
examined by the filter which identifies individual characteristics
common to spam (unsolicited marketing e-mail) and assigns each of
them a point based rating based on how "spammy" that characteristic
is. Once a certain amount of points is reached, action is taken by
the filter.
Our current set-up is that once a message is considered
spam by the filter the subject line is then relabeled "[***SPAM*** hits / allowed]"
A key point to remember is that if you sign-up for any product updates
and/or newsletters from commercial companies, and you wish to receive these
unmarked as spam, you have two options.
Opting Out of SpamAssasin
If you wish to stop having SpamAssassin relabel your e-mail do the following:
- Using your favorite editor (emacs, vi, pico, etc.) open up
.spamassassin/user_prefs
in your home directory
- Find the line that says:
# required_hits 5
- Change it to:
required_hits 100
Do not forget to remove the pound sign at the beginning of the line.
- Save the changes to the file.
Creating a Personal "Whitelist"
To ensure that SpamAssassin does not label e-mails from specific
people that you consider legitimate e-mail as spam do the following:
- Using your favorite editor (emacs, vi, pico, etc.) open up
.spamassassin/user_prefs
in your home directory
- Find the lines that say:
| # Whitelist and blacklist addresses are now file-glob-style patterns, so |
| # "friend@somewhere.com", "*@isp.com", or "*.domain.net" will all work. |
| # whitelist_from someone@somewhere.com |
- Under these lines add a line such as the following for each person you
wish to receive e-mail from unmarked by SpamAssassin:
whitelist_from myfriend@aplace.math.edu
where "mufriend@aplace.math.edu" should be the e-mail address from which you would like
to receive messages without interference from SpamAssasin.
- Save the changes to the file.
Creating a Personal "Blacklist"
To ensure that SpamAssassin does not label e-mails from specific
people that you consider legitimate e-mail as spam do the following:
- Using your favorite editor (emacs, vi, pico, etc.) open up
.spamassassin/user_prefs
in your home directory
- Find the lines that say:
| # Whitelist and blacklist addresses are now file-glob-style patterns, so |
| # "friend@somewhere.com", "*@isp.com", or "*.domain.net" will all work. |
| # whitelist_from someone@somewhere.com |
- Under these lines and any lines filled with people on your whitelist, add a line such as the
following for each e-mail address that you want SpamAssasin to mark as "SPAM":
blacklisst_from spammer@irritating.com
where "spammer@irritating.com" should be a real e-mail address that you want marked
"SPAM".
- Save the changes to the file.
Troubleshooting
If you receive a large number of e-mails from different e-mail
addresses that are similar in nature and contain similar phrases we may be
able to customize SpamAssassin to block these, please forward them to
spam@math.uconn.edu.
Redirecting Tagged Messages To Another Mailbox
Below are instructions on how to have e-mails marked as
spam by the spam filter automatically be sent to a separate mailbox for
you to view at your leisure.
Note that many email readers (KMail, Netscape, Eudora, Thunderbird, etc) allow
you to setup different mailboxes. There are several ways to
distinguish the Spam caught by Spamassassin. One is that there is
the string "[***SPAM***]" in the header. Another is the header:
X-Spam-Flag: YES
There is also a header with SPAM and a string of *'s.
For WEBMAIL, emacs rmail, mail, elm and mutt
- Using your favorite editor (emacs, vi, pico, etc.) edit the file
.procmailrc
in your home directory.
- At or near the bottom you might see the lines:
If you do not see these lines, add them.
- After these lines add the following:
| MAILDIR=$HOME/Mail |
| :0 |
| * ^X-Spam-Flag: YES |
| myspamfile |
This will direct the spam to the file "myspamfile" in your Mail folder, where you can look at it
(or not) as you wish. You can of course change the name to anything else.
- Save the changes to your file.
- Mail marked as spam can be read with the -f Mail/myspamfile flag to your mail program or by
setting the appropriate preferences.
Remark: If you are already using procmail, all you have to do is add the
three-line rule above to your .procmailrc. You can position it where you
like to allow other rules to apply to suspected spam first.
For Netscape Users:
- In the pull-down bar at the top of your Netscape window, go to
"Edit: Message Filters". A new window will open.
- Click "New". Click "Advanced". A new window will open.
- Enter "X-Spam", click "Add", click "OK". The latest new window will close.
- In the pull-down list, select "X-Spam-Flag".
- In the "contains" box, enter "X-Spam-Flag: YES".
- In the "Perform this action" pull-down list, select "move to folder".
- Click "new folder" and create a spam folder. It should then be
selected in the pull-down list of your folders.
- Click OK.
- The next time you check your mail, check to see if any messages were
automatically filtered into your spam folder!
If you use Mozilla, the steps you take are similar to those above except
you will find the Message Filters under the Tools Menu.
Sources
|