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 11-07-2011, 04:56 AM   #1
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Rep: Reputation: 1
Red face Bypass_squid_authentication for specific ip


hi every one, i installed squid on rhel6 working perfect with all restcricted sites authentication, the problem is one of my Director asked me that he hates the authentication process, so please remove and allow internet directly. Can any one of you help me how to by pass authentication only for that particular IP address

Thank you in advance.
 
Old 11-07-2011, 05:27 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

You should create an additional acl for your Director's IP:
Code:
acl director src x.x.x.x
(where x.x.x.x is the IP in question) and add a http_access allow before the one used for authenticating users, e.g.
Code:
acl authenticated proxy_auth REQUIRED
...
http_access allow director
http_access allow authenticated
http_access deny all
...
Regards
 
Old 11-08-2011, 12:53 PM   #3
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Original Poster
Rep: Reputation: 1
bathory, thank you very much for your reply, im sorry to inform you that i did the same as you written, but its still asking the password. Please tel me if you know any other method. My requirement is proxy shouldn't ask authentication for that ip, when my director from that IP type www.google.com and hit enter it directly show google web page without asking username and password, but for other systems and other users it should ask for authentication.

thank you very much.
 
0 members found this post helpful.
Old 11-08-2011, 02:58 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
I guess you're reloading squid after making changes in squid.conf.
Could you post squid.conf? Also check the squid access.log to make sure that your director is actually uses that IP
 
Old 11-09-2011, 12:14 PM   #5
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Original Poster
Rep: Reputation: 1
hi bathory

As i cant post the squid.conf and log from my server, i'm posting my own testing servers conf. Please check it


#########
auth_param basic program /usr/lib64/squid/ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm GIL proxy server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive off
http_port 8000
acl valid_users proxy_auth REQUIRED
acl subbu proxy_auth subbu
acl director src 192.168.85.55
acl authenticated proxy_auth REQUIRED
http_access deny !valid_users
http_access allow director
http_access allow authenticated
http_access allow all
http_access deny all
######
 
0 members found this post helpful.
Old 11-09-2011, 01:06 PM   #6
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

What is the subbu acl for user subbu. If it's for your director, you don't need that.
Anyway, you can put the "http_access allow director" before any other "http_access ..." directive, so that it's first evaluated and so your director is allowed access without providing username/password:
Code:
<snip>
http_access allow director
http_access deny !valid_users      <-- this is useless
http_access allow authenticated
http_access allow all                      <-- this is useless
http_access deny all
 
1 members found this post helpful.
Old 11-10-2011, 05:43 AM   #7
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Original Poster
Rep: Reputation: 1
Thumbs up

hi, bathory you are really awesome. Thank you very much, Funny thing is i been using exactly the same acl, directives for a long time. but as you said "httP_acceess allow director" should be used only before any "http_access" directive. i always used to keep "http_access allow director" after few "http_access....." directives. Now it's working two birds for one shot... didn't get it, i used the same trick to alway_direct.

Hilight is the reall stuff educated me rather than giving blind instuctions.

thank you very much can i ask you help. Can you send me request for me on facebook. my id SUBBARAOGANESHNA

Last edited by Gil@LQ; 11-10-2011 at 05:48 AM.
 
Old 11-10-2011, 05:55 AM   #8
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Glad to see it worked. You may mark the thread SOLVED
Quote:
Can you send me request for me on facebook. my id SUBBARAOGANESHNA
Sorry but I don't use facebook.

Cheers
 
Old 11-10-2011, 07:19 AM   #9
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Original Poster
Rep: Reputation: 1
ha ha you are kidding i don't annoy you, at least give me your mail id. I just want to get in touch, i post my only on LQ not on your personal mail.

thank you.
 
Old 11-10-2011, 07:30 AM   #10
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
You can use LQ to send me an email, if you want

Regards
 
Old 11-10-2011, 09:56 AM   #11
Gil@LQ
Member
 
Registered: Apr 2010
Location: India /Hyderabad
Distribution: RedHat, CentOS
Posts: 273

Original Poster
Rep: Reputation: 1
ha ha understood, k thank you very much. have a nice time.
 
  


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
troubleshooting: connection blocked, but only for 1 specific client and 1 specific NIC arri Linux - Networking 3 10-18-2011 11:31 AM
Way to make autofs mount to specific USB flash drive to specific folder? utahnix Linux - Software 2 11-24-2010 05:27 PM
IsThere a fridge, that we can program at specific date/time to unfreeze specific food frenchn00b General 3 07-21-2009 11:26 PM
How to force specific domain or user specific emails to proces in sendmail 8.13.5 FC5 peanutsa Linux - Newbie 1 03-22-2009 05:33 AM

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

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