Dear Chteh,
Exactly i faced the same problem, yours and mine OS, squid
version is same. I also couldn't make squidguard work with squid 2.6 and
gave up. Now i m using Dansguardian for web content filtering. ...I
guess there is some compatibility issues with squidguard and squid
2.6... Well hoping somebody could get the solution for it.. Thanks
hteh wrote:
Dear all,
(Try googling for more than 2 days, problems still persists J)
I have a problem on using squid guard in my proxy server (squid 2.6).
Let me go straight to my question:
I have installed squid 2.6 stable 6.4 in CentOS 5 using yum and installed
squidguard using dag repository.
Both of the squid and squidguard were running well, but the problem is
squidguard did not block anything.
Below is snippet of my configuration for squid 2.6, I have added:
--------------------------------------------------------------------------
url_rewrite_program /usr/bin/squidguard -c /etc/squid/squidguard.conf
---------------------------------------------------------------------------
and for the squidguard, I have made a simple rules:
---------------------------------------------------------------------------
dest porn {
domainlist porn/domains
urllist porn/sites
expressionlist porn/porn_dict
log pornaccesses
}
dest gamble {
expressionlist gambling/gambling_dict
log gamblingaccesses
}
acl {
default {
pass !porn !gamble all
redirect http://localhost/squid_redirect/AccessDenied.htm
---------------------------------------------------------------------------
When I ran ps -ax, I can see both squid and squidguard were running,
[root@ComboNetfinity squid]# ps -ax|grep squid
Warning: bad syntax, perhaps a bogus '-'? See
/usr/share/doc/procps-3.2.7/FAQ
6142 ? Ss 0:00 squid -D
6144 ? S 0:00 (squid) -D
6146 ? Ss 0:00 (squidguard) -c /etc/squid/squidguard.conf
6147 ? Ss 0:00 (squidguard) -c /etc/squid/squidguard.conf
6148 ? Ss 0:00 (squidguard) -c /etc/squid/squidguard.conf
6149 ? Ss 0:00 (squidguard) -c /etc/squid/squidguard.conf
6150 ? Ss 0:00 (squidguard) -c /etc/squid/squidguard.conf
6211 pts/0 S+ 0:00 grep squid
And I did also testing the squidguard with this script:
[root@ComboNetfinity squid]# echo "http://www.sex.com / - - GET" |
squidGuard -d
2007-09-26 20:09:53 [6224] init domainlist /var/lib/squidguard/porn/domains
2007-09-26 20:09:53 [6224] loading dbfile
/var/lib/squidguard/porn/domains.db
2007-09-26 20:09:53 [6224] init urllist /var/lib/squidguard/porn/sites
2007-09-26 20:09:53 [6224] loading dbfile /var/lib/squidguard/porn/sites.db
2007-09-26 20:09:53 [6224] init expressionlist
/var/lib/squidguard/porn/porn_dict
2007-09-26 20:09:53 [6224] init expressionlist
/var/lib/squidguard/gambling/gambling_dict
2007-09-26 20:09:53 [6224] squidGuard 1.2.0 started (1190808593.505)
2007-09-26 20:09:53 [6224] squidGuard ready for requests (1190808593.509)
2007-09-26 20:09:53 [6224] Request(default/porn/-) http://www.sex.com /- - -
http://localhost/squid_redirect/AccessDenied.htm /- - -
2007-09-26 20:09:53 [6224] squidGuard stopped (1190808593.512)
[root@ComboNetfinity squid]#
The file permission of squidquard and database:
[root@ComboNetfinity squid]# ll /etc/squid/squidguard.conf
-rw-r--r-- 1 root squid 632 Sep 26 19:48 /etc/squid/squidguard.conf
[root@ComboNetfinity squid]# ll /var/lib/squidguard/porn/
total 28
-rw-r----- 1 squid squid 29 Sep 26 05:57 domains
-rw-r----- 1 squid squid 8192 Sep 26 18:26 domains.db
-rw-r----- 1 squid squid 75 Sep 26 07:45 porn_dict
-rw-r----- 1 squid squid 16 Sep 26 05:33 sites
-rw-r----- 1 squid squid 8192 Sep 26 18:26 sites.db
Thanks, and hope to hear from you all soon.
Best Regards,
Simon Teh
Network and System Administrator
National Advanced IPv6
Centre of Excellence,
School of Computer Science,
Universiti Sains Malaysia