PDA

View Full Version : Rejecting mail from foreign domains


pmennen
February 18th, 2006, 07:42 PM
I subscribe to 1-2 Wonder primarily for the email forwarding service which has been working perfectly (maybe even too well :). I forward - to their respective ISPs - my mail and the mail for about a dozen family members who also use my domain. We all then pick up our mail using OE or Thunderbird.

I usually use a throw away email address when responding to newsgroup postings, but a few weeks ago I made the silly mistake of using my real email address on just one message. Since then I have received 22,000 junk email messages. Most get filtered out by my spam filter, but enough get thru that it is becoming a major hassle. Plus sometimes the messages come in so fast that my computer is bogged down just processing all the messages. 80% of these junk messages are coming from Germany and most of the rest from China and several other contries. I thought I could outlast this problem, but several weeks later it is showing no signs of slowing down.

Is there a way to tell the email forwarder to discard messages from non US domains? (I have no frequent email contacts in other contries). I would like to do this for just my own email, although at this point I would discard foriegn messages for my entire domain if that were the only option for solving the problem.

Many thanks in advance to whatever advice you may offer to help me get over this very frustrating time.

~Paul

Brandon
February 18th, 2006, 07:59 PM
Hey-

Quick question before my .02, do you use Spam Assassin as a spam filter?
"Most get filtered out by my spam filter"

Brandon

pmennen
February 19th, 2006, 03:52 AM
> Quick question before my .02, do you use Spam Assassin as a spam filter?

No, I'm just using the default spam filter in my email client (which is Mozilla Thunderbird). So all the junk email is getting sent to my computer, and my email client is trying to take care of it. I guess I need to prevent the junk from even getting forwarded to my isp. Will spam assasin allow me to do that? Will it allow me to filter out foriegn domains, or don't you think that will be necessary?

~Paul

Brandon
February 19th, 2006, 06:32 AM
Yep, that's what Spam Assassin is. SA has a good reputation, please give it a shot, following instructions toward bottom of this thread.
http://forums.12wonder.com/showthread.php?t=170

Check back and update this forum thread in a day or so, we'll take it from there.

Brandon

12Wonder
February 19th, 2006, 02:40 PM
My own .02 here...
I don't know of any way to effectively block mail from specific countries or groups of countries, or to accept mail only from specific countries, at account level with any of the software currently running in cpanel. For obvious reasons we can't do something like this server-wide.

Probably your best bet would be to use a combination of Spam Assassin and Email Filtering.

Enable Spam Assassin (Mail -> Spam Assassin -> enable). Don't enable spam box unless you plan to clear it and/or check it frequently, otherwise your account will fill up with spam that gets diverted to the spam box.

Then go to Mail -> Email Filters -> Add Filter and add a new filter that says Any Spam Assassin Header that Begins with Yes should be Discarded.

That will get rid of the obvious stuff. But remember since all spam-tagged stuff is automatically going to be discarded, you should be sure you don't want to bother checking spam-tagged stuff before doing this.

You can use Spam Assassin to create a blacklist of ip's & domains you don't want to receive mail from. Or you can use the Email Filters to filter out (eg to Discard) emails that contain specific stuff in the headers. For example create an Email Filter to automatically Discard any email with Any Header that contains .cn and another filter to Discard email with Any Header that contains .de

etc. etc.

But remember nothing is going to be 100% and if you decide to filter out entire blocks of IP's you may miss some legitimate mail. Also there are spoofed headers to deal with -- a spoofed header can still get through even though Spam Assassin is pretty good at looking for stuff like that.

But these and the tips in Brandon's other post will give you a place to start.

Anne