Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Squid and I want to know how to make a specific IP range of allowed connections, I use this

acl permittedips src

http_access allow permittedips

But I want to make an range that allows from 70.*.*.* to 90.*.*.*. How can I do this the easiest way?

share|improve this question
up vote 4 down vote accepted

You can use CIDR notation to signify this in the ACL for squid. You would want:

acl permittedips src
acl permittedips src

More information on CIDR:

share|improve this answer
This doesn't seem to work? My IP is 86.132.x.x and I can't connect to squid, it works if I put my oringinal IP address, but I want to specify the range BETWEEN 70.*.*.* to 90.*.*.*. – MacMac Aug 26 '11 at 18:11
Oh, I missed the 'to' part. You really can't do that easily with CIDR, you'd be best off adding 20 rows one for 70, 71, 72...89, 90. – polynomial Aug 26 '11 at 20:32
Hmm, didn't work. When I restart squid, it tells me start: Job failed to start. On service squid start. – MacMac Aug 26 '11 at 20:50
You probably need to give different names to each block, like permittedips70, permittedips71 – polynomial Aug 26 '11 at 21:19
@polynomial No, it is possible to use same acl name for multiple lines. He should look into squid cache.log for errors. – AlexD Aug 29 '11 at 5:51

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.