kingdraco

Hosting Provider Filters

Aug 22nd, 2016
393
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.76 KB | None | 0 0
  1. <?php
  2. /**
  3.  * Begin modifications requested by hosting providers.
  4.  *
  5.  * You can safely remove this file to return your installation
  6.  * to a vanilla state.
  7.  */
  8. /**
  9.  * The following modification was requested by BlueHost, 7/9/2014
  10.  * due to a high level of abuse and DDOS usage.
  11.  *
  12.  * To re-enable xmlrpc pingbacks, you can remove the code below this comment.
  13.  *
  14.  * For more info, see here:
  15.  * http://blog.spiderlabs.com/2014/03/wordpress-xml-rpc-pingback-vulnerability-analysis.html
  16.  */
  17. if (function_exists('add_filter')) {
  18.     function mojo_alter_hosting_provider_filters($methods) {
  19.         if (isset($methods['pingback.ping'])) {
  20.             unset($methods['pingback.ping']);
  21.         }
  22.         return $methods;
  23.     }
  24.     add_filter('xmlrpc_methods', 'mojo_alter_hosting_provider_filters');
  25. }
Advertisement
Add Comment
Please, Sign In to add comment