PDA

View Full Version : Blocking a range of IP's


jmarin
03-05-2004, 01:07 AM
Hi there,

Does anyone know if its possible to block a range of IP's (say for instance static IP's within a LAN)?

Or sdo I need to type in each separate IP?

Thanks :D

webmoriar
03-05-2004, 04:58 AM
You can use the * to block ranges of IP's

ex. 123.4.*

This would block any IP that started with 123.4.

Hope that helps.

albert
03-05-2004, 11:17 PM
You can use the * to block ranges of IP's

ex. 123.4.*

This would block any IP that started with 123.4.

Hope that helps.


What if your IP address format is this ...

123.12.123.xx or xxx

Would the IP block also work, if I put the asterisk * like so ...

123.12.123.*

Basically, I'm on dialup and the last section of numbers always changes to either a 2-digit or 3-digit number and I am trying to prevent my own visits from showing up in the visitor stats.

I just tried it and it says "invalid IP address" and will not accept the asterisk as part of the IP address to block. It appears that when you have a dialup account, there isn't any way to block your own visits, except to enter the current IP address (showing the changes in the last block of numbers), every time you log on to the internet.

If I'm missing something that might work, I would appreciate the advice.

webmoriar
03-06-2004, 12:16 AM
Weird I am almost certain I had seen another post that you can block ranges like that and I know the asterisk works many other places.

My Projects > Configure Counter > Create Blocking Cookie

Follow the steps there to ensure the cookie is allowed and your visits should be blocked quite nicely.

potjepap
03-12-2004, 12:57 PM
same here. When I use wildcards like * in the IP adresses I want to block it says "123.* invalid IP address". Any suggestions?

03-12-2004, 04:02 PM
You can't use wild card expressions I'm afraid.

DevonGuy
08-19-2006, 11:53 AM
I had some free web space on my very first internet dial-up account. When Firefox launched I set up a page to compare browser stats from 3 free trackers. I introduced StatCounter last year. Later, I noticed one particular Firefox user, with a dynamic IP address, was loading the page a dozen times a day. It's a low traffic site, so the results were becoming skewed. I wanted to exclude the IP address range. Extreme tracker was the only one that offered the option. OneStat provides the option with its paid service, but not with the free tracker. Eventually, I withdrew guest access to both OneStat and StatCounter. That's a great pity, because I'd recommend StatCounter as the No.1 choice. You can view example browser charts here:

http://www.mywebsite.force9.co.uk/

If only StatCounter could do the same as eXTReMe I would reinstate guest access to the StatCounter reports straight away. I don't understand is why IP addresses need to be *blocked*. Wouldn't it be easy to simply omit specified IP ranges from the logs?

webado
08-19-2006, 08:41 PM
The programming is more complex and it requires a lot more than a simple lookup.

When you block a set of discrete IP addresses you look for exact match of character strings, yu don't bother intepreting them.

For a range then you ned to convert the 2 end points into purely numerical equivalents of IP addresses according to convention and store tham that way. Then each Ip address that visits has to be converted to the numercial equivalent and comapared against the 2 end points (and this for each range set provided). It's a lengthy process compared to the speed required for the tracker to add almost no overhead to the page rendering.

This of this mathematical computation being done millions of times for every single hit, for evey single project. I'm afraid it's not possible to implement it easily without making the entire tracker much slower for everybody.

DevonGuy
08-20-2006, 01:57 PM
Thanks for your reply, Christina. Maybe there is something I don't understand about how IP addresses are logged. It's true that eXTReMe tracker is not realtime, but what it says on the configuration page is:
You can exclude up to 5 IP addresses by filling out the numeric address,
e.g. 207.230.127.125

For excluding a group do not use wildcards like * or ? but instead leave that part empty.
So by entering 207.230 I would exlude IP's in the range 207.230.0.0 -- 207.230.255.255. That's all I want to do. Codewise, surely that's just a matter of masking or shifting the IP value by 1 byte, or 2 bytes, and doing a comparison?

Power Phlogger 2.2.5 (http://pphlogger.phpee.com/) is slightly less sophisticated. Entering 207.230.127. would exlude IP's in the range 207.230.127.0 -- 207.230.127.255. There doesn't seem to be a limit on the number of triplets. On another of my sites it's correctly excluding IP addresses belonging to 22 sets of IP triplets. And it logs visitors in realtime. What's different at StatCounter?

marxman
08-20-2006, 04:01 PM
i'm trying to get around an IP block from a bravenet discussion forum, i have tried anoymizer and MMIP but they worked until i got blocked again, i've tried ipconfig/release and renew that also worked for a while. now i seemed to have ran out of tricks till i found this source of information here which i hope qill get me in permanantly.

Any suggestions?

DevonGuy
08-20-2006, 06:21 PM
marxman:
I think maybe you missed the point. The word *blocking* is a red herring. I expect most StatCounter users are like me, and just want visitors from certain IP's to be omitted from the statistics.