referrer spam

I’ve been getting hit by referer spam for a couple of months. At first I noticed in my site stats that I’m being linked to by a lot of those stupid poker, pay-day loan uri’s. So much so that I have no idea about the genuine people who come to the website.

I added these to MT-Blacklist, knowing that isn’t the source of the problem. I didn’t even know what it is. Gradually I figured it out and there’s even a name for it.

Lots of articles on how to combat referer spam, mostly passive. But that’s the best we can do now. Someone’s written a perl script to get rid of bad referers in the log file but I haven’t figured out how to run perl scripts yet.

So I’ve done as much as I know how to.

  1. Password protect the stats log file. Easily done in the control panel. Username is admin, password the usual bxxxxxx.
  2. Block the offending root domains using .htaccess. I got the fomat and a list of banned referers from Tom Raferty, it’s uncanny how I’ve encountered most of the offenders in his list.
  3. I have to check site stats regularly and update the htaccess file. Small steps though.