1. Nginx 의 conf 수정

server {

location ~* /wp-includes/.*.php$ {
deny all;
access_log off;
log_not_found off;
}

location ~* /wp-content/.*.php$ {
deny all;
access_log off;
log_not_found off;
}

location ~* /(?:uploads|files)/.*.php$ {
deny all;
access_log off;
log_not_found off;
}

location ~* /modules/.*.php$ {
deny all;
access_log off;
log_not_found off;
}

location ~* /skins/.*.php$ {
deny all;
access_log off;
log_not_found off;
}

location = /xmlrpc.php {
deny all;
access_log off;
log_not_found off;
}
}

2. WordPress 플러그인 설치

Disable XML-RPC 설치

3. 참고 사이트

kinsta.com/blog/wordpress-xml-rpc/

ko.wordpress.org/plugins/disable-xml-rpc/

bjornjohansen.no/block-access-to-php-files-with-nginx/