Membership is FREE, giving all registered users unlimited access to every Acorn Domains feature, resource, and tool! Optional membership upgrades unlock exclusive benefits like profile signatures with links, banner placements, appearances in the weekly newsletter, and much more - customized to your membership level!

Blocking IP range help with .htaccess

Status
Not open for further replies.
Joined
May 18, 2006
Posts
5,943
Reaction score
103
Hi all,

Can anyone kindly assist me with creating an .htaccess file to block an IP range which is spamming several sites on my server?

I'm getting spam from an originating T-Mobile IP range of 178.100.0.0 - 178.103.255.255. T-Mobile won't do anything about it and never reply. :rolleyes:

So, rather than use the WHM to blanket ban T-Mobile users with a wildcard on the entire server, I'd like to individually upload an .htaccess file to block several sites only.

How do I block the entire range as above?

e.g. Would this work?

Code:
order allow,deny
deny from 178.*.*.*.*
allow from all

Help gratefully received, thanks! :D
 
This should work:

order allow,deny
deny from 178.
allow from all

You can also block specific ISPs
 
If you really want to block the whole 178 range then the following would do it:

Code:
deny from 178.

edit:
I was picked at the post before refreshing the page.
 
Haha, great minds think alike.

Btw I don't think you are allowed affiliate links in your sig here.
 
Thanks guys, much appreciated. :)

I've uploaded my individually needed .htaccess files and will see what happens. :cool:
 
Status
Not open for further replies.

The Rule #1

Do not insult any other member. Be polite and do business. Thank you!

Members online

Premium Members

New Threads

Domain Forum Friends

Our Mods' Businesses

*the exceptional businesses of our esteemed moderators
General chit-chat
Help Users
  • No one is chatting at the moment.
      There are no messages in the current room.
      Top Bottom