Forum Discussion
jokragly
Nimbostratus
Nov 03, 2010iRule for URI ACL
Good afternoon. We are getting desperate trying to find a solution to allow specific URIs and deny all other traffic.
Basically what we are after is to allow access to 5 specific directorie...
George_Watkins_
Nov 03, 2010Historic F5 Account
Hi Jeff,
Something like this might do the trick:
rule mycompany_url_acl {
when HTTP_REQUEST {
if { ![matchclass [HTTP::path] starts_with $::mycompany_allowed_urls] } {
HTTP::redirect http://mycompany.com/sorry_url.html
}
}
}
You'll also need a datagroup called "mycompany_allowed_urls". This is what it looks like in my bugip.conf:
class mycompany_allowed_urls {
{
"/Dealer/"
"/Help/"
"/Image/"
"/Login/"
"/User/"
}
}
Hope this helps,
George
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