I have Apache set up as a load balancer. I wanted to make apache set the X-Forwarded-Proto header, but this doesn't work:
RequestHeader set X-Forwarded-Proto "%{SERVER_PROTOCOL}e"
The header gets set to null. Any idea why?
apache-2.2http-headersload balancing
I have Apache set up as a load balancer. I wanted to make apache set the X-Forwarded-Proto header, but this doesn't work:
RequestHeader set X-Forwarded-Proto "%{SERVER_PROTOCOL}e"
The header gets set to null. Any idea why?
Best Answer
Late but still, I've just dealt with the same issue, and this worked for me:
The documentation says:
While the HTTPS environment variable is only set when the request is made through SSL.