<div dir="ltr"><div><div><div>Hi all, <br><br></div>I wanted to check with your accumulated wisdom the following squid configuration. <br><br></div>The config is working both for splice or bump (by commenting/uncommenting the respective line) using TPROXY. It is a config ported form an old installation of squid 3.1 for the new 3.5 and although I did some cleanup I am wondering if I am misusing any directive or missing any crucial one for better performance or just for sake of cleanliness.<br><br></div>At the moment for filtering I am using squidGuard and considering to go with ufdbGuard instead as pointed from Amos (thanx for that).<br> <br><div>To avoid issues with some sites I am considering to use only splicing, although this has some caveats as bumping also does. I could go with a hybrid approach (splice some and bump all) but this sounds that this will cause periodically more administrative overhead to sort out the sites that need splicing. <br><br></div><div>The config has also some ACLs as an attempt to block media streaming by those seem to not work.<br><br></div><div>The hardware running the squid is somehow small with 4 GB of RAM, 4 CPU cores and 100 GB SSD in case one wonders. <br></div><div><br></div><div><br><div><div><div><div><span style="font-family:monospace,monospace">http_port <a href="http://192.168.200.1:3128">192.168.200.1:3128</a> tproxy<br>https_port <a href="http://192.168.200.1:3129">192.168.200.1:3129</a> tproxy ssl-bump generate-host-certificates=on dynamic_cert_mem_cache_size=4MB cert=/etc/squid/ssl_cert/myCA.pem<br><br>sslcrtd_program /usr/lib/squid/ssl_crtd -s /usr/local/squid/var/lib/ssl_db -M 4MB<br>sslcrtd_children 5<br><br>shutdown_lifetime 5 seconds<br><br># ACL<br>#acl ncsa_users proxy_auth REQUIRED<br>#acl all src <a href="http://0.0.0.0/0.0.0.0">0.0.0.0/0.0.0.0</a><br>acl manager proto cache_object<br>acl localhost src <a href="http://192.168.200.1/32">192.168.200.1/32</a><br><br>acl SSL_ports port 443<br>acl Safe_ports port 80<br>acl Safe_ports port 21<br>acl Safe_ports port 443<br>acl Safe_ports port 10080<br>acl Safe_ports port 10443<br>acl SSL method CONNECT<br>acl CONNECT method CONNECT # multiling http<br>#acl block_url dstdomain "/etc/squid/block_url.squid"<br>#acl allow_url dstdomain "/etc/squid/allow_url.squid"<br>acl ELAN src <a href="http://192.168.200.0/24">192.168.200.0/24</a><br><br>acl QUERY urlpath_regex cgi-bin \?<br><br># SSL<br>always_direct allow all<br><br># Video Streaming ACLs<br>acl media rep_mime_type ^.*mms.*<br>acl media rep_mime_type ^.*ms-hdr.*<br>acl media rep_mime_type ^.*x-fcs.*<br>acl media rep_mime_type ^.*x-ms-asf.*<br>acl media2 urlpath_regex dvrplayer mediastream mms://<br>acl media2 urlpath_regex \.asf$ \.afx$ \.flv$ \.swf$<br>acl flashvideo rep_mime_type -i video/flv<br>acl flashvideo rep_mime_type -i video/x-flv<br>acl shockwave rep_mime_type -i ^application/x-shockwave-flash$<br>acl x-type req_mime_type -i ^application/octet-stream$<br>acl x-type req_mime_type -i application/octet-stream<br>acl x-type req_mime_type -i ^application/x-mplayer2$<br>acl x-type req_mime_type -i application/x-mplayer2<br>acl x-type req_mime_type -i ^application/x-oleobject$<br>acl x-type req_mime_type -i application/x-oleobject<br>acl x-type req_mime_type -i application/x-pncmd<br>acl x-type req_mime_type -i ^video/x-ms-asf$<br>acl x-type2 rep_mime_type -i ^application/octet-stream$<br>acl x-type2 rep_mime_type -i application/octet-stream<br>acl x-type2 rep_mime_type -i ^application/x-mplayer2$<br>acl x-type2 rep_mime_type -i application/x-mplayer2<br>acl x-type2 rep_mime_type -i ^application/x-oleobject$<br>acl x-type2 rep_mime_type -i application/x-oleobject<br>acl x-type2 rep_mime_type -i application/x-pncmd<br>acl x-type2 rep_mime_type -i ^video/x-ms-asf$<br><br># Block Media Streaming<br>http_reply_access deny flashvideo<br>http_reply_access deny shockwave<br>http_reply_access deny media<br>http_reply_access deny media2<br>http_reply_access deny x-type<br>http_reply_access deny x-type2<br><br>#<br>http_access deny manager<br>http_access deny !Safe_ports<br>http_access deny CONNECT !SSL_ports<br>#http_access deny block_url<br>#http_access allow allow_url<br>http_access allow LAN<br>http_access allow ELAN<br><br>http_access allow localhost<br>#http_access allow ncsa_users<br>http_reply_access allow all<br><br>deny_info ERR_CUSTOM LAN ELAN media media2 flashvideo shockwave x-type x-type2<br>error_directory /usr/share/squid-langpack/en<br><br>#icp_access allow all<br><br># Logging<br>logfile_daemon /usr/lib/squid/log_db_daemon<br>access_log daemon:/<a href="http://127.0.0.1/squid_log/access_log/squid/squid">127.0.0.1/squid_log/access_log/squid/squid</a> squid<br>icap_log stdio:/var/log/squid/icap.log squid<br>cache_store_log stdio:/var/log/squid/store.log<br><br># DNS<br>dns_nameservers 127.0.0.1<br>positive_dns_ttl 8 hours<br>negative_dns_ttl 30 seconds<br>ipcache_size 2048<br>ipcache_low 95<br>ipcache_high 97<br>fqdncache_size 2048<br><br># Leave coredumps in the first cache dir<br>coredump_dir /var/spool/squid<br>cache_dir ufs /var/spool/squid 10240 16 256<br>minimum_object_size 0 KB<br>maximum_object_size 30 MB<br>maximum_object_size_in_memory 1024 KB<br><br># HTTPS filtering<br>acl step1 at_step SslBump1<br><br>ssl_bump peek step1<br>ssl_bump splice all<br>#ssl_bump bump all<br><br># SquidGuard<br>url_rewrite_program /usr/bin/squidGuard -c /etc/squidguard/squidGuard.conf<br>url_rewrite_children 5</span><br><br><br>Your input is highly appreciated.<br><div><div><div><div><br></div></div></div></div>Alex<br></div></div></div></div></div></div>