OPNsense Forum
English Forums => Development and Code Review => Topic started by: tillsense on December 28, 2016, 07:46:02 am
-
Hi,
the configuration page of squid (cache settings) does not allow 0 to disable memory cache size in megabytes.
Squid.conf
cache deny all
cache_mem 0
Reference: http://www.squid-cache.org/Advisories/SQUID-2016_11.txt
cheers till
--------------------------------------------------------------------
OPNsense 17.1.b_66-amd64
FreeBSD 11.0-RELEASE-p5
OpenSSL 1.0.2j 26 Sep 2016
-
config screen:
-
Nice catch, how about instead writing these two lines by default when "Enable local cache" is disabled?
FWIW, 16.7.13 shipped the fixed Squid 3.5.23.
-
hi franco,
yes i think that would be a good preset!
cheers till
-------------------------------------
OPNsense 17.1.b_94-amd64
FreeBSD 11.0-RELEASE-p6
OpenSSL 1.0.2j 26 Sep 2016
-
Hi Till,
This should do the trick: https://github.com/opnsense/core/commit/d3e27cface8
Cheers,
Franco
-
Hi Franco,
i looked at this and i think this should be 0. For 0 is a good config the two lines to write off but 1 is 1 MB for cache_mem. Or maybe better an checkbox? The used full help is also misleading here.
cheers till
-------------------------------------------
OPNsense 17.1.b_103-amd64
FreeBSD 11.0-RELEASE-p6
OpenSSL 1.0.2j 26 Sep 2016
-
Hi Till,
Not sure what you mean. I had to go back and implement your idea anyway, the cache disable/enable is a bit incoherent for us:
https://github.com/opnsense/core/commit/cf48dbb970
Cheers,
Franco
-
Hi Franco,
in post 5 i had not seen your second commit yet ;) as far as the checkbox is concerned it could be similar to the activation of the local cache by checkbox.
But the implementation of https://github.com/opnsense/core/pull/1328 (https://github.com/opnsense/core/pull/1328) should have prio for backend that's the right way :)
cheers till
-------------------------------------------
OPNsense 17.1.r-amd64
FreeBSD 11.0-RELEASE-p7
OpenSSL 1.0.2j 26 Sep 2016