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 - 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 09-05-2012, 07:22 AM   #1
shakul hameed
LQ Newbie
 
Registered: Sep 2012
Posts: 8

Rep: Reputation: Disabled
unblock particular ip to access facebook using squid


I Have blocked facebook for all using

acl banned_websites dstdomain -i "/etc/squid/banned_websites"
http_access deny banned_websites

But now i need to give access to this particular Ip Address to acess facebook

acl special_client src 192.168.50.107
acl facebook dstdomain .facebook.com
http_access allow facebook special_client
http_access deny facebook
http_access allow all

After reload its not working. It is still blocked


can any one help me
 
Old 09-05-2012, 10:38 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,

Use
Code:
acl special_client src 192.168.50.107
acl facebook dstdomain .facebook.com
http_access deny facebook !special_client
http_access allow all
Regards
 
1 members found this post helpful.
Old 09-05-2012, 01:42 PM   #3
shakul hameed
LQ Newbie
 
Registered: Sep 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
Thanks


acl NO_RESTRICTION src 192.168.50.107 can i use this...
 
Old 09-06-2012, 02:00 AM   #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
Quote:
Originally Posted by shakul hameed View Post
Thanks


acl NO_RESTRICTION src 192.168.50.107 can i use this...
I don't get your questions. You can name your ACLs whatever you want and just use that name in http_access directive(s). E.g replace "special client" with "NO_RESTRICTION" in the previous post congiguration options.

Regards
 
1 members found this post helpful.
Old 09-06-2012, 07:41 AM   #5
shakul hameed
LQ Newbie
 
Registered: Sep 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
Once Again Thanks

Its worked with following script

acl user src 192.168.50.107
acl facebook dstdomain .facebook.com
http_access allow facebook
 
Old 09-06-2012, 11:48 AM   #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
Quote:
acl user src 192.168.50.107
acl facebook dstdomain .facebook.com
http_access allow facebook
Please note that with that configuration, squid allows anyone to access facebook.com
 
1 members found this post helpful.
Old 09-07-2012, 12:33 AM   #7
shakul hameed
LQ Newbie
 
Registered: Sep 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
I checked its blocked for others expect particular ip address.. Sure i ill check that out again for confirmation.
 
  


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
Renaming/Overwriting File in Squid Folder to Block and Unblock the Sites. abdeali Linux - Server 1 05-25-2012 04:03 AM
Squid facebook upload failing ! Hermanon Linux - Server 1 10-24-2010 08:57 PM
How to unblock Facebook from a Linux Computer? pequita28 Linux - Newbie 2 05-29-2010 11:04 PM
Proxy software to unblock internet access on Linux vasim98 Linux - Software 1 12-30-2009 09:10 AM
Facebook and Squid privacy qwertyjjj Linux - Software 6 12-23-2009 06:29 PM

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

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