Forum Moderators: open
"GET /robots.txt HTTP/1.1" 403 3854 "-" "Mozilla/5.0 (compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm)" <if "-R '13.66.139.0/24' || -R '40.77.167.0/24' || -R '157.55.39.0/24' || -R '207.46.13.0/24' ">
SetEnvIfExpr "%{REMOTE_ADDR} =~ /(.+)/" ips=bing:$0
BrowserMatch bingbot bing bot=bing
Require env bing
</if>
Require env bingI don't understand this line. Doesn't the <If> envelope ensure that "bing" will always be defined?
<Directory "/srv/brisacu">
DirectoryIndex index.php
AllowOverride All
Include /etc/apache2/use-setenv.conf
</Directory> Require env favicon
Require expr %{REQUEST_URI} =~ m#/robots\.txt#
Require expr %{REQUEST_URI} =~ m#favicon\.ico|apple-touch-icon\.png|apple-touch-icon-precomposed\.png#i
<RequireAll>
Require method GET POST HEAD
<RequireNone>
Require env (several of these trapping bad things)
...
</RequireNone>
</RequireAll>
<if " ! %{HTTP_USER_AGENT} =~ m#((Apple|bing|Exa|Google|istella|Twitter)bot|(Mojeek|Seznam|Yandex)Bot|BingPreview|DuckDuck|facebook|Let's Encrypt|Qwantify|Vagabondo|Yeti)# && ! %{REQUEST_URI} =~ m#/robots\.txt#">
BrowserMatch .{0,10}([Bb]ot|crawl|rank|review|spider).{0,10} bot_is=bad_robot:$0
</if>
Require env bing