GHSA-7V4J-8WVR-V55R
Vulnerability from github – Published: 2022-06-16 23:40 – Updated: 2022-06-20 18:24
VLAI?
Summary
`array!` macro is unsound when its length is impure constant
Details
Affected versions of this crate did substitute the array length provided by an user at compile-time multiple times.
When an impure constant expression is passed as an array length (such as a result of an impure procedural macro), this can result in the initialization of an array with uninitialized types, which in turn can allow an attacker to execute arbitrary code.
The flaw was corrected in commit d5b63f72 by making sure that array length is substituted just once.
{
"affected": [
{
"package": {
"ecosystem": "crates.io",
"name": "array-macro"
},
"ranges": [
{
"events": [
{
"introduced": "2.1.0"
},
{
"fixed": "2.1.2"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [],
"github_reviewed": true,
"github_reviewed_at": "2022-06-16T23:40:38Z",
"nvd_published_at": null,
"severity": "MODERATE"
},
"details": "Affected versions of this crate did substitute the array length provided by an user at compile-time multiple times.\n\nWhen an impure constant expression is passed as an array length (such as a result of an impure procedural macro), this can result in the initialization of an array with uninitialized types, which in turn can allow an attacker to execute arbitrary code.\n\nThe flaw was corrected in commit [d5b63f72](https://github.com/xfix/array-macro/commit/d5b63f72090f3809c21ac28f9cfd84f12559bf7d) by making sure that array length is substituted just once.\n",
"id": "GHSA-7v4j-8wvr-v55r",
"modified": "2022-06-20T18:24:00Z",
"published": "2022-06-16T23:40:38Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/xfix/array-macro/commit/d5b63f72090f3809c21ac28f9cfd84f12559bf7d"
},
{
"type": "WEB",
"url": "https://github.com/rustsec/advisory-db/blob/main/crates/array-macro/RUSTSEC-2022-0017.md"
},
{
"type": "PACKAGE",
"url": "https://github.com/xfix/array-macro"
},
{
"type": "WEB",
"url": "https://gitlab.com/KonradBorowski/array-macro/-/issues/5"
},
{
"type": "WEB",
"url": "https://rustsec.org/advisories/RUSTSEC-2022-0017.html"
}
],
"schema_version": "1.4.0",
"severity": [],
"summary": "`array!` macro is unsound when its length is impure constant"
}
Loading…
Loading…
Sightings
| Author | Source | Type | Date |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Loading…
Loading…