GHSA-mcrf-7hf9-f6q5: Rmpv Unchecked Vector Pre-allocation Vulnerability
MODERATEGHSA-mcrf-7hf9-f6q5 is a MODERATE unchecked vector pre-allocation vulnerability (CWE-400: Uncontrolled Resource Consumption) affecting Rmpv libraries in the crates.io ecosystem. The issue involves unchecked vector pre-allocation. Remediation is available by upgrading affected packages to version 0.4.2.
GHSA-mcrf-7hf9-f6q5 at a Glance
How to Fix GHSA-mcrf-7hf9-f6q5
To remediate this vulnerability, upgrade all affected Rmpv 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 rmpv to 0.4.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for rmpv
How to Check if You Are Affected
To determine whether your application is affected by GHSA-mcrf-7hf9-f6q5, inspect your project dependencies for Rmpv:
inspect dependencies for rmpv
Analyze the terminal output to locate any version of Rmpv in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.4.2), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-400: Uncontrolled Resource Consumption, where the product does not properly control the allocation and maintenance of a limited resource. In Rmpv, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-mcrf-7hf9-f6q5 Affected Rmpv Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
rmpv
|
crates.io |
< 0.4.2
|
0.4.2
|
References
Frequently Asked Questions
What is GHSA-mcrf-7hf9-f6q5?
Which Rmpv versions are affected?
What version fixes GHSA-mcrf-7hf9-f6q5?
Is rmpv affected?
What CWE is associated with GHSA-mcrf-7hf9-f6q5?
How can I check crates.io dependencies for GHSA-mcrf-7hf9-f6q5?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-mcrf-7hf9-f6q5",
"modified" : "2023-06-13T20:48:55Z",
"published" : "2021-08-25T21:00:09Z",
"aliases" : [ ],
"summary" : "Unchecked vector pre-allocation",
"details" : "Affected versions of this crate pre-allocate memory on deserializing raw buffers without checking whether there is sufficient data available. This allows an attacker to do denial-of-service attacks by sending small msgpack messages that allocate gigabytes of memory.\n",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "rmpv"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.4.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/3Hren/msgpack-rust/issues/151"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/3Hren/msgpack-rust"
}, {
"type" : "WEB",
"url" : "https://rustsec.org/advisories/RUSTSEC-2017-0006.html"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-400" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2021-08-06T19:28:40Z",
"nvd_published_at" : null
}
}