Re: [squid-users] Reverse proxy redirector

From: Kinkie <[email protected]>
Date: Wed, 02 Feb 2005 09:18:44 +0100

On Tue, 2005-02-01 at 11:02 -0500, Brad Taylor wrote:
> I have a redirector setup on my reverse squid proxy to change all http
> requests to https. But it doesn't seem to be working. Here is the
> script:
>
> #!/usr/bin/perl
> $|=1; #Don't buffer output.
>
> while(<>) #Infinite loop. running as a daemon
> {
> $url=(split)[0];
> $url=~ s/^http:/https:/;
> print "$url\n";
> }
>
> See any reason why this will not redirect http to https?

If you want to send a redirect to the client the script has to return
print "302:$url\n";

        Kinkie
Received on Wed Feb 02 2005 - 01:19:10 MST

This archive was generated by hypermail pre-2.1.9 : Tue Mar 01 2005 - 12:00:01 MST