16-Apr-2021 05:54
The X-Forwarded-Host HTTP request header is required to forward the original Host HTTP request header value to the origin server.
When the user sends requests to https://abc.pfc.net/ , the request forwarded by F5 to the backend server
must contain the X-Forwarded-Host header with the value of the source of the request (which is https://abc.pfc.net/ in this example)
The backend server should be able to know what the host/FQDN from which the request came from so it will return to the client the same URL.
16-Apr-2021
06:24
- last edited on
04-Jun-2023
20:57
by
JimmyPackets
BIGIP doesn't modify HOST header values by default. So server should receive original HOST header coming from the client. But if you still want to pass it explicitly you can use something sort of below.
when HTTP_REQUEST {
while {[HTTP::header exists "X-Forwarded-Host"]}{
HTTP::header remove "X-Forwarded-Host"
}
HTTP::header insert "X-Forwarded-Host" [HTTP::host]
}