In this post (5)
How the rocket_beacon path traversal works
WP Rocket (used across more than 5.5 million WordPress sites) ships a browser-side performance script that measures page elements and posts telemetry back to WordPress’s public AJAX handler at /wp-admin/admin-ajax.php with the action parameter set to rocket_beacon.
In versions 3.15 through 3.24.1, two optional optimization features — “LazyLoad for CSS background images” and “Self-host Google Fonts” (also referred to as “Host Fonts Locally”) — both process asset URLs supplied through that public beacon workflow. Neither feature is on by default, but both are common on performance-tuned sites.
Because versions prior to 3.24.2 failed to properly validate external URLs and path traversal sequences (../) in that flow (CWE-22, CVSS 9.8), an unauthenticated attacker can send a crafted request that makes the server download a file from an attacker-controlled host and write it outside the intended cache directory as an executable .php script.
Once the PHP file lands in a web-accessible directory, the attacker simply requests it over HTTP for remote code execution. WP Media shipped version 3.24.2 on November 19, 2026; manual probing began on November 25, and automated campaigns escalated on November 26.
Why commercial caching plugins break normal patching cadence
If you run one WordPress site, you notice when a paid plugin asks for a license key. If you run forty departmental, athletics, grant-funded, or agency WordPress sites built by outside vendors, commercial plugins routinely sit on expired keys.
WordPress core keeps updating. Free repository plugins keep updating. A commercial caching plugin with a lapsed license stays pinned at whatever 3.x build was installed last year — and nobody gets an error banner on the public site.
Campus/agency angle
WP Rocket is one of the first plugins agencies install before handoff, and departmental editors love turning on font-hosting or CSS lazy-loading toggles to chase PageSpeed scores. That means your fleet inventory probably does not match your procurement spreadsheet.
What to check in versions, logs, and wp-content
Patching to 3.24.2 (or turning off both toggles) stops the next exploit request, but it does not clean up a PHP webshell written before you patched. Before you mark a site done, check three things:
- Plugin inventory and settings: flag every WordPress site and multisite child running WP Rocket 3.15 through 3.24.1, and check whether LazyLoad for CSS background images or Self-host Google Fonts is enabled.
- Access logs and WAF logs: look for spikes or unusual POST requests to /wp-admin/admin-ajax.php referencing rocket_beacon, especially payloads containing ../ traversal sequences, bare IP URLs, nip.io domains, or temporary tunnel hostnames.
- Disk and user accounts: inspect wp-content/wp-rocket-config/, wp-content/uploads/, wp-content/cache/, and the wp-content/ root for unfamiliar or recently modified .php files (trackers have observed dropped files such as wp-media-*.php). If you find one, check for unauthorized WordPress admin users, rotate database passwords, and rotate WordPress salts.
Recommended action
If a site has an expired WP Rocket license and procurement cannot renew it today, either turn off both “LazyLoad for CSS background images” and “Self-host Google Fonts” in WP Rocket > Page Optimization > Image & Media (or Media on older builds), or deploy WP Media’s official WP-CLI helper plugin (wp plugin install ./wp-rocket-mitigate-cve-2026-125812.zip --activate) across your estate until 3.24.2+ is installed.
Where edge WAF rules fit (and why you start in count mode)
You cannot blindly block /wp-admin/admin-ajax.php at the edge — contact forms, theme widgets, logged-in editors, and legitimate WP Rocket beacons all post there. Blocking the path wholesale breaks real visitors.
Instead, an edge WAF rule needs to inspect the combination: POST requests to /wp-admin/admin-ajax.php carrying rocket_beacon alongside path traversal sequences (../) or external URLs that point off-origin.
In WAF Cybersecurity, every new rule starts in count mode first so you watch live traffic across your sites without risking legitimate beacons or form posts. After the count window, the Advisor reads the logged hits and explains in plain English whether the rule is safe to promote, needs a narrow allowlist, or should stay in count — and nothing blocks until a human clicks Promote.
One guardrail matters just as much as the rule itself: make sure your origin server only accepts HTTP/HTTPS from the edge, not directly from the public internet. Automated scanners routinely hit origin IPs directly to skip edge virtual patches.
Recommended action
Put any emergency rocket_beacon virtual-patch rule in count mode first, verify in the Advisor that zero legitimate admin-ajax.php traffic matches, click Promote, confirm direct origin access is blocked, and then finish updating WP Rocket to 3.24.2 or later and auditing wp-content/ for PHP drops.
Sources
Sources & advisories
Related reading on WAF Cybersecurity: scan your site, managed WAF for WordPress, emergency virtual patching, what WAF count mode is, hiding the origin IP behind a WAF, pricing, and start a 14-day trial.
Related reading
More from the blog
Weekly Briefing
Get our Monday morning security briefing
A quick 4-minute read on the Drupal, WordPress, and campus login issues being targeted this week, plus simple steps to stay ahead of them without breaking logins. Unsubscribe anytime.
Free Website Check
Curious how your site looks from the outside?
Check your firewall coverage, HTTPS setup, and exposed server details in 10 seconds. Nothing on your website changes and you don't need an account.