LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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-11-2008, 11:34 AM   #1
amitkush
Member
 
Registered: Jun 2003
Location: Roorkee, Uttrakhand, India
Distribution: RedHat, Ubuntu
Posts: 47

Rep: Reputation: 15
configuring squid to block URLs


Hello all!
I have HP Proliant ML350 G5 running RHEL AS4. How can I configure squid to block the contents based on keywords or block URLs to impose restrictions.
Also, can I impose restrictions by declaring ACL using IP address and MAC address together? If yes, then how?
Thanks
Amit

Last edited by amitkush; 09-11-2008 at 11:38 AM.
 
Old 09-11-2008, 12:23 PM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,617

Rep: Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962Reputation: 7962
Quote:
Originally Posted by amitkush View Post
Hello all!
I have HP Proliant ML350 G5 running RHEL AS4. How can I configure squid to block the contents based on keywords or block URLs to impose restrictions.
Also, can I impose restrictions by declaring ACL using IP address and MAC address together? If yes, then how?
Thanks
Amit
I'd suggest reading the squid and squid-guard documentation. For example:

To deploy the web-site blocking mechanism in Squid, add the following entries to your Squid configuration file (in my system, it's called squid.conf and it's located in the /etc/squid directory):

acl bad url_regex "/etc/squid/squid-block.acl" http_access deny bad

The file /etc/squid/squid-block.acl contains web sites or words you want to block. You can name the file whatever you like. If a site has the URL or word listed in squid-block.acl file, it won�t be accesible to your users.
Be aware that if you use keywords to block on (say playboy, or sex), that by blocking sites containing the word 'sex', you will also block sites such as http://www.sussexcounty.com, etc. To resolve this problem, you can put those sites in a special file called squid-noblock.acl:

http://www.sussexcounty.com

The documentation you already have with Squid tells you more in greater detail.
 
Old 09-13-2008, 11:56 AM   #3
amitkush
Member
 
Registered: Jun 2003
Location: Roorkee, Uttrakhand, India
Distribution: RedHat, Ubuntu
Posts: 47

Original Poster
Rep: Reputation: 15
Thanks! I will give it a try.
What about acl using IP address and MAC address combination.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
How to block urls for specific ip in squid addipolli Linux - Security 10 11-24-2008 02:04 AM
squid bad urls mrlinux2000 Linux - Security 4 02-27-2008 05:36 AM
Firefox URLs with Squid win32sux Linux - Software 5 03-24-2005 02:03 PM
Squid Limit Urls Roach Linux - Networking 3 12-06-2004 11:59 AM

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

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