Forum Discussion
John_Merritt_45
Nimbostratus
Nov 06, 2006Need help with multi domain url rewrite
I am new to the iRule world. I have multiple domains that I need to rewrite. The first group should all rewrite to the same url. However I have another domain that I want to rewrite to a second url...
steve_cross_650
Nimbostratus
Nov 17, 2006Thanks Joe, this code now correctly redirects the pages listed in my string data group "secure_pages" to a https URL:
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] equals "test.mywebsite.com"}
{
if { [matchclass [string tolower [HTTP::uri]] starts_with $::secure_pages]}
{
HTTP::redirect "https://[HTTP::host][HTTP::uri]"
}
else
{
pool pool_A
}
}
else
{
pool pool_B
}
}
Now I have another issue. I want to make sure that any pages that are NOT listed in "Secure_pages" are always treated as http (and not https). Here is our business senario:
1) User comes to page_1 (http)
2) Clicks on "login". Login is in "secure_pages" string data group. (https)
3) Upon successful login we automatically redirect user to page2 (http)
Unfortunately no matter what I try the step 3 always remains https OR it doesn't do the redirect at all. Any thoughts?
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