rustsec-2024-0424
Vulnerability from osv_rustsec
Published
2024-12-19 12:00
Modified
2025-10-28 06:02
Summary
Unsound usages of `core::slice::from_raw_parts_mut`
Details
The library breaks the safety assumptions when using unsafe API slice::from_raw_parts_mut. The pointer passed to from_raw_parts_mut is misaligned by casting u8 to u16 raw pointer directly, which is unsound. The bug is patched by using align_offset, which could make sure the memory address is aligned to 2 bytes for u16.
This was patched in 0.11.2 in the commit.
{
"affected": [
{
"database_specific": {
"categories": [],
"cvss": null,
"informational": "unsound"
},
"ecosystem_specific": {
"affected_functions": null,
"affects": {
"arch": [],
"functions": [
"libafl::observers::map::HitcountsMapObserver::post_exec"
],
"os": []
}
},
"package": {
"ecosystem": "crates.io",
"name": "libafl",
"purl": "pkg:cargo/libafl"
},
"ranges": [
{
"events": [
{
"introduced": "0.0.0-0"
},
{
"fixed": "0.11.2"
}
],
"type": "SEMVER"
}
],
"versions": []
}
],
"aliases": [
"GHSA-f7qj-v3vp-4856"
],
"database_specific": {
"license": "CC0-1.0"
},
"details": "The library breaks the safety assumptions when using unsafe API `slice::from_raw_parts_mut`. The pointer passed to `from_raw_parts_mut` is misaligned by casting `u8` to `u16` raw pointer directly, which is unsound. The bug is patched by using `align_offset`, which could make sure the memory address is aligned to 2 bytes for `u16`. \n\nThis was patched in 0.11.2 in the [commit](https://github.com/AFLplusplus/LibAFL/pull/1530/commits/5a60cb31ef587d71d09d534bba39bd3973c4b35d).",
"id": "RUSTSEC-2024-0424",
"modified": "2025-10-28T06:02:18Z",
"published": "2024-12-19T12:00:00Z",
"references": [
{
"type": "PACKAGE",
"url": "https://crates.io/crates/libafl"
},
{
"type": "ADVISORY",
"url": "https://rustsec.org/advisories/RUSTSEC-2024-0424.html"
},
{
"type": "REPORT",
"url": "https://github.com/AFLplusplus/LibAFL/issues/1526"
},
{
"type": "WEB",
"url": "https://github.com/AFLplusplus/LibAFL/pull/1530"
}
],
"related": [],
"severity": [],
"summary": "Unsound usages of `core::slice::from_raw_parts_mut`"
}
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…