Skip to content
Noroxi
NVD / CVE Program· CNA mitre

CVE-2018-12895: WordPress through 4.9.6 allows Author users to execute arbitrary code by leveraging directory traversal in the wp-admin/post.php thumb…

HighCVSS 8.8 · v3.1—Weaponized Fix available

Noroxi assessment

Priority: Plan (action score 54/100)

  • A ready-made attack module is public (Metasploit); exploiting it takes no special expertise.
  • Public proof-of-concept code exists (GitHub); there is no record of exploitation in the wild.
  • Probability of exploitation in the next 30 days: 62.1% (FIRST EPSS); higher than 99.1% of all records.
  • Anyone who can reach it over the internet can trigger it. A low-privileged account is enough. No user action is required. No special conditions are required; it is repeatable.
  • Fixed version: wordpress (Debian:12) 4.9.7+dfsg1-1; wordpress (Debian:8) 4.1+dfsg-1+deb8u18; wordpress (Debian:9) 4.7.5+dfsg-2+deb9u4.

Add it to your regular patch cycle. Upgrade to wordpress (Debian:12) 4.9.7+dfsg1-1; wordpress (Debian:8) 4.1+dfsg-1+deb8u18; wordpress (Debian:9) 4.7.5+dfsg-2+deb9u4 or later.

Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it

Primary sources: NVD · CVE.org · FIRST EPSS

WordPress through 4.9.6 allows Author users to execute arbitrary code by leveraging directory traversal in the wp-admin/post.php thumb parameter, which is passed to the PHP unlink function and can delete the wp-config.php file. This is related to missing filename validation in the wp-includes/post.php wp_delete_attachment function. The attacker must have capabilities for files and posts that are normally available only to the Author, Editor, and Administrator roles. The attack methodology is to delete wp-config.php and then launch a new installation process to increase the attacker's privileges.

Published
Jun 26, 2018
Updated
Jun 16, 2026
EPSS
62.1% · 99th percentile

Report tools

JSON

Action score

54

Plan

Add it to your regular patch cycle.

CVSS
35 / 40 · 8.8 / 10
CISA KEV
0 / 30 · Not listed
EPSS
19 / 30 · 62.1%

Is WordPress on your site?

WP Lens reads your site's plugin, theme and WordPress versions from the outside and matches them to known vulnerabilities. Works without an account.

Follow CVE-2018-12895

Is WordPress on your site?

When you'll hear from us

  • when it enters CISA KEV
  • when exploit code appears or is weaponized
  • when the record is updated (including a fixed version)
  • when EPSS rises 20 points in a week

One daily email digest (06:00 UTC); connect a webhook for KEV listings and weaponized exploits every 10 minutes on paid plans, on the hour on the free plan.

Your free account also gets you

  • CVE alerts: add the products and versions you run, get the new CVEs that affect them
  • Uptime monitoring: 1 site, instant email when it goes down
  • Add your domain: subdomains and takeover risk scanned every week (1 domain)
  • 10 scans an hour on the security tools, at most 30 a day (3 a day without an account), an API key and MCP
  • All your scans in one panel: findings, what changed in the last scan, a report per domain or per client (PDF, share link)
All free tools
If any of these changes, we'll tell you in the daily email digest.
Is your version affected? Check it

Noroxi analysis

What does it mean in your environment?

The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.

We use this product, ask for help

Affected systems

Is your version affected?

Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.

VendorProduct
wordpresswordpress
debiandebian linux

Using wordpress? Add it to your stack and be the first to know about CVEs like this one. (WordPress)

Watch new CVEs for wordpress

When you'll hear from us

  • when a new CVE affecting this product is published
  • when a record in your stack enters KEV or is weaponized

One daily email digest (06:00 UTC); connect a webhook for KEV listings and weaponized exploits every 10 minutes on paid plans, on the hour on the free plan.

