[WordPress] XML-RPC を無効にする
WordPress の XML-RPC を DoS 攻撃に悪用されることを知ったので、Nginx の設定を変更して XML-RPC を無効にしました。
/etc/nginx/conf.d/codenote.com.conf
server { # deny xmlrpc location = /xmlrpc.php { deny all; } |
XML-RPC を無効にすると Nginx の error.log には下記のようなログが出力されます。
2015/07/12 21:49:31 [error] 11605#0: *815037 access forbidden by rule, client: 123.123.123.123, server: codenote.net, request: "POST /xmlrpc.php HTTP/1.1", host: "codenote.net" |
以上です。
参考情報
- 踏み台にされたくないのでXML-RPCを無効にした | kwLog
- [WordPress] XML-RPC を使用する方法 | Sun Limited Mt.
- how to prevent access to xmlrpc.php with nginx.conf server block – DV Managed – (mt) Community Forums