What to do2 steps
Update WordPress to 7.1.1.
On older branches, update to 7.0.5, 6.9.8, 6.8.9 or 6.7.8. The fix escapes the slug with
$.escapeSelectorand scopes the selector todiv.theme.Remove unused themes.
Treat PHP in inactive themes as an execution surface.
Are you affected?only if all are true
- A logged-in administrator has to open a crafted link; their nonce and install_themes capability are used without their knowledge.
- Core only force-installs an inactive theme from the WordPress.org catalog; PHP execution also needs a separately vulnerable theme (e.g. Mobile Repair Zone 2.5.4).
- The finder's proof of concept assumes that theme is not already installed.
Check your version
- WP-CLI
wp core version - Without WP-CLI, from the WordPress root
grep '^\$wp_version' wp-includes/version.php - Prompt for your own agent, read-onlyAm I affected by Click2Shell?
Read the prompt
Check whether the systems I am authorized to inspect are affected by Click2Shell. A jQuery selector injection on theme-install.php makes an admin's browser click Install on an attacker-chosen catalog theme; a vulnerable inactive theme then fetches and runs an attacker plugin. It is exploitable under these conditions: - A logged-in administrator has to open a crafted link; their nonce and install_themes capability are used without their knowledge. - Core only force-installs an inactive theme from the WordPress.org catalog; PHP execution also needs a separately vulnerable theme (e.g. Mobile Repair Zone 2.5.4). - The finder's proof of concept assumes that theme is not already installed. Fixed releases: - WordPress: 7.1.1 (branch 7.1), 7.0.5 (branch 7.0), 6.9.8 (branch 6.9), 6.8.9 (branch 6.8), 6.7.8 (branch 6.7) WordPress says 7.0, 6.9, 6.8 and 6.7 are affected by all 11 issues fixed in 7.1.1 and their releases above fix all of them. Releases for 6.6 and older fix 10 or fewer of the 11, and the notes do not say whether this one is among them. Commands the catalog lists to find the version or the setting (read each one before you run it): - WP-CLI: wp core version - Without WP-CLI, from the WordPress root: grep '^\$wp_version' wp-includes/version.php What the catalog says to do on an affected system (report these, do not carry them out): 1. Update WordPress to 7.1.1. 2. Remove unused themes. For each host, container image or application, report affected, not affected, fixed or unknown, with the evidence, and list anything you could not access. Work read-only: do not change configuration, restart services or send exploit input. More: https://wordpress.2shell.wtf/click2shell
Affected versions5 branches
| WordPress branch | Fixed in |
|---|---|
| 7.1 | 7.1.1 |
| 7.0 | 7.0.5 |
| 6.9 | 6.9.8 |
| 6.8 | 6.8.9 |
| 6.7 | 6.7.8 |
WordPress says 7.0, 6.9, 6.8 and 6.7 are affected by all 11 issues fixed in 7.1.1 and their releases above fix all of them. Releases for 6.6 and older fix 10 or fewer of the 11, and the notes do not say whether this one is among them.
Proof of concept1 public PoC
For testing systems you own or are authorized to test. A PoC repository can be fake or carry malware: read it before you run it.
- Open the PoC
Public PoC reproducing the pre-auth install-to-RCE chain
Timeline4 events
Reported to the vendor
Reported to WordPress by pwn.ai
Patched
WordPress 7.1.1 released
Disclosed
pwn.ai publishes the chain
Public PoC
Public PoC reproducing the pre-auth install-to-RCE chain
Sources5 links
Sources checked on . This page tells you how to check and what to install. It cannot tell you that you are safe.
6 changes since it was published
- Linked a public PoC for the chain.
- Remediation steps got short titles; no fact changed.
- Added the 7.0, 6.9, 6.8 and 6.7 backports listed in the WordPress 7.1.1 release notes.
- Added commands to check the installed version.
- WordPress 7.1.1 release notes link updated to their new address.
- Added exploit conditions from pwn.ai and the WordPress 7.1.1 release notes.
