Forum Discussion
sfracass_83515
Nimbostratus
Apr 11, 2008iRule to block networks works, sometimes.....
I just want to block googlebot requests to certain virtual servers at the LTM but this rule doesn't seem to work. Oddly enough, when I change the IP values to block my own internal network subnets at the same virtual servers, it works. I had to block at the router where I could see in the logs the rejection of the IP specified, so I know the IP is coming into my network as expected (not NAT'd).
when CLIENT_ACCEPTED {
if { [IP::addr [IP::remote_addr] equals 60.249.0.0/255.255.0.0] } {
reject
}
}
Any help is appreciated.
- Did you log the value of IP::remote_addr to verify it's correct when googlebot is trying to access it?
when HTTP_REQUEST { if { [string tolower [HTTP::header "User-Agent"]] contains "googlebot" } { reject } }
- sfracass_83515
Nimbostratus
BUT, Googlebot is a legitimate useragent for organizations with google appliances. We needed to specifically block Google's googlebot.
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