Netsonic SUPPORT

Knowledgebase: General Email Issues
Procmailrc to Filter Spammers Sending Direct, Bypassing Antispam
Posted by Bleau S. on 25 April 2008 07:47 PM

Spammers constantly change their tactics to get the most spam through as possible. One common way, is to send email direct to the server that they see your website is hosted on. They can be relatively assured that this is also where your email is hosted. As a result, they can manage to get some spam through. You can thwart this with a procmailrc file installed in your site's /etc/ directory. Just copy the contents of the text below, substituting the "yourdomain" for your real domain name - just be sure if your domain name is .net, .org, etc., that you also change that section in the second to last line of the text, including the slash before the dot "." in your domain.

This will prevent spam that is sent to you direct, bypassing antispam scanning, from getting into your inbox. This will only work if you already subscribe to our antispam service.


# logging only needed for debugging
LOGFILE=/var/log/procmaillog

:0 fhw
* !^X-Spam-Status:
| /usr/bin/formail -a "X-Msg-Caught: Bypassed DNS or Local"

:0
* !^Received: from .*(authenticated|mail-in-01\.netsonic\.net|mail-in-02\.netsonic\.net|mail-in-02x\.netsonic\.net|mail-in-02y\.netsonic\.net)
* !^Return-Path: .*(yourdomain\.com)
/var/log/unfilteredlog

# end of file
(330 vote(s))
This article was helpful
This article was not helpful