Hi,

On Mon, Nov 09, 2009 at 10:59:33AM +0100, Jose Luis Gordo Romero wrote:
> Hi,
> 
> First congrats for this great software!
> 
> I'm forcing https in haproxy (https requests come from stunnel):
> 
>         #################
>         # Rewrite Rules
>         #################
>         # Set acl first
>         acl secure src 127.0.0.1
> 
>         redirect prefix https://www.domain.com if !secure
> 
> But I have multiple subdomains (not fixed) client1.domain.com,
> client2.domain.com, client-n.domain.com... and for the redirect to https I
> need to get and pass the host header.

We have already received this request a few times, but it's not possible
yet. At first I thought we could get this easily done by simply copying
the host header but it's not that easy in fact. If the host header specifies
a port and we are switching the protocol, then we should strip the port,
or possibly replace it with another one. Or maybe we could simply consider
that we always strip the port and always use the Host header, but even then,
some people like to use another host name (eg: X-Forwarded-Host). So this
still requires a little bit more thinking.

Regards,
Willy


Reply via email to