[WordPress] Avoid xmlrpc attack

  • add below code in the functions.php in your themes.
add_filter('xmlrpc_enabled', '__return_false');
  • edit .htaccess
#protect xmlrpc
<Files xmlrpc.php>
Order Deny,Allow
Deny from all
</Files>
  • delete the xmlrpc.php file

Ref. 解決WordPress被利用xmlrpc.php文件攻擊導致內存超負荷

This entry was posted in WordPress. Bookmark the permalink.