CVE-2018-12895 affects WordPress through 4.9.6. The issue is caused by missing filename validation in the wp-includes/post.php wp_delete_attachment function. An attacker with a role that has file and post capabilities can leverage directory traversal via the wp-admin/post.php thumb parameter, which is ultimately passed to PHP's unlink function. By supplying a crafted path, the attacker can delete arbitrary files accessible to the WordPress process, including wp-config.php. Deletion of wp-config.php can then be abused to trigger the WordPress installation flow again, allowing the attacker to reinitialize the site and elevate privileges.
Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.
What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.
What an attacker gets, and what they’ve been doing with it.
If you can’t patch tonight, do this now.
Patch, then assume compromise.
1 valid exploit after Mallory filtered fakes, detection scripts, and README-only repos.
This repository contains a single Metasploit auxiliary module (modules/auxiliary/scanner/http/wp_arbitrary_file_deletion.rb) that exploits CVE-2018-12895, an arbitrary file deletion vulnerability in WordPress core. The exploit requires valid author-level credentials and interacts with the WordPress backend via HTTP requests to upload a dummy media file, manipulate its metadata, and trigger deletion of an attacker-specified file (default: wp-config.php). The module leverages several WordPress admin endpoints (/wp-admin/upload.php, /wp-admin/async-upload.php, /wp-admin/post.php, /wp-admin/admin-ajax.php) to perform the attack. Successful exploitation can lead to full site compromise or code execution. The code is written in Ruby and is designed to be run within the Metasploit framework.
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.
2 sources tracked across advisories and community write-ups. News coverage will land here when it surfaces.
No news coverage yet. Advisories and community discussion only.
Query your assets running an affected version, and investigate the blast radius.
Every observed campaign linking this CVE to a named adversary.
Malware families riding this exploit, with evidence and IOCs.
YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
Cross-references every affected SKU, including bundled OEM variants.
Community discussion across Reddit, Mastodon, and other social sources.