Forum Discussion
Chad_Emerson_85
Nimbostratus
May 12, 2006Alter uri
Hey guys, I want to require https on my site by altering the http request with a rule to make it https. I have the ssl acc. feature on my box so I am trying to get it working. The only problem with the redirect is that I would need to keep their request intact due to book marks links ect... I saw an earlier example where the request was altered using something like the rule below, however I just need to make it https and retain the rest of the request. Maybe I'm making this more complicated than it needs to be but I havent found anything in the forum so far to help. Any ideas would be greatly appreciated.
when HTTP_REQUEST {
if { not ( [HTTP::uri] ends_with "/" ) } {
set newURI "[HTTP::uri]/index.html"
} else {
set newURI "[HTTP::uri]index.html"
}
HTTP::uri $newURI
}
Thanks and Have a great weekend!
- Deb_Allen_18Historic F5 AccountIf you want to redirect all port 80 traffic to https, create a virtual on port 80 and apply this rule:
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