sample : GET /XMLRPC.php
XML-RPC works as an API.
XML-RPC is a mechanism for transferring calls and HTTP using XML.
In WordPress, it is performed through xmlrpc.php.
XML-RPC of xmlrpc.php is an RPC protocol,
and wordpress uses HTTP protocol to exchange XML-encoded data.
Typically, it is used to write new articles using a separate client program
without accessing WordPress, or to write trackbacks or pingbacks.
API : Application Program Interface
- gives mobile/desktop app developers the ability to talk to Wordpress site.
(also) write applications
it will be browsed as shown below when you connect.
When XML-RPC is enabled on a target site;
by exploiting xmlrpc.php to send vast numbers of pingbacks to a target site
2) Brute Force attack
xmlrpc.php system Multicall function affecting the most current version of Wordpress (3.5.1).
until a valid user response is acquired.
It will then selectively acquire and display the valid username and password to login.
[Solution]
1) If Apache :
- You can set up additional setting by using .htaccess and .conf file.
1; .htaccess
[root]# vi .htaccess
<files xmlrpc.php>
Order allow,deny
Deny from all
# ErrorDocument 403 /403.html
</files>
or
<Files xmlrpc.php>
Require all denied
# ErrorDocument 403 /403.html
</Files>
If you wanna use a html and if there is an annotated one in the file,
you can unpack an annotation and use it.
2; .conf
[root]# grep -i include httpd.conf | grep -v "#"
IncludeOptional conf.d/*.conf
You can create conf.d /.. .conf file and apply this setting
throughout various web source and virtualhost simultaneously.
[root]# conf.d
[root]# vi httpd-wordpress-security.conf
<Files xmlrpc.php>
Require all denied
#ErrorDocument 403 /403.html
</Files>
[root]# systemctl reload httpd
(When reloaded, several virtualhosts will receive this setting and be applied )
2) If Nginx :
move to ----------------> /etc/nginx/conf.d , and apply setting to each server block.
location = /xmlrpc.php {
deny all;
error_page 403 = /403.html;
}
when finished, reload nginx.
$ sudo systemctl reload nginx
[Reference]
Comments
Post a Comment