そして、これは偽者をブロックする方法です (誰かが偽者をブロックする方法を検索しているときにこのページを見つけた場合に備えて)
Apache でそのトリックをブロックします。
# Block fake google when it's not coming from their IP range's
# (A fake googlebot) [F] => Failure
RewriteCond %{HTTP:X-FORWARDED-FOR} !^66\.249\.(6[4-9]|[78][0-9]|9[0-5])\.
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/5\.0\ \(compatible;\ Googlebot/2\.[01];\ \+http://www\.google\.com/bot\.html\)$ [NC]
RewriteRule .* - [F,L]
または完全を期すためにnginxのブロック
map_hash_bucket_size 1024;
map_hash_max_size 102400;
map $http_user_agent $is_bot {
default 0;
~(crawl|Googlebot|Slurp|spider|bingbot|tracker|click|parser|spider)$ 1;
}
geo $not_google {
default 1;
66.0.0.0/8 0;
}
map $http_user_agent $bots {
default 0;
~(?i)googlebot $not_google;
}