Forum Discussion
arjun_ankathil_
Nimbostratus
Apr 07, 2010Http redirection for specific URL and HTTP to HTTPs redirection
Hi ,
We have a situation where we have HTTPs for specific Virtual server, We have certain URLs under that VS which works only on HTTP, and we need HTTP to HTTPS redirection expect those URLs.
Please help me with a irule.
4 Replies
- hoolio
Cirrostratus
Hi Arjun,
Can you explain a bit more on why you only want to have some URIs requested via HTTP?
Are you decrypting HTTPS traffic on LTM using a client SSL profile and then passing the traffic to the pool members via HTTP? If so, all traffic to the pool members should be unencrypted.
Thanks,
Aaron - nick_84883
Nimbostratus
I have a similar problem... any help? - nick_84883
Nimbostratus
my problem is that I have 2 VS's, one for HTTP and one for HTTPS. Now, the HTTP VS originally had a blanket redirect HTTP>HTTPS, but now there are 2 sub domains that need to be HTTP.
They are:
http://blah.com/test/site1
http://blah.com/test/site2
So I need all traffic to be redirected to HTTPS except for the above sites. Any idea how I get this going as I have been pulling my hair out all day? - hoolio
Cirrostratus
Hi Nick,
You can use an iRule like this to selectively redirect HTTP requests to HTTPS:when HTTP_REQUEST { switch [string tolower [HTTP::path]] { "/test/site1" - "/test/site2" { Do nothing so the request will be sent to the VIP's default pool } default { HTTP::redirect "https://[HTTP::host][HTTP::uri]" } } }
Aaron
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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