• Resolved David

    (@dkomando)


    Hi,
    I’m looking for a way to start/initiate a Wordfence scan from the WordPress CLI.

    Reason/Use Case:
    I recently had to help someone who’s dedicated server was infected with malware and had to clean all their sites on that server. The malware or hacker that got in disabled Wordfence as well as a few other security plugins. In which I had to completely remove and reinstall Wordfence. I then had to setup and run a scan manually for every site on that server. So, I’m basically looking for a way to automate this through a script using WP-CLI if this is to happen again in the future.

    I can write a simple extended WP-CLI Wordfence plugin to do this, but I’m looking for the PHP command(s) to have it run. I’ve done some searching and cannot find a method other than possibly ‘wfScanEngine::startScan()’. Does any documentation on starting a scan from PHP itself currently exist? Having access to a do_action() method would be amazing. So I’m really just looking to be pointed in the right direction.

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Starting a scan from WP-CLI’ is closed to new replies.