-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathremove-xmlrpc-pingback-ping.php
35 lines (32 loc) · 1.11 KB
/
remove-xmlrpc-pingback-ping.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
/**
* Remove XMLRPC Pingback Ping
*
* Prevent WordPress From Participating In Pingback Denial of Service Attacks
*
* @package Remove_XMLRPC_Pingback_Ping
* @author Brad Vincent <bradvin@gmail.com>
* @license GPL-2.0+
* @link http://wordpress.org/plugins/remove-xmlrpc-pingback-ping
* @copyright 2014 Brad Vincent
*
* @wordpress-plugin
* Plugin Name: Remove XMLRPC Pingback Ping
* Plugin URI: http://wordpress.org/plugins/remove-xmlrpc-pingback-ping
* Description: Prevent WordPress From Participating In Pingback Denial of Service Attacks
* Version: 1.0.0
* Author: Brad Vincent
* Author URI: http://fooplugins.com
* License: GPL-2.0+
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt
* GitHub Plugin URI: https://github.com/fooplugins/remove-xmlrpc-pingback-ping
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
add_filter( 'xmlrpc_methods', 'remove_xmlrpc_pingback_ping' );
function remove_xmlrpc_pingback_ping( $methods ) {
unset( $methods['pingback.ping'] );
return $methods;
}