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

    37
    6
    8
    Oct 11, 2014
    Ratings:
    +7
    Local Time:
    12:31 PM
    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

    30,161
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    7:01 PM
    Nginx 1.13.x
    MariaDB 5.5