Forum Discussion
Bob_66655
Nimbostratus
Oct 10, 2018F5 host header rewrite different domain
Im trying to do rewrite of https://abc.com/code/* to https://xyz.com/* when HTTP_REQUEST { if { [HTTP::host] contains "abc.com" && [HTTP::uri] starts_with "/code" }
...
Lee_Sutcliffe
Nacreous
Oct 10, 2018Your iRule looks fine and the string map logic is correct - I've tested it nativity in TCL:
% set uri /one/two/three
/one/two/three
% set new [string map {"/one" ""} $uri]
/two/three
If you are receiving a bad request from the pool member - it maybe that the new URI is incorrect and the web server is unable to process it.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
