Blocking open relay spam or exploit sites is done at the mail server level.
We use a couple of live DNS black holes that when presented with a
unwanted site, the correct IP address is not returned, but a local non-routable address is; by which the eMail server
knows not to accept mail.
We check your incoming eMail by
scanning for various words, phrases and different types of mail headers, then assign a 'weight' according to the number/type of things found. Please see SpamAssassin for more information. The email's subject is then modified according to the 'weight' of the stuff that is found. You can then determine what to do with it after that. If you are a windoz user, you can setup filters in Outlook Express to move spam to the trash bin when it reaches a certain weight level. In concert are a couple of other ways that we fight spam; graylisting, blacklists, exploits, and open relays. We use SpamHaus to detect and delete email from known spammers, the Exploits database which tracks IP addresses of illegal 3rd party exploits, including open proxies (HTTP, socks, AnalogX, wingate, etc), worms/viruses with built-in spam engines, and other types of Trojan-horse exploits. and the open relay database for...duh open relays.