Skip Menu |

This queue is for tickets about the AxKit-XSP-WebUtils CPAN distribution.

Report information
The Basics
Id: 3118
Status: new
Priority: 0/
Queue: AxKit-XSP-WebUtils

People
Owner: Nobody in particular
Requestors: chrislaco [...] hotmail.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 1.3_90
  • 1.4
  • 1.5
  • 1.6
Fixed in: (no value)



Subject: request_host broken behind a proxy
When accessing an AxKit hosted page from behind a proxy, the request_host sub returns the wrong data. (http://PROXY/ instead of http://mysitename/) I found the patch a while back from Mark A. Hershberger (Fri, 04 Oct 2002 10:35:46 -0500) and used it to patch the 1.4 version. Attached is a patch for the 1.6 version. -=Chris
--- WebUtils.pm.orig Fri Aug 1 15:02:11 2003 +++ WebUtils.pm Fri Aug 1 15:06:07 2003 @@ -78,9 +78,7 @@ } sub request_host () { - my $hostname = Apache->header_in('Via'); - $hostname =~ s/^[0-9.]+ //g; - $hostname =~ s/ .*//g; + my $hostname = Apache->request->hostname; $hostname ||= $ENV{HTTP_HOST}; $hostname ||= Apache->header_in('Host'); return $hostname;