Bug 485535 - Google safe rewrite doesn't work any more
Summary: Google safe rewrite doesn't work any more
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: squidGuard
Version: 10
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Gwyn Ciesla
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-02-13 23:32 UTC by Bojan Smojver
Modified: 2009-02-24 14:30 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-02-20 03:56:33 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Bojan Smojver 2009-02-13 23:32:47 UTC
Description of problem:
Rewrite rules like this:
-------------------------
rewrite google {
    s@(google\.com(\.[a-zA-Z][a-zA-Z])*/search.*q=.*)@\1\&safe=active@i
    s@(google\.com(\.[a-zA-Z][a-zA-Z])*/images.*q=.*)@\1\&safe=active@i
    s@(google\.com(\.[a-zA-Z][a-zA-Z])*/groups.*q=.*)@\1\&safe=active@i
    s@(google\.com(\.[a-zA-Z][a-zA-Z])*/news.*q=.*)@\1\&safe=active@i
    # log google
}
-------------------------

End up in this:
-------------------------
The following error was encountered while trying to retrieve the URL: http://www.\1\&safe=active

    Unable to determine IP address from host name "www.\1\&safe=active"

The DNS server returned:

    Name Error: The domain name does not exist.

This means that the cache was not able to resolve the hostname presented in the URL. Check if the address is correct.
-------------------------

Version-Release number of selected component (if applicable):
1.2.1-2.fc10

How reproducible:
Always.

Steps to Reproduce:
1. Hit Google.
2. Search.
  
Actual results:
Invalid rewrite.

Expected results:
Worked before upgrade to 1.2.1-2.

Additional info:

Comment 1 Arthur Dent 2009-02-16 15:24:43 UTC
Just wanted to add that I am seeing exactly the same behaviour on an F9 system since the recent update:

# cat /var/log/yum.log | grep squid
Feb 14 10:45:07 Updated: 7:squid-3.0.STABLE13-1.fc9.i386
Feb 14 10:46:13 Updated: squidGuard-1.2.1-2.fc9.i386

Any workaround or fix available?

Comment 2 Marc Rechte 2009-02-16 16:40:27 UTC
I confirm this is new since:
Feb 14 11:49:39 Updated: squidGuard-1.2.1-2.fc10.i386

Comment 3 Gwyn Ciesla 2009-02-17 15:19:58 UTC
Can you test against the 1.3 build in koji?
http://koji.fedoraproject.org/koji/buildinfo?buildID=83046

Comment 4 Arthur Dent 2009-02-17 15:43:42 UTC
I notice this is a F11 build. Will it break anything on a F9 system?

Comment 5 Gwyn Ciesla 2009-02-17 15:52:33 UTC
Shouldn't, but if you like I can build it for F-10.

Comment 6 Arthur Dent 2009-02-17 15:57:06 UTC
Oh...

# rpm -Uvh /home/mark/Installs/squidGuard-1.3-1.fc11.i586.rpm 
error: Failed dependencies:
	libdb-4.7.so is needed by squidGuard-1.3-1.fc11.i586

Should I embark into dependency hell - or just wait for a fix for F9?

Comment 7 Gwyn Ciesla 2009-02-17 16:12:08 UTC
I'll build for F-10 and F-9, but leave them in -testing.  If the problem is on F-9, you should change the version of this bug.

Comment 8 Arthur Dent 2009-02-17 16:21:05 UTC
I am not the original reporter. I merely pointed out that the bug affects *both* F9 *and* f10.

But yes please, I would very much like a F9 build. Thank you.

If you could let us know when it's available in testing I would very much appreciate it.

Comment 9 Gwyn Ciesla 2009-02-17 16:23:54 UTC
Sorry, caffeine failure.  :)  Builds coming, I'll post here. :)

Comment 11 Arthur Dent 2009-02-17 17:17:54 UTC
OK - I haven't done any form of comprehensive testing, but I can confirm that the F9 build fixes the google re-write problem as reported.

