LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-20-2010, 01:29 AM   #1
lasantha
Member
 
Registered: Oct 2005
Location: Sri Lanka
Distribution: Red Hat, Cent OS
Posts: 38

Rep: Reputation: 16
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.
 
Old 10-25-2010, 07:20 AM   #2
archtoad6
Senior Member
 
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
Blog Entries: 15

Rep: Reputation: 234Reputation: 234Reputation: 234
Did you mean to mark this "[SOLVED]"?

If so kindly post the solution -- it might help someone else w/ the same problem.
 
Old 10-25-2010, 12:07 PM   #3
lasantha
Member
 
Registered: Oct 2005
Location: Sri Lanka
Distribution: Red Hat, Cent OS
Posts: 38

Original Poster
Rep: Reputation: 16
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
 
1 members found this post helpful.
Old 10-26-2010, 03:16 AM   #4
archtoad6
Senior Member
 
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
Blog Entries: 15

Rep: Reputation: 234Reputation: 234Reputation: 234
Thanks for responding w/ the solution.
 
  


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
Access control through squid ridwan77 Linux - Newbie 1 05-29-2010 02:52 AM
LXer: Role-based Access Control in SELinux LXer Syndicated Linux News 0 02-18-2008 09:50 PM
User based Authentication in Squid instead of Terminal based. TSK2000 Linux - Software 1 12-30-2005 02:22 AM
Squid Access Control acompw Linux - Software 2 09-02-2004 07:42 PM
Squid Access Control aaronsols Linux - Networking 1 09-30-2002 05:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:44 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