LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   user name based access control in squid. (http://www.linuxquestions.org/questions/linux-server-73/user-name-based-access-control-in-squid-827378/)

lasantha 08-20-2010 02:29 AM

user name based access control in squid.
 
Dear all,

I have configured squid proxy on centos 5.5 and some of my squid.conf file has following lines

Code:

auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd


acl office src 192.168.1.0/24
acl ncsa_users proxy_auth REQUIRED

http_access allow ncsa_users office

There are 3 users called "user034, user035 and user050" in the /etc/squid/squid_passwd file need to restricted access to internet except sites www.abc.com form anywhere in the lan. Once they logged in any ip, rule should apply.(that means no ip related acl, only user name related)

How can I configure this in squid. Your help highly appreciated.

archtoad6 10-25-2010 08:20 AM

Did you mean to mark this "[SOLVED]"?

If so kindly post the solution -- it might help someone else w/ the same problem.

lasantha 10-25-2010 01:07 PM

Problem solved as follows....

auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd

acl Controlled_sites dstdomain "/etc/squid/controlled_sites.squid"
#where controlled_sites.squid contain sites that need to allow


acl www_controlled_users proxy_auth "/etc/squid/controlled_users.squid"
#where controlled_users.squid contain user names that need to allow

http_access allow www_controlled_users Controlled_sites
#allowing those users for sites


acl office src 192.168.1.0/24
acl ncsa_users proxy_auth REQUIRED

http_access allow ncsa_users office

archtoad6 10-26-2010 04:16 AM

Thanks for responding w/ the solution.


All times are GMT -5. The time now is 12:27 PM.