diff options
Diffstat (limited to 'config/squid/squid.inc')
-rw-r--r-- | config/squid/squid.inc | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/config/squid/squid.inc b/config/squid/squid.inc index 7a31f750..3848b818 100644 --- a/config/squid/squid.inc +++ b/config/squid/squid.inc @@ -266,7 +266,7 @@ function squid_deinstall_command() { mwexec("ps awux | grep \"dnsserver\" | grep -v \"grep\" | awk '{ print $2 }' | xargs kill"); mwexec("ps awux | grep \"unlinkd\" | grep -v \"grep\" | awk '{ print $2 }' | xargs kill"); update_status("Reloading filter..."); - filter_configure_sync(); + filter_configure(); } function squid_before_form_general($pkg) { @@ -324,17 +324,6 @@ function squid_validate_general($post, $input_errors) { $input_errors[] = "You can not run squid on the same port as the webgui"; } - if (($post['transparent_proxy'] != 'on') && ($post['private_subnet_proxy_off'] == 'on')) { - $input_errors[] = "You can not bypass traffic to private subnets without using the transparent proxy."; - } - - if (($post['transparent_proxy'] != 'on') && !empty($post['defined_ip_proxy_off'])) { - $input_errors[] = "You can not bypass traffic from specific IPs without using the transparent proxy."; - } - if (($post['transparent_proxy'] != 'on') && !empty($post['defined_ip_proxy_off_dest'])) { - $input_errors[] = "You can not bypass traffic to specific IPs without using the transparent proxy."; - } - foreach (array('defined_ip_proxy_off') as $hosts) { foreach (explode(";", $post[$hosts]) as $host) { $host = trim($host); @@ -690,6 +679,7 @@ function squid_resync_cache() { $memory_cache_size = ($settings['memory_cache_size'] ? $settings['memory_cache_size'] : 8); $max_objsize = ($settings['maximum_object_size'] ? $settings['maximum_object_size'] : 10); $min_objsize = ($settings['minimum_object_size'] ? $settings['minimum_object_size'] : 0); + $max_objsize_in_mem = ($settings['maximum_objsize_in_mem'] ? $settings['maximum_objsize_in_mem'] : 32); $cache_policy = ($settings['cache_replacement_policy'] ? $settings['cache_replacement_policy'] : 'heap LFUDA'); $memory_policy = ($settings['memory_replacement_policy'] ? $settings['memory_replacement_policy'] : 'heap GDSF'); $offline_mode = ($settings['enable_offline'] == 'on' ? 'on' : 'off'); @@ -712,7 +702,7 @@ function squid_resync_cache() { $conf = <<<EOD cache_mem $memory_cache_size MB -maximum_object_size_in_memory 32 KB +maximum_object_size_in_memory $max_objsize_in_mem KB memory_replacement_policy $memory_policy cache_replacement_policy $cache_policy cache_dir $disk_cache_opts |