Forum Discussion
irule for allowing mixed content
When someone is hitting the web site using IE8, http gets redirected to https (I have an irule for that) but is getting a warning message "do you want to view only the webpage content that was delivered securely?"
Is it any way to create an irule to allow mixed content so the browser would not show the warning?
The irule I use for http redirection is:
when HTTP_REQUEST {
HTTP::redirect https://[HTTP::host][HTTP::uri]
}
Thank you all for help
Sorin
4 Replies
- The_Bhattman
Nimbostratus
Hi Sorin,
I haven't found any way on an iRule - more or less I fixed the mixed content that was being displayed OR adjusted my browser not to warn me about mixed content.
CB - sbadea_81872
Nimbostratus
Adjusting the browser was not an option. I have found a solution by using a customized stream profile. Read this solution posted on support web site
https://support.f5.com/kb/en-us/solutions/public/8000/100/sol8115.html
Thanks, S.- Jaz_170005
Nimbostratus
Hi, can you please share our solution. I am facing the same situation. main app run son https, within main app there is iFrame which supposed to direct user to another app which runs on http. e.g https://mainapp.domain.com iframe within main app is http://subapp.domain.com.
I used iRule to redirect user to subapp: if https://mainapp.domain.com/subapp --> http://subapp.domain.com.
I get mixed contents error from browser when loading iFrame. if I change browser setting, it load with no issue but that is not an option.
thank you in advance.
- hoolio
Cirrostratus
Hi Sorin,
Make sure to explicitly disable the stream filter if the response type isn't text. This is something that SOL8115 doesn't show, but should.when HTTP_RESPONSE { if { [HTTP::header Content-Type] starts_with "text/" }{ STREAM::expression "@abc@123@" STREAM::enable } else { STREAM::disable } }
Also, if the string you're replacing is a different length than the replacement string, you'll need to create a custom HTTP profile with response chunking set to rechunk. This gets around a mismatch in content length as chunked responses don't use a content length header.
Aaron
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