Forum Discussion
Domai
Altostratus
Sep 14, 2016iRule check data data group assist
Hello I need help with an iRule if possible. I am trying to accomplish 2 things.
1. Redirect if the url is abc.com to abc.com/login.jsp
2. Check if the uri is part of data group and allow.
So far I...
Vijay_E
Cirrus
Sep 14, 2016Assuming the iRule is intended ONLY for abc.com domain:
when HTTP_REQUEST {
if { [HTTP::host] eq "abc.com" } {
if { [HTTP::uri] equals "/" } {
HTTP::redirect "https://abc.com/login.jsp"
} elseif { [class match [string tolower [HTTP::uri]] starts_with allow_uri_list] } {
pool allow_pool_80
} else {
Log the request for testing from client
log local0. "rejected request for [HTTP::path] from [IP::client_addr]"
HTTP::respond 200 content "Please check the URL and try again."
}
}
}
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
