I have this rule which is supposed to block all agent with “bot”
(http.user_agent contains “bot” and (ip.geoip.asnum ne 15169 and http.user_agent ne “Googlebot/2.1”) and (not http.user_agent contains “compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm”))
I still see this bypassing the rule
Mozilla/5.0 (compatible; Riverbot/1.0; +http://www.useriver.com/bot.html)
@sdayman
yes … AS15169 GOOGLE So what ?
Do you mean it is because I allowed googleBOT. But what is this Riverbot/1.0; +http://www.useriver.com/bot.html
while my goal is to block all except googIe and bing. I cant see the benefit of not cf.client.bot as I already blocking all “bot” without excluding CF known BOTs
is there a way to say:
block all “bot” except (the user agent googlebot that is coming from asnum 15169 )
I tried modifying this: (ip.geoip.asnum ne 15169 and http.user_agent ne “Googlebot/2.1”)
but the expression builder couldnt read it
Thank you guys, I was thinking what @sandro said
I ll try something like this
(http.user_agent contains “bot” and (not http.user_agent contains “Googlebot” and not http.user_agent contains “bingbot”) and not cf.client.bot)
I added Yandex because it’s a Known Bot, but you want to block it. You’d have to add a bunch of And rules for each one you don’t want visiting your site.
Known Bots is pretty accurate, so it’s better than trying any other Googlebot or Bingbot detection.
I was thinking this (http.user_agent contains “bot” and (ip.geoip.asnum ne 15169 and not http.user_agent “Googlebot”))
means any request coming from IP that is not a part of Google ASN and it’s user-agent string does not contain “googlebot” will be blocked
@sdayman
what do you think about this
(http.user_agent contains “bot” and not cf.client.bot) or (http.user_agent contains “bot” and not http.user_agent contains “Googlebot” and not http.user_agent contains “bingbot”)
First part will filter out fake google and bing … then second part will filter out the rest of CF known BOTs that contains “bot”
this is similar to your approach but with all that contains “bot” in one line. if i am correct