Forum Discussion
Change URL host without chaining in the User browser
I have request to publish one of our internal applications that is on a .local domain to be public facing on a .com domain. The team is not willing to change the URL and internal users use the .local URL but external users will use the .com.
Below is the flow I am looking to achieve, I am looking for F5 to proxy the connection and SSL offload. I cannot do a redirect as the .local is not reachable externally. I did the basic setup of setting up a VIP and SSL offloading with a pool going to the internal IP, it fails if I use just the site.
Inbound mysite.com --> F5 VIP --> mysite.local
This does work for external users but I am getting errors in the application where it is receiving the mysite.com address? I need the app to see the internal mysite.local from F5.
- Michael_Jenkins
Cirrostratus
Sounds like you may want to look at using a stream profile to perform some custom rewriting on the response since the application requires the .local address, as well as changing the
header on the request as it comes through. This may help...Host
Example which replaces xyz.local with xyz.com in response content Prevents server compression in responses when HTTP_REQUEST { Change the Host header to the internal value HTTP::host "xyz.local" Disable the stream until we're ready STREAM::disable You always need to make sure the response content is uncompressed, so the data can be properly modified HTTP::header remove "Accept-Encoding" } when HTTP_RESPONSE { Typically you may only want to rewrite certain content types (like text or html) if {[HTTP::header value Content-Type] contains "text"}{ Replace the values for xyz.local with xyz.com STREAM::expression {@xyz.local@xyz.com@} You may consider using this instead for multiple rewrites (or ensuring a url reference STREAM::expression {@://xyz.local@://xyz.com@ @://www.xyz.local@://www.xyz.com@ @} Enable the stream for this response STREAM::enable } }
Hope this helps.
- Stanislas_Piro2
Cumulonimbus
Hi Rusty,
you can use rewrite profile which is created to do it. create one rewrite rule:
- direction : both (if server response does not include internal link, use
for performance improvement)request
- client url: https://mysite.com/
- server url :
and assign it to the VS.
- direction : both (if server response does not include internal link, use
Recent Discussions
Related Content
* 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