Aaron J Mackey wrote:
> Yes: simply because I want to be able to install the software at new
> sites with minimal httpd.conf twiddling (and the user has a configuration
> file in which they can switch on/off the SSL requirement).
in that case, you probably want to check $r->subprocess_env('HT
ent: Monday, May 13, 2002 1:12 PM
> > To: [EMAIL PROTECTED]
> > Subject: automatic redirect to https
> >
> >
> >
> > Can anyone see something wrong with this, or suggest a better
> > mechanism:
> >
> > unless ( $ENV{HTTPS} ) {
> > #
om: Aaron J Mackey [mailto:[EMAIL PROTECTED]]
> Sent: Monday, May 13, 2002 1:12 PM
> To: [EMAIL PROTECTED]
> Subject: automatic redirect to https
>
>
>
> Can anyone see something wrong with this, or suggest a better
> mechanism:
>
> unless ( $ENV{HTTPS} ) {
On Mon, 13 May 2002, Geoffrey Young wrote:
> hmm, that's interesting - I guess you're catching a setting?
> If
> so, there's probably not much you can do about it save something like
>
> my $uri = Apache:URI->parse($r);
> $uri->hostname($r->headers_in->get('Host'));
That did the trick - the b
Aaron J Mackey wrote:
> On Mon, 13 May 2002, Geoffrey Young wrote:
>
>
>>my $uri = Apache::URI->parse($r);
>>
>
> Well, now $uri->unparse yields this: "null: https://_default_/mydirectory";
>
> Which of course doesn't work in the Location field of the redirect. I can
> munge this as I need
On Mon, 13 May 2002, Geoffrey Young wrote:
> my $uri = Apache::URI->parse($r);
Well, now $uri->unparse yields this: "null: https://_default_/mydirectory";
Which of course doesn't work in the Location field of the redirect. I can
munge this as I need, but I was hoping for something cleaner.
-
Aaron J Mackey wrote:
> Can anyone see something wrong with this, or suggest a better mechanism:
>
> unless ( $ENV{HTTPS} ) {
> # bounce request to secure port
> my $uri = $r->parsed_uri();
> $uri->scheme('https');
> $r->header_out(Location => $uri->unparse(
Can anyone see something wrong with this, or suggest a better mechanism:
unless ( $ENV{HTTPS} ) {
# bounce request to secure port
my $uri = $r->parsed_uri();
$uri->scheme('https');
$r->header_out(Location => $uri->unparse());
return REDIRECT;
}
Th