LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-11-2010, 09:25 PM   #1
2buck56
Member
 
Registered: Oct 2004
Posts: 54

Rep: Reputation: 15
Squid 3.0 access list problem


I have an old FC2 box running Squid version 2.5. It has been running since 2003 so I am in the process of replacing it. I have a new machine with FC11, iptables, and Squid 3.0 installed.

On the old machine I use iptables to intercept Port 80 traffic and send it to Squid. By default I block all internet access and allow only sites that are in an Allowed_Sites.txt file. Within Squid I also have statements to allow certain users to bypass Squid based on their IP address.

I have set up the same thing on the new box. I have iptables intercepting the Port 80 traffic and sending it to Squid. That is working because if I remove the redirect statement from iptables all internet access is blocked.

The problem I am having is that Squid is not blocking any websites. It acts like the ACL is set to http_access allow all. I have worked on this for several hours and am stumped.

These are my Squid rules:
acl allowed_sites url_regex "/etc/squid/Allowed_Sites.txt"
acl manager proto cache_object
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
acl SSL_ports port 443
acl CONNECT method CONNECT
http_access allow manager localhost
http_access deny manager
http_access allow Bypass_Users
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
acl our_networks src 192.168.1.0/24
http_access allow allowed_sites
http_access allow our_networks
http_access deny all
icp_access deny all
htcp_access deny all
http_port 192.168.1.254:3128 transparent
hierarchy_stoplist cgi-bin ?
access_log /var/log/squid/access.log squid
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
refresh_pattern . 0 20% 4320
visible_hostname FC11.proxybox
icp_port 3130
coredump_dir /var/spool/squid

Any suggestions would be appreciated. I'm seriously thinking about trying to find Squid version 2.5 to replace the 3.0. since 2.5 worked find for the last 7 years.
 
Old 06-12-2010, 03:38 PM   #2
Lexus45
Member
 
Registered: Jan 2010
Distribution: Debian, Centos, Ubuntu, Slackware
Posts: 361
Blog Entries: 3

Rep: Reputation: 48
Hi,
try this (I haven't copied all your config, just keep in mind that you have to specify both ACLs in the rule)
Code:
...
http_access allow Bypass_Users
http_access allow our_networks allowed_sites
http_access deny all
...
Hope, it'll help you. I love Squid
Have fun

Last edited by Lexus45; 06-12-2010 at 03:42 PM.
 
Old 06-14-2010, 04:11 PM   #3
2buck56
Member
 
Registered: Oct 2004
Posts: 54

Original Poster
Rep: Reputation: 15
Lexus45,

I already had those in my http_access section but it didn't work. Apparently Squid 3.0 operates differently because I fixed it this way.

In the http_access section I have this:
http_access allow our_networks
http_access deny all

In the http_reply_access section I have this:
http_reply_access allow allowed_sites
http_reply_access allow Bypass_Users
http_reply_access deny all

That makes sense which is probably why it was changed in Squid 3.0. If you think about it, http_access controls who can access the proxy box. And http_reply_access controls which sites can reply to the proxy box.

In version 2.5 the rules were apparently a little less restrictive.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Squid server internet access problem ashishkhandelwal Linux - Server 3 02-20-2010 08:13 AM
squid access problem methanigai Linux - Server 1 03-26-2009 06:19 PM
internet access problem using squid soumalya Linux - Networking 6 11-30-2006 07:33 AM
win2k Printer Access control list problem zepplin611 General 0 01-29-2004 11:09 PM
Squid Access list and ident with RH7.3 rdesai Linux - General 0 05-06-2003 06:52 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:18 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration