http->https redirection on the same port

Igor Sysoev is at
Thu Jun 19 00:56:40 MSD 2008

On Wed, Jun 18, 2008 at 01:53:28PM -0700, Michael Nachbaur wrote:

> On 18-Jun-08, at 1:21 PM, Igor Sysoev wrote:
> >On Wed, Jun 18, 2008 at 01:05:26PM -0700, Michael Nachbaur wrote:
> >
> >>On 17-Jun-08, at 9:11 AM, Igor Sysoev wrote:
> >>
> >>>BTW, how had you implemented this in Apache ?
> >>
> >>We built this with an ugly CGI script that handled the  
> >>redirection.  I
> >>can't remember off the top of my head how this is built, because it
> >>was written before my time.  Lighttpd supports a "$HOST[scheme]"
> >>variable that can be used to handle request configuration, but it
> >>seems to be buggy.
> >
> >I had asked because last time I checked this, Apache simply returned  
> >400
> >for a plain HTTP request sent to a HTTPS server. I'm curious how do
> >you pass the request to CGI script ?
> Well, we listed the error handler for 400 errors as being /cgi-bin/ 
> 400.cgi which outputted a redirect page containing meta refresh to the  
> new URL.

But where do you know host name ? AFAIK Apache does not preserve it.

Igor Sysoev

More information about the nginx mailing list