EFW Support

Support => EFW SMTP, HTTP, SIP, FTP Proxy Support => Topic started by: lukew on Wednesday 02 November 2011, 01:46:12 am



Title: How to rewrite google search to force all queries to have safesearch active
Post by: lukew on Wednesday 02 November 2011, 01:46:12 am
Hi all,
I would like to know the steps to rewrite the google search string to force the safesearch for all queries.

I guess it should look something like this ...but I am unsure how that translates into the current endian squid config.


rewrite google {
    s@(google.com/search.*q=.*)@\1\&safe=active i
    s@(google.com/images.*q=.*)@\1\&safe=active i
    s@(google.com/groups.*q=.*)@\1\&safe=active i
    s@(google.com/news.*q=.*)@\1\&safe=active i
    # log google
}

acl {

default {
                # for google to be in "safe mode"
                rewrite google
                pass all
                pass eg-ok !eg-block local-ok !local-block !aggressive !hacking !violence !gambling !porn !warez all


Thanks,
Luke