Some estimates propose that over 90% of all e-mail is unsolicited advertisements (spam)! Regardless of whether these estimates are correct or not, there's no denying that spam is a huge problem. Unwanted messages cause extra load on mail servers, consume storage space, and can even be a security risk. Also, while there have been many attempts to legally manage spam, such attempts have largely failed.
This recipe teaches you how to set up SpamAssassin to identify spam messages. SpamAssassin filters incoming messages by checking for various spam hallmarks, such as missing headers and invalid return addresses, and uses heuristics to analyze the message content. Each check contributes to the message's overall spam score, and if this score exceeds the defined threshold then the message is labeled spam.