Your free account also gets you

  • CVE alerts: add the products and versions you run, get the new CVEs that affect them
  • Uptime monitoring: 1 site, instant email when it goes down
  • Add your domain: subdomains and takeover risk scanned every week (1 domain)
  • 10 scans an hour on the security tools, at most 30 a day (3 a day without an account), an API key and MCP
  • All your scans in one panel: findings, what changed in the last scan, a report per domain or per client (PDF, share link)
All free tools

Sign up with email · Have an account? Sign in

Free account, no card. Unfollow any time.

Affected versions

NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.

  • wordpress wordpressbefore 4.9.7

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
Debian:12wordpressbefore 4.9.7+dfsg1-14.9.7+dfsg1-1
Debian:8wordpressbefore 4.1+dfsg-1+deb8u184.1+dfsg-1+deb8u18
Debian:9wordpressbefore 4.7.5+dfsg-2+deb9u44.7.5+dfsg-2+deb9u4

Other highest-scoring records for the same primary product.

  • CVE-2026-87902An unauthenticated attacker can make `get_page_template()` page-template resolution include a chosen readable local `.php` file outside the…KEV
    91Now
  • CVE-2026-63030WordPress < 7.0.2 - REST API batch-route confusion and SQL injection issue leading to Remote Code ExecutionKEV
    72This week
  • CVE-2026-119977WordPress Core 4.7.0 - 7.1.3 - Unauthenticated Upgrade-Window Staged-Installer Remote Code ExecutionKEV
    62This week

Published before and after this one in the same product

  • ← EarlierCVE-2018-10101Apr 16, 2018 · Before WordPress 4.9.5, the URL validator assumed URLs with the hostname localhost were on the same host as the WordPress server.
    25Monitor
  • ← EarlierCVE-2018-10102Apr 16, 2018 · Before WordPress 4.9.5, the version string was not escaped in the get_the_generator function, and could lead to XSS in a generator tag.
    25Monitor
  • Later →CVE-2018-14028Aug 10, 2018 · In WordPress 4.9.7, plugins uploaded via the admin area are not verified as being ZIP files.
    33Monitor

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
debian:wordpress4.9.7+dfsg1-1 · Debian:12Package registry (OSV)

Exploit status

Weaponized

A ready exploit tool or active in-the-wild use is known for this vulnerability. This should be your top priority.

Evidence

  • Metasploit module ×1
  • Proof-of-concept repository on GitHub ×1

Noroxi does not host or link to exploit code. Metasploit module names and Nuclei template ids are shown (names, not code); Exploit-DB entries and PoC repositories are given as counts only.

Public exploit evidence
SourceKindDate
Metasploit moduleauxiliary/scanner/http/wp_arbitrary_file_deletionWordpress Arbitrary File Deletionauxiliary2018-06-26
Proof-of-concept repository on GitHubstars:02018-07-05

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

  1. Metasploit-1 d
  2. Published
  3. First PoC+8 d
  4. TodayNov 16, 2026+3065 d

Bug bounty scope

The product’s vendor appears in a public program. Matched by name; verify the scope text in the program.

Not on record for this CVE: EPSS history · patch commit or PR link · researcher credit · variant or chain candidate.

Technical details

Attack conditions

  • Anyone who can reach it over the internet can trigger it.
  • A low-privileged account is enough.
  • No user action is required.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
high · data can be read
Integrity
high · data or configuration can be modified
Availability
high · the service can be disrupted
Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality impact
High
Integrity impact
High
Availability impact
High

CVSS vector

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

nvd-primary

Root cause

A user-supplied file name is joined with the allowed directory, but the result is never checked to confirm it is still inside that directory.

A representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.

Vulnerable

ts
const file = path.join(ROOT, req.query.name);res.sendFile(file);

Fixed

ts
const file = path.resolve(ROOT, req.query.name);if (!file.startsWith(ROOT + path.sep)) {  return res.sendStatus(400);}res.sendFile(file);

References

All records