CVE-2026-124969: Optimole arbitrary file deletion vulnerability
published 2026-11-14 · updated 2026-11-16
- Affected versions
- 4.2.19 and older
- Fixed in
- 4.2.20 *
- Latest version
- 4.2.21
- Active installs
- 200,000+
- Type
- Arbitrary file deletion
* The source does not name a fixed version; this is the first wordpress.org release after the last affected version.
What to do now
- Update Optimole to 4.2.20 or newer (the latest is 4.2.21): Dashboard → Updates, or Plugins → “update now”.
- If you cannot update right away, deactivate it until you can.
- Turn on auto-updates for it: Plugins → “Enable auto-updates” on its row.
- Not sure which version you run? Check your version against every known Optimole issue.
With WP-CLI:
wp plugin get optimole-wp --field=version. - If you ran an affected version and something looks off (new admin users, spam pages, redirects), run the free scan below.
Is your site exposed to CVE-2026-124969?
- Are you on an affected version? Compare your Optimole version with every known issue on record. Check my version
- Has your site already been hit? The free scan looks for signs of a hack from the outside. It cannot see plugin versions or test for this bug.
- Already hacked? Flat $499 for a standard cleanup. Nothing is charged until we have looked at your site and confirmed the job. See how cleanup works
What an attacker needs
- Access: None. No account or login is needed.
- Interaction: It also needs someone on the site (often an admin) to click a link, open a page or submit a form the attacker prepared.
Technical details
Weakness
Arbitrary file deletion
A file path that an attacker can influence reaches a delete operation without being properly restricted.
Deleting key files can take a site down. On WordPress, removing wp-config.php can open the way to a full takeover.
General description of this issue type. The advisory below covers this bug.
CVSS 3.1 breakdown
- Attack vector
- Network (remote)
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality impact
- None
- Integrity impact
- Low
- Availability impact
- High
CVSS vector (scored by Wordfence): CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:H
The advisory
The Optimole – Optimize Images | Convert WebP & AVIF | CDN & Lazy Load | Image Optimization plugin for WordPress is vulnerable to arbitrary file deletion due to insufficient file path validation in the replace_urls_in_value function in all versions up to, and including, 4.2.19. This makes it possible for unauthenticated attackers to delete arbitrary files on the server, which can easily lead to remote code execution when the right file is deleted (such as wp-config.php). Successful exploitation requires PEAR's Archive_Tar library to be present and loadable on the host (common in official WordPress Docker images and many PHP distributions), and an administrator must subsequently use the plugin's Rename control on any attachment after the attacker has staged a malicious payload in a comment. Successful exploitation additionally requires an action by an administrator — the attacker cannot trigger the vulnerability on their own.
References
- NVD CVE-2026-124969 nvd.nist.gov
- Wordfence advisory www.wordfence.com
- Plugin source plugins.trac.wordpress.org
How Laskyr cleans up a site hacked through Optimole
We confirm the job by email before any payment, remove the infection, harden the site and report how they got in. A standard cleanup is $499 with a 30-day reinfection guarantee. Bigger jobs get a written estimate first, and nothing more is charged unless you approve it. Full details.
Related
Ran an affected version? Run the free scan for signs of a hack.
Where this data comes from
- CVE record, score and references: NIST National Vulnerability Database (NVD), checked 2026-11-29. This product uses data from the NVD API but is not endorsed or certified by the NVD.
- Versions and install counts: wordpress.org/plugins/optimole-wp (Plugins API), fetched 2026-11-29.
- Everything outside the quoted description is our plain-English reading of the record and the plugin's release history. The CWE is the standard one for this issue type. Spot an error? Email Daniel.