Want to subscribe to topics you're interested in?
Become a Member

Nginx Limiting xml-rpc in wordpress to certain ips

Discussion in 'Nginx, PHP-FPM & MariaDB MySQL' started by amin, Dec 28, 2014.

  1. amin

    amin Member

    38
    6
    8
    Oct 11, 2014
    Ratings:
    +7
    Local Time:
    6:57 AM
    Katest
    Latest
    Hi,
    To avoid the xml-rpc attack, I wanted to limit xmlrpc.php file in my wordpress, I added this command to /usr/local/nginx/conf/conf.d/mydomain.com.conf :
    location ~ ^(xmlrpc\.php) { allow my ip range/18; deny all; }

    It is not working and I still can access to this file from any ip! Any idea?

     
  2. eva2000

    eva2000 Administrator Staff Member

    54,098
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    1:27 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+