CVE-2026-5821: elemntor image optimizer – optimize images and convert to webp or avif External Control of File Name or Path
Vulnerability summary
CVE-2026-5821 is a high (CVSS 8.1) External Control of File Name or Path vulnerability in elemntor image optimizer – optimize images and convert to webp or avif. EPSS estimates a 0.66% chance of exploitation in the next 30 days, higher than 50.7% of scored vulnerabilities.
Timeline
- 02-07-2026PublishedVulnerability first disclosed.
- 02-07-2026Last modifiedVulnerability information updated.
Description
The Image Optimizer plugin for WordPress is vulnerable to arbitrary file deletion in versions up to and including 1.7.4. This is due to insufficient path validation in the Image_Backup::remove() function where backup file paths stored in post meta are used directly in file deletion operations without verifying they are within the uploads directory. The plugin stores backup file paths in the image_optimizer_metadata post meta field and trusts these paths completely when deleting backups on the delete_attachment hook. An authenticated attacker with Author-level access can edit the image_optimizer_metadata post meta on their own attachments via WordPress's Custom Fields interface, injecting arbitrary absolute file paths into the backups array. When the attacker subsequently deletes the attachment, the plugin calls File_System::delete() on each path without validation. This makes it possible for authenticated attackers, with Author-level access and above, to delete arbitrary files on the server within the web server's filesystem permissions, potentially leading to denial of service, data loss, or security degradation.
CVSS metrics
3 scores · 3 sources · 1 version- NVDNIST8.1HighCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
- wordfenceSource8.1HighCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
EPSS trend
Probability
0.66%
Chance of exploitation in the next 30 days
Percentile
51%
Versus all other CVEs
30-day change
0.00 pp
From 0.66% on 20-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Elemntor1 product
Wordpress1 product
- image-optimization≤ 1.7.4 (fixed in 1.7.5)
2 vendors · 2 products