0

I use a Windows server to host Squid and loaded some ACL rules from file to block ads. The file is loaded, but the ACL rules don't work, and I can still access the web page which is located in the file. How can I fix it?

These are my blocking rules:

#Block ads start
acl ads_host dstdom_regex "c:/squid/etc/ad_block_host.txt"
acl ads_ip dst "c:/squid/etc/ad_block_ip.txt"
http_access deny ads_host
http_access deny ads_ip
#Block ads end
Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Hartman
  • 295
  • 4
  • 14

2 Answers2

0

Use URL_REGEX. Only that worked for me in Windows.

ZygD
  • 22,092
  • 39
  • 79
  • 102
aagcnet
  • 28
  • 3
-1

Instead of dstdomain, use url_regex -i and make a file with either hostnames. For example, .facebook.com or simply facebook. One regex per line will work.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
aagcnet
  • 28
  • 3