In addition to the spam detection tools and methodologies already discussed, there are a few more worth mentioning. These techniques can be used in conjunction with SpamAssassin or can be implemented on their own.
Greylisting is a technique used at the MTA level to delay incoming email, particularly from senders that have never sent email to the domain before. When accepting email from an unknown source, the MTA issues an SMTP code 451 to the sending MTA, which tells the MTA to try again later. Spammers generally use trojanned software that rarely tries resending an email once it is rejected, while a genuine MTA would always attempt a retry. So, a lot of spam can be blocked using the greylisting technique.
Over time, spammers will probably develop better software that will try to resend the email. However, the second reason for greylisting is that in the intervening period between the initial rejection of the email and the subsequent retry, the relay may be listed...