4

I understand it is possible to block a country from viewing my website using apache, .htaccess.

I was wondering if it is possible to block everyone from a specific City (namely the city of Flower Mound, in Texas) from accessing my website. If that's a no-go, how about blocking all of Texas?

Edit - the reason why. There is a competitor company that is based in Flower Mound. I want them to think my website is down/offline. cough dirty..i know

2nd Edit - I do this because they tend to steal my work, change it in some way, and then call it their own. They are quite adept in doing this, and I can't call upon the law for help.

Greatestswordsman
  • 387
  • 1
  • 5
  • 17
  • 3
    I'd love to know why! – Rich Dec 10 '10 at 13:04
  • 1
    +1 for why. this sounds like a great story. – Sirex Dec 10 '10 at 13:05
  • What has Flower Mound done to you ? – user9517 Dec 10 '10 at 13:05
  • 1
    But think of the children! – GregD Dec 10 '10 at 13:05
  • Edited with the Why... – Greatestswordsman Dec 10 '10 at 13:10
  • Is this kind of thing in your roles and responsibilities or have you been specifically asked to do this my management - the reason I ask is that if you're doing it yourself then your management might actually NOT want you to do it. – Chopper3 Dec 10 '10 at 13:27
  • Virendar - Your question, at least for me, is now entering the dubious side what with making your website appear down to your competitors and entering their establishment with a wireless laptop in order to determine what their IP address range could be. You may be on the wrong site to get much help with these types of tactics. – GregD Dec 10 '10 at 13:29
  • 3
    On a personal note, if I knew what your company was in the business of doing, knowing what you've asked here, I would not purchase a damn thing from you. – GregD Dec 10 '10 at 13:30
  • Ah well I'm sorry for sounding suspicious haha, I updated my original post with some more insight – Greatestswordsman Dec 10 '10 at 13:42
  • Law enforcement might not be good for chasing derivative works problems; but lawyers sure are. If you've got a good case, some will work the case "free" in exchange for a large portion of any winnings too. – Chris S Dec 10 '10 at 13:57

1 Answers1

2

It's technically not possible to block 100% of all users in $CITY/$STATE/$COUNTRY . Reasons:

  • Proxy servers
  • Satellite connections
  • Inaccurate/too-infrequently updated geolocation databases

How about finding out which ISP your competitor uses and then block an IP-range of that ISP used in the city?

If you want to try blocking the city nonetheless, take a look at mod_security +GeoIP (assuming you're using Apache).

Funny question/idea btw ;-)

weeheavy
  • 4,039
  • 1
  • 27
  • 41
  • Any tip on how I can find out what ISP they use? I personally live in Canada, but I can get someone from Flower Mound to enter their company headquarters with a wireless laptop, if that helps any... – Greatestswordsman Dec 10 '10 at 13:20
  • Well I don't want to support illegal actions, but here are some keywords: WHOIS lookup, netcraft, DNS queries (dig, nslookup) etc. – weeheavy Dec 10 '10 at 13:25
  • 1
    ... or just email them and start by the mail headers of the reply. – Sirex Dec 10 '10 at 15:40