Forum Discussion
Gorkalrp_105155
Nimbostratus
Jun 18, 2015Need help: iRules to allow only URIs
I would appreciate if some one could help me in create iRule/datagroup and applying iRule to allow only few URI's and remaining all should go to invalid page.
https://Ind-hyd.vidya.com/KURservle...
stan_piron
Cumulonimbus
Jun 19, 2015The previous irule must generate cyclic redirect as the else statement redirect to the same URL.
the following irule must answer the need:
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::path]] {
switch -glob [HTTP::path] {
"/KURservlet/servlet/KURServlet*" -
"/KURservlet-stage/servlet/KURServlet*" -
"/KURservlet-test/servlet/KURServlet*" {}
default { HTTP::redirect noserver "https://Ind-hyd.vidya.com/error/invalid.html }
}
}
The commented line is if you need to ignore the case. if you use this line, all conditions must be changed to lowercase.
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