Forum Discussion
Ravier_356281
Nimbostratus
Mar 21, 2018Redirect from HTTP to HTTPS if SSL Profile exists on the HTTPS virtual server
We have several load balancers configured on this F5 using the following irule:
when HTTP_REQUEST {
switch -glob [HTTP::uri] {
"Redacted URI" { return }
"Redacted URI" { return }
...
Ben_Noonan
Nimbostratus
Mar 23, 2018I believe this may work:
when HTTP_REQUEST {
if { [SSL::mode] == 0} { HTTP::redirect http://[HTTP::host][HTTP::uri]}
}
- Ravier_356281Apr 17, 2018
Nimbostratus
I'm not sure that's what I'm looking for.
I already have the redirect working for everything that is http to be redirected as HTTPS.
What I need now is basically an exemption mechanism where if the request comes in, and there's no SSL profile for that URL, then to let it go through as HTTP.
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