16 min to read
WP Rocket CVE-2026-125812: Hunting rocket_beacon RCE Attacks on WordPress
A cache plugin on 5.5 million sites is being used to plant PHP web shells. Patch, then go looking for what was left behind.
Caching plugins are usually the boring part of a WordPress stack, the thing you install once to make the store load faster and then forget about. This week one of them became a way in. CVE-2026-125812 in WP Rocket, a premium caching plugin that its vendor says runs on more than 5.5 million WordPress sites, lets an unauthenticated attacker make the site download a file from a server the attacker controls, save it as PHP, and run it. Patchstack rates it CVSS 9.8. It is being exploited now.
The fix (version 3.24.2) shipped on 19 November 2026. Patchstack recorded the first exploitation attempt on 25 November, six days later, and blocked tens of thousands of attempts on 26 November alone. As Patchstack puts it: “The update stops new attacks, but it does not remove files an attacker already planted.”
So this is not a “please update” post. It is a practitioner’s guide to the part that patching does not cover: working out whether a site was exposed, hunting through web logs for the attack, sweeping the file system for planted shells, and cleaning up without making things worse.
TL;DR / Key takeaways
- CVE-2026-125812 is an unauthenticated RCE (CVSS 9.8) in WP Rocket’s page-measurement “beacon”, reached through
POST /wp-admin/admin-ajax.phpwithaction=rocket_beacon. Fixed in 3.24.2 (19 Nov 2026); 3.24.3 is also out.- Exposure needs one of two optional features: LazyLoad for CSS background images or Host Fonts Locally (self-host Google Fonts). Both are off by default but common on speed-tuned sites, WooCommerce stores included.
- Exploited since 25 Nov 2026, now automated. Several unrelated operators; payloads hosted on bare IPs,
nip.ionames andtrycloudflare.comtunnels.- Hunt for:
rocket_beaconPOSTs from clients that never loaded a page, outbound fetches from the web server to odd hosts, andwp-media-*.phpfiles inwp-content/,wp-content/uploads/andwp-content/wp-rocket-config/, plus a mu-plugins loader and rogue admin accounts.- Patching does not clean up. If you ran a vulnerable version with either feature on, treat the site as possibly compromised until you have checked.
Timeline
| Date (2026) | Event |
|---|---|
| 19 Nov | WP Rocket 3.24.2 released. Changelog security note: “Improve validation of cached CSS, font and preconnect files.” |
| By ~23 Nov | Patchstack’s virtual-patch rule goes live, more than two days before the first attack |
| 25 Nov, 15:27 UTC | First exploitation attempt recorded by Patchstack: manual, a handful of sites, encoded retries after blocks |
| 26 Nov | Automated campaigns; tens of thousands of blocked attempts |
| 26 Nov | WP Rocket 3.24.3 released |
| 27 Nov | Patchstack publishes its analysis and indicators |
| 1 Dec | SecurityWeek and The Hacker News report; Wordfence says it blocked 135 attacks in the prior 24 hours |
How the attack works (conceptually)
WP Rocket ships a small script that runs in visitors’ browsers, measures each page and reports what it found back to the server through a public AJAX endpoint. The plugin then uses the reported URLs to optimise the page: for example, fetching CSS background images or Google Fonts and caching local copies in the web root.
According to Patchstack, the plugin “does not validate them strictly enough.” A forged report can point WP Rocket at an attacker-controlled server, and the content it downloads ends up saved as a .php file inside the site, where the attacker can then request it and run code as the web server user. Rescana classifies the bug as path traversal (CWE-22). Because the beacon is meant to receive data from anonymous visitors, no login is required.
Two details matter for defenders:
- The vulnerable path only runs when one of the two features is enabled. Some attackers send requests that cover both paths at once so whichever feature is on will fire.
- The attack causes the server to make an outbound request. That is a detection opportunity many WordPress hosts never use.
We are deliberately not publishing request bodies or payload structure; the indicators below are enough to hunt with.
Am I affected?
You were exposed to exploitation if all of the following were true at any point since about 19 November:
- WP Rocket was installed and active at a version below 3.24.2. Patchstack describes every version before 3.24.2 as affected; WP Rocket’s own statement, as reported by SecurityWeek, names 3.15 through 3.24.1.
- LazyLoad for CSS background images or Host Fonts Locally was turned on.
- The site was reachable from the internet (almost always yes).
If you manage many sites and do not know which had those features enabled, follow Imunify360’s advice and treat every WP Rocket site as exposed.
Check the installed version without loading WordPress (important later, see the cleanup section):
~|#| Run from the site root as the site's own user, not root
grep ~|-|m1 ~|-|i "Version:" wp~|-|content/plugins/wp~|-|rocket/wp~|-|rocket.php
~|#| Fleet~|-|wide on a shared host (adjust the base path to your layout)
find /var/www /home ~|-|path '*/wp~|-|content/plugins/wp~|-|rocket/wp~|-|rocket.php' 2>/dev/null \
| while read f; do printf '%s\t%s\n' "$(grep ~|-|m1 ~|-|i 'Version:' "$f" | awk '{print $NF}')" "$f"; done \
| sort ~|-|V
Anything printed below 3.24.2 needs action. Then check the two settings in WP Rocket’s dashboard for each site, and write down whether they were on, because that decides how deep your investigation needs to go.
Step 1: Hunt the web logs
The attack arrives as a POST to admin-ajax.php. Standard access logs (Apache combined, nginx default) do not record POST bodies, so you usually cannot see action=rocket_beacon in them directly. You can still do a lot with what you have.
Quick triage on the server
~|#| Who is POSTing to admin~|-|ajax.php, and how often? (nginx/Apache combined format)
zgrep ~|-|h 'POST /wp~|-|admin/admin~|-|ajax.php' /var/log/nginx/access.log* \
| awk '{print $1}' | sort | uniq ~|-|c | sort ~|-|rn | head ~|-|30
~|#| Any request where the action is visible in the query string (some clients send it there)
zgrep ~|-|h 'rocket_beacon' /var/log/nginx/access.log* /var/log/apache2/*access* 2>/dev/null | head
~|#| Hits from the source IPs Patchstack published (25~|-|27 Nov activity)
zgrep ~|-|hE '^(103\.235\.74\.7[12]|157\.245\.122\.230|152\.89\.170\.194|180\.232\.236\.101|201\.79\.120\.217|112\.78\.154\.32|167\.71\.75\.155|43\.163\.8\.253|51\.79\.199\.209) ' \
/var/log/nginx/access.log* 2>/dev/null
Those ten addresses are the most active sources Patchstack saw, together roughly half of its blocked attempts. Treat them as leads, not a blocklist: operators are rotating residential proxies, so absence of these IPs proves nothing.
The “never loaded the page” signal
Patchstack’s best behavioural indicator is a rocket_beacon request from a client that never loaded the page it is reporting on. A real browser fetches an HTML page, runs the script, then posts the beacon. A scanner just posts. You can approximate this with access logs alone: find IPs that POST to admin-ajax.php but never issued a normal GET for a page.
Splunk (web access logs):
index~|=|web sourcetype IN (access_combined, nginx:plus:kv) earliest~|=|~|-|14d
| eval is_ajax_post~|=|if(method~|=|"POST" AND like(uri_path,"%/wp~|-|admin/admin~|-|ajax.php"),1,0)
| eval is_page_get~|=|if(method~|=|"GET" AND NOT match(uri_path,"\.(css|js|png|jpe?g|gif|svg|webp|woff2?|ico)$") AND NOT like(uri_path,"/wp~|-|admin/%"),1,0)
| stats sum(is_ajax_post) AS ajax_posts sum(is_page_get) AS page_gets values(useragent) AS ua dc(host) AS sites BY clientip
| where ajax_posts>0 AND page_gets~|=|0
| sort ~|-| ajax_posts
Microsoft Sentinel / KQL (Azure Front Door or App Gateway logs; adapt the table to wherever your web logs land):
AzureDiagnostics
| where TimeGenerated > ago(14d)
| where Category in ("FrontDoorAccessLog", "ApplicationGatewayAccessLog")
| extend ip ~|=| coalesce(clientIp_s, clientIP_s), uri ~|=| requestUri_s, m ~|=| httpMethod_s
| summarize ajaxPosts ~|=| countif(m ~|=|~|=| "POST" and uri has "/wp~|-|admin/admin~|-|ajax.php"),
pageGets ~|=| countif(m ~|=|~|=| "GET" and not(uri matches regex @"\.(css|js|png|jpe?g|gif|svg|webp|woff2?|ico)(\?|$)") and not(uri has "/wp~|-|admin/"))
by ip
| where ajaxPosts > 0 and pageGets ~|=|~|=| 0
| order by ajaxPosts desc
Expect some noise (uptime monitors, headless integrations, other plugins’ AJAX calls). What you are looking for is a burst starting 25 November or later, often hitting several of your sites from the same IP.
Make the beacon visible from now on
If you run a WAF or ModSecurity, log (or block) requests to admin-ajax.php whose body contains action=rocket_beacon and an absolute URL in the reported data. Patchstack notes attackers report full URLs where WP Rocket expects bare domains, which is a useful rule condition. Imunify360 also warns that a WAF in “DetectionOnly” mode logs but does not block: check that yours is actually enforcing. A WAF rule is a stopgap, not a substitute for 3.24.2.
Step 2: Look for the outbound fetch
Exploitation makes your web server download the payload. Most WordPress servers have no reason to make outbound requests to *.nip.io, *.trycloudflare.com or bare IP addresses, so this is a high-signal hunt if you have DNS, proxy or firewall egress logs.
Sigma rule (DNS query logs):
title: Web Server Resolving Tunnel or Wildcard~|-|DNS Hosts (WP Rocket CVE~|-|2026~|-|125812 Payload Fetch)
id: 6a0f4f3e~|-|2b6c~|-|4b8f~|-|9b3e~|-|125812c0de01
status: experimental
description: >
Detects a web server resolving nip.io or trycloudflare.com names, which Patchstack
reported as payload hosting for WP Rocket CVE~|-|2026~|-|125812 exploitation.
references:
~|-| https://patchstack.com/articles/critical~|-|wp~|-|rocket~|-|rce~|-|cve~|-|2026~|-|125812~|-|under~|-|active~|-|attack/
logsource:
category: dns
detection:
selection:
query|endswith:
~|-| '.nip.io'
~|-| '.trycloudflare.com'
condition: selection ~|#| scope the log source to your WordPress web servers
falsepositives:
~|-| Developers using these services for legitimate testing from the same hosts
level: high
tags:
~|-| attack.initial_access
~|-| attack.t1190
~|-| attack.command_and_control
~|-| attack.t1105
On a single Linux host without central logging, check what PHP-FPM or the web server user is talking to right now, and look at firewall logs for connections initiated by the web server around the time of suspicious POSTs:
ss ~|-|tnp state established | grep ~|-|Ei 'php~|-|fpm|php|httpd|apache2|nginx|lsphp'
Step 3: Sweep the file system
This is where most compromises will actually be confirmed. Patchstack and Imunify360 point to the same artefacts:
- PHP files named like
wp-media-<8 hex characters>.phpinwp-content/,wp-content/uploads/orwp-content/wp-rocket-config/. The first file is often a small probe or a web shell that runs commands it is sent. - A file in
wp-content/mu-plugins/that re-creates the other files when you delete them. - A new administrator account.
cd /path/to/site ~|#| as the site user
~|#| 1. Known filename pattern
find wp~|-|content ~|-|type f ~|-|regextype posix~|-|extended ~|-|regex '.*/wp~|-|media~|-|[0~|-|9a~|-|f]{8}\.php$' ~|-|ls
~|#| 2. Any PHP in places that should never contain PHP
find wp~|-|content/uploads wp~|-|content/wp~|-|rocket~|-|config wp~|-|content/cache ~|-|type f ~|-|name '*.php' ~|-|ls 2>/dev/null
~|#| 3. PHP created or changed since the patch window opened
find wp~|-|content ~|-|type f ~|-|name '*.php' ~|-|newermt '2026~|-|11~|-|19' ~|-|not ~|-|path '*/plugins/*/vendor/*' ~|-|ls
~|#| 4. Every must~|-|use plugin: there are usually none, or a few you can name
ls ~|-|la wp~|-|content/mu~|-|plugins/ 2>/dev/null
wp-content/wp-rocket-config/ normally holds WP Rocket’s own per-site config files, so do not panic at every PHP file there; compare against a clean install or another site, and look for files that do not match the plugin’s naming. In uploads/, there should be essentially no PHP at all.
Open any suspicious file in a text viewer, not a browser. Typical tells are eval, assert, base64_decode, gzinflate, str_rot13, system, shell_exec, passthru, or references to $_POST/$_REQUEST/$_COOKIE feeding straight into those. Keep copies (with timestamps preserved: cp -p) before you delete anything, so you can work out when the site was first hit.
Check for rogue admins
~|-|~|-| Default table prefix wp_; change if yours differs
SELECT u.ID, u.user_login, u.user_email, u.user_registered
FROM wp_users u
JOIN wp_usermeta m ON m.user_id ~|=| u.ID
WHERE m.meta_key ~|=| 'wp_capabilities'
AND m.meta_value LIKE '%administrator%'
ORDER BY u.user_registered DESC;
Anything registered on or after 25 November that nobody recognises is a strong sign of compromise.
Step 4: Clean up safely
Imunify360’s guidance includes one point many admins get wrong: do not run WP-CLI as root on an infected site. WP-CLI loads the site’s code, including the attacker’s mu-plugins loader, so you would be running their code with root privileges. Work as the site user and with plain file tools until the loader is gone.
A sane order of operations:
- Snapshot first. Copy the site files and database, and preserve web, PHP-FPM and WAF logs from at least 18 November onward.
- Remove the persistence loader in
mu-plugins/before the payload files, otherwise it may recreate them. - Delete the planted PHP files you found, then re-run the sweep to confirm they stay gone.
- Update WP Rocket to 3.24.2 or later (3.24.3 is current). If you cannot update today, for example on an expired licence, turn off both LazyLoad for CSS background images and Host Fonts Locally.
- Remove unknown admin accounts, then rotate the salts in
wp-config.php(this logs everyone out) and change the database password. - Rotate everything the web server could read: payment gateway API keys, SMTP credentials, object-storage keys, any secrets in
wp-config.phpor.env. On a WooCommerce store, check checkout pages and theme files for injected JavaScript too; card skimming is the obvious next step for anyone holding a shell on a store. - If in doubt, restore from a backup taken before 25 November, then update and harden before bringing it back online.
Prioritised checklist
Immediately (today)
- Inventory every site running WP Rocket and its version.
- Update to 3.24.2+ everywhere; where you cannot, disable both affected features.
- Run the file sweep and rogue-admin query on every site that ran a vulnerable version.
This week
- Run the log hunts back to 19 November; review hits from Patchstack’s IP list and “POST-only” clients.
- Hunt egress logs for
nip.io,trycloudflare.comand bare-IP fetches from web servers. - Clean or restore any compromised site; rotate salts, DB passwords and API keys.
- Confirm your WAF is in blocking mode, not detection-only.
Longer term
- Block PHP execution in
wp-content/uploads/at the web server level. - Restrict outbound traffic from web servers to the destinations they genuinely need (payment gateways, update servers, email).
- Add file-integrity monitoring on
wp-content/and alert on new PHP files and new mu-plugins. - Track premium plugins in your patching process: they do not always auto-update, and licence lapses silently freeze them.
A minimal nginx snippet for the uploads rule:
location ~* ^/wp~|-|content/uploads/.*\.php$ {
deny all;
}
Note this alone would not stop every variant of this attack, because Patchstack lists other write locations too; it is one layer, not the fix.
OffensioX perspective
Two patterns stand out. First, the patch-to-exploit gap was six days, and the bug sat in a premium plugin. Premium plugins often update through licence-gated channels rather than WordPress.org, and when a licence lapses the site simply stops receiving fixes. In our assessments across Pakistan and the wider region we regularly find stores whose plugin licences expired years ago, quietly running versions with known holes. Second, this is a “performance feature becomes attack surface” bug: two optional speed toggles turned an anonymous analytics endpoint into a file-write primitive. Anything that makes your server fetch and store remote content on behalf of an unauthenticated request deserves the same scrutiny as a file-upload form. The defences that would have contained this, egress filtering and no-PHP-in-uploads, are old, cheap and still rarely deployed on WordPress hosting.
If you would like a second pair of eyes, OffensioX runs WordPress and e-commerce penetration tests and compromise assessments, including the kind of file, log and egress review described above.
References
- Patchstack: Critical WP Rocket RCE (CVE-2026-125812) Under Active Attack
- WP Rocket changelog (3.24.2, 19 November 2026; 3.24.3, 26 November 2026)
- SecurityWeek: Critical WordPress WP Rocket Vulnerability Exploited Days After Patching
- The Hacker News: Hackers Target Critical WP Rocket Flaw Allowing Unauthenticated Remote Code Execution
- Imunify360: Exploited WP Rocket flaw: update, check for planted files
- BleepingComputer: Hackers exploit critical WordPress WP Rocket flaw to breach sites
- Rescana: WP Rocket CVE-2026-125812 Unauthenticated RCE Under Active Attack