Email Filters


Table of Contents


Introduction

Mail filters allow you to selectively process incoming email. A filter defines how messages are to be selected and what is to be done with the selected messages. Messages may be selected based on
  • contents of the Subject, From, or To header lines
  • spam score (likelihood of being spam)
  • size of message

Selected messages may then be

  • discarded (thrown away)
  • rejected (thrown away but with a reply to the sender)
  • saved into a mail folder

Messages not selected by any filter will be delivered to your INBOX as usual.

Note that filters are applied only to messages destined for your INBOX. If you have mail forwarding enabled, filters will not be applied to the forwarded messages.

To set filters on your central email server (UTK-MAIL) email account, go to OIT Account Management and select "Manage Your Email Account".


Selecting messages by header line content

To select messages by header line content, specify the header line to be tested (Subject, From, or To) and one or more phrases to be matched against it.

A phrase is simply a string of characters, usually one or more words. Each phrase is compared to the header line and if that exact string occurs anywhere within the header line the message will be selected. Upper and lower case don't matter.

For example, the phrase 'earn' will match any of the following lines:

Your chance to earn big bucks!
How To Increase Your Earning Power
LEARN HOW TO GET RICH
while the phrase 'mortgage info' will match
Mortgage Information
but not
Mortgage Rate Information

Wildcards. You may also use an asterisk as a wildcard character, but note that a wildcard phrase must match the entire contents of the header line (i.e. you must place wildcard characters so as to match everything in the line including any leading and trailing text you need to match). For example, the wildcard phrase

*mortgage*info*

will match the following line (wildcard matches are underlined):

Super Mortgage Rates: Free Information.
while the phrase *.com will match any of these:
smith@hotmail.com
deals@computers.com

But note that if you had specified the above wildcard as *.com* (with a trailing asterisk) it would also have matched:

listserv@using.computers.org

which is probably not what you want.

Examples. Here are some examples of header line filtering.

HeaderPhraseSelects
Subjectearn moneymessages with 'earn money' somewhere in the subject line
Subjectadult site
webcam
porn
messages with any of these three phrases somewhere in the subject line
Fromsmith@hotmail.commessages sent by smith@hotmail.com
From*@hotmail.commessages sent from the hotmail.com domain
From*.commessages sent from any .com domain

Note. Enter the phrases one per line; don't enter them separated by commas. Don't leave a trailing space at the end of a phrase unless you intend it to be there. Short one-word phrases may match more than you think. Remember that upper and lower case don't matter.


Selecting messages by spam score

To select messages by spam score (likelihood of being spam), specify a spam score threshold (a number). Messages with spam scores that exceed this threshold will be selected.

Spam score. Messages destined for your INBOX are scanned by spam detection software and assigned a number (the spam score) representing roughly how many spam-like characteristics the message contains. This score is then recorded in a special header line that may be used to filter the message.

Messages with higher spam scores are more likely to be spam. Those with lower scores are less likely (i.e. more of them may be "innocent").

Spam score threshold. Choosing the level at which to filter messages is a tradeoff between catching more spam versus erroneously catching "innocent" messages.

  • We suggest you start out with a threshold of 8 and then adjust it based on your experience.

  • Adjusting the number downward will filter out more spam (but also more innocent messages).

  • Adjusting the number upward will filter out less spam (but also fewer innocent messages).

Note. The spam score assigned to a message is only an educated guess. It is inherently impossible to identify spam with certainty.


Selecting messages by size

To select messages by size, specify a maximum message size. Any message larger than this will be selected.


What to do with selected messages

Once you have defined how to select messages, you must specify what to do with them. You may choose one of the following actions.

Discard. Throw the message away.

Reject. Throw the message away but send a short reply back to the sender. Note: Please do not attempt to retaliate against spam by sending back a reply. This does not work. Spam senders typically refuse to accept replies and the messages simply accumulate in our outgoing mail queues as undeliverable.

Save to folder. Save the message into a folder on your email account. The folder will be created if it does not exist. Note that two special folder names are available:

auto-delete-1-week
auto-delete-4-weeks

Messages saved into folders with these names will be automatically deleted when they reach the indicated age.

Accept. Save the message in your INBOX. See below for more information.


Advanced techniques

Filter order. If you have more than one filter, the filters will be applied in the order you have specified. You can achieve special effects by careful placement of filters. You can change the order of filters using the "Up" and "Down" buttons.

Continuation. Certain filter types allow you to specify that processing of subsequent filters is to continue even after a message has been selected and processed by the current filter. In this case a given message might be selected and processed by more than one filter.

Accepting messages. Accepting filtered messages (i.e. saving them into your INBOX) might seem redundant since any message not selected by a filter will go into your INBOX anyway, but by placing an "Accept" filter ahead of other filters you can achieve "exception" effects. Here is an example:

Filter1: Accept messages from *@aol.com
Filter2: Discard messages from *.com

The effect of this is to discard messages from all .com domains except aol.com. Or consider this:

Filter1: Accept messages from mary-jones@yahoo.com
Filter2: Discard messages with spam scores greater than 8

Since you accept all messages from mary-jones@yahoo.com before you filter out spam, you are guaranteed to receive her email even if it gets a high spam score for some reason and would otherwise be discarded.


Back to Top