Re: [SQU] ACL & Netmasks

From: Henrik Nordstrom <[email protected]>
Date: Mon, 25 Sep 2000 22:02:57 +0200

Freaked Personality wrote:

> Ok what I wanna do is really simple, I want to allow the range
> 192.168.0.150 to 192.168.0.200 to use the proxy. So I used this
> acl localnet src 192.168.0.150/255.255.255.205

Odd netmask. This will match

132, 134, 148, 150, 164, 166, 180, 182

Why don't you use a range?

192.168.0.150-192.168.0.200/32

The above range cannot be specified as a netmask as it is not a even
power of two subnet.

> as i figure the addr1-addr2 gives a range... but why on earth
> would i wanna use a netmask then???

If you want to specify a range of networks.

192.168.0.0-192.168.43.0/24
(192.168.0.0-192.168.43.255/32)

or

192.168.0.16-192.168.0.48/28
(192.168.0.16-192.168.0.63/32)

> Anyways if anyone could help out I'd really appreciate it.
> If necessary we can switch to a 64 range which gives the possibility of
> using a bit netmask of let's say 6 bits so that would be 32-6=26bits which
> gives
> acl localnet src 192.168.0.150/26 which should allow addresses
> 192.168.0.150 through 192.168.0.213 to pass through the proxy. right?

Right, but why bother when you have ranges?

--
Henrik Nordstrom
Squid Hacker
--
To unsubscribe, see http://www.squid-cache.org/mailing-lists.html
Received on Mon Sep 25 2000 - 14:10:33 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:55:28 MST