Koozali.org: home of the SME Server

Windows Cache still a problem with Squidguard

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Windows Cache still a problem with Squidguard
« on: March 20, 2005, 04:16:51 PM »
I noticed a recent update on smeplus.sh script which deals with windows update cache manager. The new one comes from http://perso.wanadoo.fr/passionelectro/ but unfortunatelly it still does not work if squidguard is in place. After installing you'll start seing broken pictures and dynamic pages stop working (even access to this forum). So this is more like a bug report, disabling the cache also does not fix it, you need to remove.

jaco

Windows Cache still a problem with Squidguard
« Reply #1 on: March 22, 2005, 03:46:19 PM »
Squid does not seem to allow for more than one redirector. The partially loaded pages are typical of squid being unhappy.

Have a look at  http://adzapper.sourceforge.net/#chaining for a solution. This script allows you to chaing multiple redirectors together (eg. squidguard and windows update manager)

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Windows Cache still a problem with Squidguard
« Reply #2 on: March 23, 2005, 12:55:59 AM »
Thanks jaco,
I believe this is exactly how the cache manager works (http://www.squid-cache.org/Doc/FAQ/FAQ-15.html). Do you have yours working? Can you shed a light?

Regards,

jaco

Windows Cache still a problem with Squidguard
« Reply #3 on: March 23, 2005, 03:52:02 PM »
To set it up I did the following:
1. Modify /etc/squid/squid.conf with the following lines: (Note: You should do this in a custom template)
Code: [Select]
redirect_program /etc/squid/redirect/wrapzap
redirect_children 5

2. In /etc/squid/redirect/wrapzap -- right at the end of the file:
Code: [Select]
exec /etc/squid/redirect/zapchain /usr/local/bin/squidGuard /etc/squid/redirect/redir.pl


Now zapchain will chain together squidGuard and redir.pl

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Windows Cache still a problem with Squidguard
« Reply #4 on: March 23, 2005, 05:11:00 PM »
Jaco,
wrapzap and zapchain are redirectors for advertizements (a filtering option):
snip:
Quote
This is a redirector for squid that intercepts advertising (banners, popup windows, flash animations, etc), page counters and some web bugs (as found). This has both aesthetic and bandwidth benefits.

What I'm trying to do is cache the content of Windows updates and redirect the internal client to the cache instead of Microsoft Servers. The cache checks to see if it has the content on it, if not let it pass through, otherwise it serves locally.

jaco

Windows Cache still a problem with Squidguard
« Reply #5 on: March 23, 2005, 07:40:49 PM »
zapchain chains redirectors together.
redir.pl handles the windows update cache
squidGuard checks the URL's based on the rules you configured.

So, when you browse to a web site (or if windows tries to update from Microsoft's web site), then squid asks wrapzap if it is OK to go to that site. Wrapzap asks zapchain to chain together squidGuard and redir.pl and tell it if you can go to the site. Either squidGuard or redir.pl may modify the URL and pass it back to zapchain that passes the URL back to wrapzap that passes it back to squid.

This is a very simplified version of the events, but it basically means that you are chaining multiple redirectors together. This allows you to run both squidGuard and the update cache checker.

Have a look at the last comment in wrapzap. It will explain how you can use wrapzap for the above and not for advertising etc.