GHSA-GHC8-5CGM-5RPF
Vulnerability from github – Published: 2023-09-11 20:43 – Updated: 2023-09-11 20:43
VLAI?
Summary
Inventory fails to prohibit standard library access prior to initialization of Rust standard library runtime
Details
Affected versions allow arbitrary caller-provided code to execute before the lifetime of main.
If the caller-provided code accesses particular pieces of the standard library that require an initialized Rust runtime, such as std::io or std::thread, these may not behave as documented. Panics are likely; UB is possible.
The flaw was corrected by enforcing that only code written within the inventory crate, which is guaranteed not to access runtime-dependent parts of the standard library, runs before main. Caller-provided code is restricted to running at compile time.
{
"affected": [
{
"package": {
"ecosystem": "crates.io",
"name": "inventory"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "0.2.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [],
"github_reviewed": true,
"github_reviewed_at": "2023-09-11T20:43:17Z",
"nvd_published_at": null,
"severity": "MODERATE"
},
"details": "Affected versions allow arbitrary caller-provided code to execute before the lifetime of `main`.\n\nIf the caller-provided code accesses particular pieces of the standard library that require an initialized Rust runtime, such as `std::io` or `std::thread`, these may not behave as documented. Panics are likely; UB is possible.\n\nThe flaw was corrected by enforcing that only code written within the `inventory` crate, which is guaranteed not to access runtime-dependent parts of the standard library, runs before `main`. Caller-provided code is restricted to running at compile time.\n",
"id": "GHSA-ghc8-5cgm-5rpf",
"modified": "2023-09-11T20:43:17Z",
"published": "2023-09-11T20:43:17Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/dtolnay/inventory/pull/43"
},
{
"type": "WEB",
"url": "https://github.com/dtolnay/inventory/commit/b853350a3800e38d2cb9950355b80bc8b8d3959c"
},
{
"type": "PACKAGE",
"url": "https://github.com/dtolnay/inventory"
},
{
"type": "WEB",
"url": "https://rustsec.org/advisories/RUSTSEC-2023-0057.html"
}
],
"schema_version": "1.4.0",
"severity": [],
"summary": "Inventory fails to prohibit standard library access prior to initialization of Rust standard library runtime"
}
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…