GHSA-f7qj-v3vp-4856: libafl has unsound usages of `core :slice::from_raw_parts_mut` Vulnerability
MODERATEGHSA-f7qj-v3vp-4856 is a MODERATE :slice::from_raw_parts_mut` vulnerability (General Security Weakness) affecting libafl has unsound usages of `core libraries in the crates.io ecosystem. The issue involves :slice::from_raw_parts_mut`. Remediation is available by upgrading affected packages to version 0.11.2.
GHSA-f7qj-v3vp-4856 at a Glance
How to Fix GHSA-f7qj-v3vp-4856
To remediate this vulnerability, upgrade all affected libafl has unsound usages of `core 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 libafl to 0.11.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for libafl
How to Check if You Are Affected
To determine whether your application is affected by GHSA-f7qj-v3vp-4856, inspect your project dependencies for libafl has unsound usages of `core:
inspect dependencies for libafl
Analyze the terminal output to locate any version of libafl has unsound usages of `core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.11.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 General Security Weakness. In libafl has unsound usages of `core, 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-f7qj-v3vp-4856 Affected libafl has unsound usages of `core Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
libafl
|
crates.io |
< 0.11.2
|
0.11.2
|
References
Frequently Asked Questions
What is GHSA-f7qj-v3vp-4856?
Which libafl has unsound usages of `core versions are affected?
What version fixes GHSA-f7qj-v3vp-4856?
Is libafl affected?
What CWE is associated with GHSA-f7qj-v3vp-4856?
How can I check crates.io dependencies for GHSA-f7qj-v3vp-4856?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-f7qj-v3vp-4856",
"modified" : "2024-12-23T19:30:20Z",
"published" : "2024-12-23T19:28:19Z",
"aliases" : [ ],
"summary" : "libafl has 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`. \n\nThis was patched in 0.11.2 in the [commit](https://github.com/AFLplusplus/LibAFL/pull/1530/commits/5a60cb31ef587d71d09d534bba39bd3973c4b35d).\n",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "libafl"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.11.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/AFLplusplus/LibAFL/issues/1526"
}, {
"type" : "WEB",
"url" : "https://github.com/AFLplusplus/LibAFL/pull/1530"
}, {
"type" : "WEB",
"url" : "https://github.com/AFLplusplus/LibAFL/pull/1530/commits/5a60cb31ef587d71d09d534bba39bd3973c4b35d"
}, {
"type" : "WEB",
"url" : "https://github.com/AFLplusplus/LibAFL/commit/f70a16a09a8096d3c50159dd8a912a75c2af157c"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/AFLplusplus/LibAFL"
}, {
"type" : "WEB",
"url" : "https://rustsec.org/advisories/RUSTSEC-2024-0424.html"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-12-23T19:28:19Z",
"nvd_published_at" : null
}
}