This section elaborates the steps to enable rewrite host header to server name.
When proxying a request to a back-end server through Avi Load Balancer, an SE can rewrite the host header to the server name of the back end server to which the request is forwarded. This functionality can be turned on for selected or all servers in the pool.
Enabling Rewrite Host Header Option
The Rewrite Host Headeroption can be enabled by selecting Rewrite Host Header check box corresponding to the individual server for which this behavior is intended.
If the rewrite host header to SNI is turned ON
with this feature, it takes precedence over the to server name feature.
Using rewrite_host_header_to_server_name
with rewrite_host_header_to_sni
Below are the few observations which clarifies how rewrite_host_header_to_server_name
interacts with rewrite_host_header_to_sni
.
For Non-SSL back-end servers:
rewrite_host_header_to_sni
has no effect on the non-SSL back-end servers. Host Header is set according to therewrite_host_header_to_server_name
flag.For SSL back-end servers with the
TLS SNI Enabled
flag set asOFF
: Therewrite_host_header_to_sni
has no effect. The Host header is set according to therewrite_host_header_to_server_name
flag.For SSL back-end servers with the
TLS SNI Enabled
flag set asON
: Incoming Host Header = Abc.com.
The following combination of the configuration options is not supported because the SNI name used in the SSL handshake, and the host header used in the request do not match.
The
TLS SNI Enabled
flag is set asON
.SNI name is configured in the pool, while the
rewrite_host_header_to_server_name
option isenabled
.
Rewriting Host Header with Pool Member and Port Number
Support for providing port number is available while rewriting the host header with the pool member.
To update the port to the hostname in the host header, the following options are available under the pool configuration:
Append port if not default port for protocol (80 and 443)
Never append port
Always append port