LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-30-2006, 12:44 AM   #1
sapheroth
LQ Newbie
 
Registered: Jun 2004
Posts: 28

Rep: Reputation: 15
Restrict users to browse in Squid.


i wanted to restrict a specific proxy to restrict users to browse the internet for specific time...
i entered the following code in the access list

(i entered this followind code at the bottom of acl section)
acl FOO src 10.11.3.30/255.255.255.0
acl WORKING time MTWFHA 08:00-14:00

(and entered this code at the top of http_access portion)
http_access deny FOO WORKING
http_access deny FOO

where 10.11.0.30 is the proxy server.

when i restart the squid, i didnt get any error msg that means that the work is ok...
but the useres are still able to browse the internet....

plz tell me what the problem with this code.

regards.
 
Old 09-30-2006, 02:42 AM   #2
amitsharma_26
Member
 
Registered: Sep 2005
Location: New delhi
Distribution: RHEL 3.0/4.0
Posts: 777

Rep: Reputation: 31
Quote:
Originally Posted by sapheroth
(i entered this followind code at the bottom of acl section)
acl FOO src 10.11.3.30/255.255.255.0
acl WORKING time MTWFHA 08:00-14:00

(and entered this code at the top of http_access portion)
http_access deny FOO WORKING
http_access deny FOO

where 10.11.0.30 is the proxy server.
I dont see many things wrong in that.. but i suggest if you are blocking one single host, then you should have 255.255.255.255 as a subnet mask up there. Try modifying with that.
 
Old 09-30-2006, 03:42 AM   #3
bonowax
Member
 
Registered: Jul 2006
Location: Suburbs of Lisbon, Portugal
Distribution: Slackware, FreeBSD
Posts: 75

Rep: Reputation: 16
Hi;

According to that portion of your config file, your proxy server and the hosts you want to block access to the internet, reside on different subnets... Is that so or was it a typo?...
As an example I usually do it this way:

....
....
acl FOO src 10.11.3.0/255.255.255.0 # Defines a trusted subnet
acl WORKING time MTWFHA 08:00-14:00 # Defines a time window to allow/deny access
....
....
....
http_access allow FOO !WORKING # Allows FOO to access but not during WORKING
http_access deny all

Hope this helps...

Cheers
 
  


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
restrict internet bandwidth using squid coolamit78 Linux - Networking 2 08-15-2009 12:50 AM
how to restrict downloading in squid capricorn80 Linux - Networking 1 09-12-2006 06:24 AM
Squid- restrict access to url jocast Linux - Software 0 03-10-2006 01:59 PM
restrict access using squid, iptables? jgnasser Linux - Networking 3 04-13-2005 07:21 AM
How can I restrict users from accessing particular webistes using squid. lyn Linux - Networking 0 02-24-2004 04:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:07 AM.

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