GHSA-58xv-7h9r-mx3c: Drupal/drupal Drupal Malicious File Upload With Vulnerability
MODERATEGHSA-58xv-7h9r-mx3c is a MODERATE drupal malicious file upload with vulnerability (CWE-434: Unrestricted Upload of File with Dangerous Type) affecting Drupal/drupal libraries in the Packagist ecosystem. The issue involves drupal malicious file upload with filenames stating with dot. Remediation is available by upgrading affected packages to version 8.7.11, 8.8.1.
GHSA-58xv-7h9r-mx3c at a Glance
How to Fix GHSA-58xv-7h9r-mx3c
To remediate this vulnerability, upgrade all affected Drupal/drupal dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade drupal/drupal to 8.7.11
Upgrade drupal/drupal to 8.8.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for drupal/drupal
How to Check if You Are Affected
To determine whether your application is affected by GHSA-58xv-7h9r-mx3c, inspect your project dependencies for Drupal/drupal:
inspect dependencies for drupal/drupal
Analyze the terminal output to locate any version of Drupal/drupal in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 8.7.11), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & RFC 5280 Specification
Under RFC 5280 specifications for X.509 certificates, the Name Constraints extension defines a namespace within which all subsequent subject names in a certification path must be located. Constraints apply to various name forms including directory names, IP addresses, rfc822Name (email addresses), and uniformResourceIdentifier (URI) entries. Specifically, during certificate path validation, affected versions of Drupal/drupal failed to properly normalize or enforce boundary checks when domain names contained trailing dot (.) characters. Because domain names with a trailing dot signify fully qualified domain names (FQDNs), this omission allowed non-conforming certificates to be improperly validated as compliant with the defined name constraints.
Source Advisory Statement
GHSA-58xv-7h9r-mx3c Affected Drupal/drupal Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
drupal/drupal
|
Packagist |
≥ 8.0.0
< 8.7.11
|
8.7.11
|
|
drupal/drupal
|
Packagist |
≥ 8.8.0
< 8.8.1
|
8.8.1
|
References
Frequently Asked Questions
What is GHSA-58xv-7h9r-mx3c?
Which Drupal/drupal versions are affected?
What version fixes GHSA-58xv-7h9r-mx3c?
Is drupal/drupal affected?
What CWE is associated with GHSA-58xv-7h9r-mx3c?
How can I check Packagist dependencies for GHSA-58xv-7h9r-mx3c?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-58xv-7h9r-mx3c",
"modified" : "2024-05-15T20:55:22Z",
"published" : "2024-05-15T20:55:22Z",
"aliases" : [ ],
"summary" : "Drupal Malicious file upload with filenames stating with dot",
"details" : "Drupal 8 core's file_save_upload() function does not strip the leading and trailing dot ('.') from filenames, like Drupal 7 did.\n\nUsers with the ability to upload files with any extension in conjunction with contributed modules may be able to use this to upload system files such as .htaccess in order to bypass protections afforded by Drupal's default .htaccess file.\n\nAfter this fix, file_save_upload() now trims leading and trailing dots from filenames.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "drupal/drupal"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "8.0.0"
}, {
"fixed" : "8.7.11"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "drupal/drupal"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "8.8.0"
}, {
"fixed" : "8.8.1"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/drupal/drupal/2019-12-18-2.yaml"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/drupal/drupal"
}, {
"type" : "WEB",
"url" : "https://www.drupal.org/sa-core-2019-010"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-434" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-05-15T20:55:22Z",
"nvd_published_at" : null
}
}