SquidGuard Redirector
-
Hi
I am testing pfS 1.2 with a view to migrating over from IPcops. One feature we use a lot is URL Filter on the IPcop so I am trying to get the same functionality configured with pfS and SquidGuard.I would like a redirector to an .asp page on an external web server but also passing the client IP, group and requested URL in the Query String (or as a POST).
In the Default Redirect field I have tried every possible combination I can think of (over the past 5 hours!) but I can only pass one variable to the redirected page.If I enter the following in the redirector field:
http://webserver.mydomain.com/accessdenied.asp?group=%t&caddr=%iI only get the first parameter after the ?
Looking in squidGuard.conf, the following is generated:
redirect http://10.0.2.1/sgerror.php?url=http://webserver.mydomain.com/accessdenied.asp?group=%t&caddr=%i&a=%a&n=%n&i=%i&s=%s&t=%t&u=%uIt appears to be appending the parameters automatically at the end of the url, so I tried omitting them from the redirector field in the web GUI. This then gives:
redirect http://10.0.2.1/sgerror.php?url=http://webserver.mydomain.com/accessdenied.asp&a=%a&n=%n&i=%i&s=%s&t=%t&u=%u
My browser expects to see a '?' in the URL to denote the start of the query string parameters not an '&' so consequently none of the parameters are passed!
Can anyone help?
This is driving me nuts!Thanks
Gordon -
Set 'Redirect mode' field as 'External …' (General page) and use you own block page URL.
-
Doh!
That worked.Many thanks
Gordon