In my wordpress site virus script added in footer on wp_footer action.

I try many techniques, but i cant find virus hook location.

Is there any wp action/filter, that hook after each action /filter hooked including hooked output data?

I mean, if some one hook

add_action("wp_footer","abc");
function abc(){
  echo "inside content";
}

I want this.

output: inside content
function ABC, file : foo.php

I am using this code, that only return list of hooks.

add_action('wp', function(){ 
      echo '<pre>';
      print_r($GLOBALS['wp_filter']); 
      echo '</pre>';
      exit; 
});
  • The plugin Debug Objects list you all functions, that are fired on a hook. Maybe this helps you. – bueltge Apr 21 '17 at 8:28

Check also if it was added by JavaScript. To list all the functions hooked wp_footer, this might help:

global $wp_filter;
var_dump( $wp_filter['wp_footer'] );

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.