よろしくない被リンクサイトを拒否しようと思い .htaccess に書いたらめっちゃエラーでした。
<RequireAll> Require all granted Require not host japaneseclass.jp Require not ip 104.21.22.123 </RequireAll>
アクセスログ。はあ。
[日付] [authz_host:error] [pid 14834:tid 140405955364608] [client 129.204.44.57:55732] AH01753: access check of 'japaneseclass.jp' to /index.html failed, reason: unable to get the remote host name
こういったエラーもたくさんありました。何なんだろうこのリファラーは。
[日付][authz_host:error] [pid 25072:tid 140406123218688] [client 58.3.95.115:53538]
AH01753: access check of 'japaneseclass.jp' to /wp-content/uploads/xx.png failed,
reason: unable to get the remote host name,
referer: https://fuutou-sozai.blogspot.com/
ちなみに「Require local」などと書いてもエラー。で、試しにここを見てこのように書き直したら撃沈。
Require not forward-dns japaneseclass.jp
Internal Server Error HTTP 500 [core:alert]
[core:alert] [pid 2121:tid 140406853383936] [client 66.249.68.52:39254] /public_html/.htaccess: Unknown Authz provider: forward-dns
次のように書いたら正解でした。単純なのね…
# siteblock host deny from .japaneseclass.jp
以前の書き方はこちら。今は「order allow,deny allow from all」省略しても良いみたいですね。
order allow,deny allow from all deny from 111.222.111.222 deny from 123.12.1. deny from example.ne.jp