Brilliant service!

Thank you very much!

Comment 12 Gwyn Ciesla 2009-02-17 17:23:28 UTC
I thought it would:

http://www.squidguard.org/Doc/known_issues.html

I'll push it for both releases.

Comment 13 Bojan Smojver 2009-02-20 03:53:57 UTC
I can confirm that the F-10 build of 1.3 fixes the problem. Thank you!

Comment 14 Arthur Dent 2009-02-21 11:38:07 UTC
Jon,

I really appreciate your efforts here, but there is one small problem since this update:

I use a nightly cron script to download updated blacklists. This script contains some echo statements to report progress and errors, and the command 
"/usr/bin/squidGuard -C all"
to rebuild the databases. Previously this ran silently. Now it reports progress as follows:
Processing file and database /var/squidGuard/blacklists/blacklists/porn/domains
    [==================================================] 100 % done

This is fine when run from the command line, but when run as a cron job it fills the output with characters that result in a c.800mb email!
(it also takes approximately 3 times as long to run)

Is this the intended behaviour?
Is there an option to silence the output?
(incidentally I no longer have a man entry for squidGuard)

Should I report this as a bug or a feature request?

Thanks again for your work...

Mark

Comment 15 Gwyn Ciesla 2009-02-23 14:30:12 UTC
I found this in the changelog:

2007-07-16      Added patch by Marc Clayton to include a progressbar to the
                build of the database files (bug 6).


There's no -q (quiet) flag, so you'll want to file a bug upstream.  If you come up with a patch, or they issue one, let me know so I can apply it to previous versions.

Comment 16 Gwyn Ciesla 2009-02-23 14:36:18 UTC
Oh, nevermind, fixed in 1.4:

2008-07-11      Added a switch to turn on the progress bar. The old default 
                behaviour has been restored to not show anything. To see the
                progress of the compilation of the db files, use the command
                        squidGuard -b
                (-b for "bar" - the progressbar).

Comment 17 Arthur Dent 2009-02-23 15:16:41 UTC
Thanks for this Jon. Two questions:

1) Given that the version you have packaged for us is 1.3-1 what is the likely timesacle for a 1.4 version?

2) What has happened to the man page for this release?

Thanks again. Much appreciated...

Mark

Comment 18 Gwyn Ciesla 2009-02-23 15:24:54 UTC
1.4's been in rawhide a brief time, I've got a bug to fix so I'll bring 1.4 to F-10 at the same time:
https://bugzilla.redhat.com/show_bug.cgi?id=486634

2. What do you mean?  1.3 or 1.4, and is it missing, or garbled or something?

Comment 19 Arthur Dent 2009-02-23 21:13:55 UTC
I can't upgrade to F9 before Easter (and I might then decide just to wait until F11) So can I put in a plea for a F9 package too please?

# rpm -qa | grep -i squidguard
squidGuard-1.3-1.fc9.i386

$ squidGuard -v
SquidGuard: 1.3 Berkeley DB 4.6.21: (December 23, 2008)

$ man squidGuard
No manual entry for squidGuard

$ man squidguard
No manual entry for squidguard

Comment 20 Gwyn Ciesla 2009-02-23 21:22:01 UTC
That'll take a BZ, detailing why you'd like to see 1.4 for F-9.  Then, sure. :)

As far as the man page, I don't see one in any version.  When did you last have one?

Comment 21 Arthur Dent 2009-02-24 14:30:13 UTC
Man page - Erm... sorry. My bad. Looking for the "quiet" switch, my natural first course of action was to go for "man squidGuard". It didn't dawn on me that I have never used man pages for squidGuard in the past... I just assumed that there would be a man page (always bad to just assume...) Sorry.

BZ - Done
https://bugzilla.redhat.com/show_bug.cgi?id=487137

Thanks again for all your help

Mark


Note You need to log in before you can comment on or make changes to this bug.