Hackers are actively exploiting a critical vulnerability in the WP Rocket WordPress caching plugin, tracked as CVE-2026-125812, to execute arbitrary PHP code on vulnerable websites. The flaw affects WP Rocket versions older than 3.24.2 when certain performance features are enabled, and security researchers say automated attacks are already targeting sites worldwide.
WP Rocket is a paid WordPress plugin designed to improve website performance through page caching, CSS optimization, and image lazy loading. According to developer WP Media, it is used on 5.6 million sites by 394,000 customers.
WP Rocket vulnerability enables remote code execution
CVE-2026-125812 is caused by insufficient validation of data sent to a publicly accessible endpoint. An unauthenticated attacker can abuse the flaw to create and execute PHP code downloaded from an external source.
The vulnerability affects WP Rocket versions before 3.24.2 when either the “LazyLoad of CSS Background Images” or “Host Fonts Locally” option is enabled. Both features are disabled by default, but sites where either option has been activated may be vulnerable.
WP Media released a security fix on November 19. The company has also published an advisory urging users to upgrade to WP Rocket 3.24.2 or later.
Attacks escalated into an automated campaign
WordPress security firm Patchstack observed the first small-scale manual exploitation attempt on November 25 at 15:27 UTC. The activity escalated into a fully automated campaign the following day.
Researchers said the attacks target both vulnerable feature paths. Attackers deploy exploits when either option is enabled on a target site and may invoke both paths in the same request.
“An attacker may use both feature paths in a single request, causing either of the features enabled on the site to be invoked,” Patchstack said.
“They host their payloads on bare IP addresses, wildcard DNS names like nip.io, temporary trycloudflare.com tunnels, and other likely compromised WordPress sites.”
How to protect vulnerable sites
Administrators who cannot immediately install the latest version of WP Rocket should disable LazyLoad for CSS background images and locally hosted Google fonts. These settings can be found under WP Rocket > Page Optimization > Images & Media > Media.
WP Media has also shared a helper plugin for administrators managing multiple websites, allowing them to reduce the risk of abuse across their sites. Patchstack has additionally published attacker IP addresses that website owners can add to their blocklists.
Updating WP Rocket to a secure version will not remove files that attackers may have previously planted. Administrators whose sites ran a vulnerable version with either exploit path enabled should review server logs for suspicious requests and outbound connections, and check their websites for unauthorized files or changes.
Patchstack warns that a large-scale automated attack is already underway. Its security platform has blocked more than 25,000 malicious requests from multiple attackers.
Source: www.bleepingcomputer.com


