Forum Discussion
automatic redirect problem.
I have a one arm model.
Client --> http --> F5 --> http -- server
This works fine.
Client -->https -->F5 -->http --server
I try to open the link with https but it opens with http url. When i disabled the http VS on F5 then tried with https then page was not opening at all.
What could be the problem and how to resolve this? Why url is redirected to https to http automatically? I want https to remain https.
Please help
6 Replies
- Michael_Jenkins
Cirrostratus
To clarify, do you have 2 VIPs for the same IP (one http and one https) that both go to the same pool using http?
What's your VIP config(s) look like? With the CLI, you can do something like
to get the config. Can you past the config (sanitize as needed) here to help debug?tmsh list ltm virtual VIRTUAL_NAME - Brad_Parker_139
Nacreous
You web server is most likely generating the links with an absolute path. You have a few options to help with that if your devs can't change the link to relative easily. You can just have a redirect setup on 80 that redirects everything over to HTTPS, enable your site to use HSTS which will tell modern browsers to never even try going to HTTP and always go to HTTPS for the domain, or you can use stream profile to rewrite all the respons links coming from the server to https.
- Yes sir you are right about redirecting each response from 80 to 443. I am using version 11.2.1. My VIP,s are 10.50.180.14:80 and 10.50.180.14:443. Sir can you please make me a simplest iRule for this. I will be grateful.
- Brad_Parker
Cirrus
You web server is most likely generating the links with an absolute path. You have a few options to help with that if your devs can't change the link to relative easily. You can just have a redirect setup on 80 that redirects everything over to HTTPS, enable your site to use HSTS which will tell modern browsers to never even try going to HTTP and always go to HTTPS for the domain, or you can use stream profile to rewrite all the respons links coming from the server to https.
- Yes sir you are right about redirecting each response from 80 to 443. I am using version 11.2.1. My VIP,s are 10.50.180.14:80 and 10.50.180.14:443. Sir can you please make me a simplest iRule for this. I will be grateful.
- Michael_Jenkins
Cirrostratus
You can use the STREAM::expression command in an iRule to accomplish what Brad mentioned. There's an example iRule for rewriting http to https on the wiki page.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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