WordPress security changelog
HIGH CVE-2018-12895 Modified

WordPress component: Filesystem traversal

WordPress component is affected by filesystem traversal. Exposure depends on how the affected operation is made reachable by the site. A crafted path can escape the intended directory and reach files or directories elsewhere on the server.

CVE / CNA score 8.8 CVSS · cve@mitre.org
NVD score 8.8 CVSS 3.1 · nvd@nist.gov
Component
WordPress component
Plugin slug
Not applicable
Affected
See vendor advisory
Safe version
See mitigation notes
Published
Jun 26, 2018
Weakness
CWE-22 — Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Update, patch or deactivate.

Update WordPress component to a release outside the affected range, or disable and remove it until a fixed version is available.

No confirmed safe version is listed. Consider a vendor-supported patch or temporarily restricting the affected functionality while you assess the risk.

Deactivate only when warranted by your risk profile, or when advised by your hosting provider in the limited circumstances where the vulnerability cannot otherwise be mitigated. If you’re unsure which action is appropriate, contact Fused or your hosting provider for guidance.

Technical description

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.

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

Primary and upstream sources