LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 03-24-2011, 08:14 AM   #1
kuddush
LQ Newbie
 
Registered: Mar 2011
Posts: 21

Rep: Reputation: 0
website block by using proxy server


Dear,
i am using RHEL 5. i configured proxy server. now i want block one website. can anyone help me how to configure.
regards
kuddush
 
Old 03-24-2011, 08:23 AM   #2
linuxgurusa
Member
 
Registered: Mar 2008
Location: Namibia, Swakopmund
Distribution: Redhat, Fedora, Centos, ClearOS, Mandrake
Posts: 151

Rep: Reputation: 29
Quote:
Originally Posted by kuddush View Post
Dear,
i am using RHEL 5. i configured proxy server. now i want block one website. can anyone help me how to configure.
regards
kuddush
These lines is what you need
-----------------------------
acl blockfiles urlpath_regex "/etc/squid/badcontent.acl"
acl blocksites dstdomain "/etc/squid/badsites.acl"

acl mynetwork src 192.168.10.0/24

http_access deny mynetwork blockfiles
http_access deny mynetwork blocksites

---------------------------------------

Contents of /etc/squid/badcontent.acl file

\.[Aa][Vv][Ii]$
\.[Mm][Pp][Gg]$
\.[Mm][Pp][Ee][Gg]$
\.[Mm][Pp]3$

Contents of /etc/squid/badsites.acl file

.facebook.com
.microsoft.com
.cnn.com
.youtube.com
 
Old 03-24-2011, 11:05 PM   #3
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
And please do search LQ before posting your question(s).

This one has been asked and answered here a gazillion times.
 
  


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
how do i get squid proxy server to block websites using webmin baronobeefdip Linux - Software 3 07-19-2010 10:35 AM
Restriction of website through squid proxy server problem 124vikas.dange@gmail.com Linux - Server 1 09-25-2009 11:47 AM
I want to block the google talk from my squid proxy server ver 2. ameyswi2 Linux - Newbie 3 07-25-2009 02:19 PM
set up proxy server on hosted website secretlydead Linux - Server 1 09-06-2008 04:06 AM
block internal user to access external proxy server ckamheng Linux - Security 7 09-09-2005 03:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

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