Forum Discussion
DaZZa
Nimbostratus
Jun 26, 2017HTTPS redirection with exceptions
Hi.
I have a web site which is used to by developers to build out corporate product. Because it's used for QA purposes, I want it to be as realistic as possible - but I am putting all the associ...
CharlesCS
Cirrus
Jun 27, 2017For hostname comparisons, use HTTP::host instead of HTTP::path, like so:
when HTTP_REQUEST {
switch [string tolower [HTTP::host]] {
"foo.bar.com" -
"baz.bar.com" -
"yet.another.subdomain.of.bar.com" { return }
default {
HTTP::redirect https://[getfield [HTTP::host] ":" 1][HTTP::uri]
}
}
}
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
