Get a Free iPhone 4 from Xpango - click here

Monday, November 22, 2010

How to block websites using Squid

This is very simple way to block a Single Web site, or multiple website in Squid Proxy Server.Just Write the under mentioned Script in squid.cof file
To Block single website:
acl <network name>  url_regex -i <website name>
http_access deny <network name>
example:
acl block_website url_regx -i www.yahoo.com.
http_access deny block_website.
To Block multiple websites:
acl <filename with websites to block> url_regex -i "/etc/squid/<filename with websites to block>"
http_access deny <filename with websites to block>

example:
Create a file named "Blockwebsite" in /etc/squid directory.
Write names of websites you wanna block in this file.
www.hotmail.com
www.yahoo.com
www.gmail.com


Edit squid.conf as:
acl  Blockwebsite url_regx -i "/etc/squid/Blockwebsite"
http_access deny Blockwebsite.


Below is the link for installation of squid.
Proxy Server With Squid.

1 comment:

  1. I really appreciate this blog and I will sure promote this blog to others in my circle. Mp3lemon UK proxy

    ReplyDelete