From d846f000424522bc2e26d554ada61d0ae7e10ecc Mon Sep 17 00:00:00 2001 From: aapostoliuk Date: Tue, 6 Dec 2022 13:57:42 +0200 Subject: T4862: Added the generation config for webproxy domain-block Added the generation in the config file /etc/squid/squid.conf for command: set service webroxy domain-block --- data/templates/squid/squid.conf.j2 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'data') diff --git a/data/templates/squid/squid.conf.j2 b/data/templates/squid/squid.conf.j2 index 5781c883f..b953c8b18 100644 --- a/data/templates/squid/squid.conf.j2 +++ b/data/templates/squid/squid.conf.j2 @@ -24,7 +24,12 @@ acl Safe_ports port {{ port }} {% endfor %} {% endif %} acl CONNECT method CONNECT - +{% if domain_block is vyos_defined %} +{% for domain in domain_block %} +acl BLOCKDOMAIN dstdomain {{ domain }} +{% endfor %} +http_access deny BLOCKDOMAIN +{% endif %} {% if authentication is vyos_defined %} {% if authentication.children is vyos_defined %} auth_param basic children {{ authentication.children }} -- cgit v1.2.3