SERVER_NAME:SERVER_PORT and UseCanonicalName in Apache conflict

Barry Flanagan barryf-lists@online.ie
Mon, 12 Nov 2001 15:13:13 +0000


Hello list,

Horde/IMP RC1 problem.

In line 280 of lib/Horde.php, you are specifically building the redirect
URLs based on the reported SERVER_NAME and SERVER_PORT variables.

This causes a problem in a set up like ours where we use front-end load
balancers which map (say) port 80 for a specific external IP to an arbitrary
internal host/port of our choosing.

As it happens, our IMP installation is running on ports 81 and 444. Apache
handles redirects perfectly by using 'UseCanonicalName Off', thus building
URLs based on the client-supplied HTTP_HOST variable alone (i.e.
'http://mail.online.ie'). However, Horde RC1 is sending back
'http://mail.online.ie:81' which does not exist in the world outside our
internal network.

Is there any real need for Horde to be building these redirect URLs as
opposed to the web server? I can see this affecting Virtual Host setups
where the SERVER_NAME (which is server wide) is NOT where the redirect
should be pointed, which would more likely want to be HOST_NAME.

Thanks in advance.

-Barry Flanagan