Forum Discussion
david0512_20548
Nov 12, 2014Nimbostratus
HTTPS rewrite
Hi All,
Have a requirement to rewrite a https request to another url. That part is all good with "HTTP::header replace host ". However I need the server side connection to go out as a https conn...
david0512_20548
Nov 17, 2014Nimbostratus
Guys
I have the first irule qworking now but the second isnt quite right yet. Can anyone see why the folloiwng irule doesnt replace the "host" header with www.cde.com
when HTTP_REQUEST {
if { [HTTP::header host] contains "www.abc." and [HTTP::uri] starts_with "/t/" } {
HTTP::uri "/[HTTP::host][HTTP::uri]"
log local0. "first_host_uri: [HTTP::host][HTTP::uri]"
HTTP::header replace "Host" "www.def.com"
pool testredirect
log local0. "second_host_uri: [HTTP::host][HTTP::uri]"
}
}
Results from the log statements are the following.....
Rule /xxx/xxx_redirect_2 : first_host_uri: www.abc.com/www.abc.com/t/spain
Rule /xxx/xxx_redirect_2 : second_host_uri: www.abc.com/www.abc.com/t/spain
It seems the http header replace host command isnt being actioned but not sure why.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects