Linux Forums - Linux Help,Advice & support community:LinuxSolved.com

Network Troublshooting => Linux Proxy Server Support => Topic started by: Avin on October 23, 2008, 06:59:45 AM

Title: About Gmail Blocking through Squid
Post by: Avin on October 23, 2008, 06:59:45 AM
Hello All

        Can any one tell me How to block gmail.com totally.I have added following acl rules for block gmail in my squid.conf

      acl  gmailblock  url_regex -i www.gmail.com
      acl  gmailblock  url_regex -i mail.google,com/mail
      acl  gmailblock  url_regex -i http://mail.google.com/mail
      acl  gmailblock  url_regex -i gmail

     http_access deny gmailblock

     Problem is that User is blocked to access gmail.com but if they pass https instead of http the traffic is allow. and my rules is not filter the https traffic so What should I do ?  How to block https traffic and How to write acl  for https blocking........ please help..

Avin
Title: Re: About Gmail Blocking through Squid
Post by: aktiwari4u on October 25, 2008, 04:26:46 AM
i think if you will block gmail.com domain that will solve your problem
Title: Re: About Gmail Blocking through Squid
Post by: Ricky on October 27, 2008, 10:44:45 AM
Hi, squid do allow https proxy but through tunneling which means it can't block sites those are on https.
You can block https sites using iptables on the machine where squid is installed.

try :
Code: [Select]
iptables -A INPUT -s gmail.com -j DROP
iptables -A OUTPUT -d gmail.com -j DROP

Above will drop all incoming and output connection to gmail.