Blocking access to certain URI except from IP Address
Hi All,
I am trying to block access to the admin sections of my website, unless the request comes from one of my public IP addresses.
The rule I tried to implement looks like this:
when HTTP_REQUEST {
if { [HTTP::host] equals "www.mywebsite.com.au" and [HTTP::uri] equals "/provider/faces/provider.jspx" or "/faces/admin.jspx" or "/reporting/BOE/BI" and !([matchclass [IP::remote_addr] equals $::MyPublicAddressPool ]) } {
reject
}
else {
return
}
}
It is based on another example I saw in the forums. The trouble is, when I implement this iRule, it ends up blocking all traffic to my website, rather than just the admin URI listed above.
Could someone point me to where I am going wrong? I don't think I'm that far. off.
Thanks in advance.