Publish Advisories

GHSA-f7qj-v3vp-4856
GHSA-h6xm-c6r4-vmwf
This commit is contained in:
advisory-database[bot]
2024-12-23 19:31:06 +00:00
parent b38c19c595
commit 9486bfa235
2 changed files with 121 additions and 0 deletions
@@ -0,0 +1,69 @@
{
"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
}
}
@@ -0,0 +1,52 @@
{
"schema_version": "1.4.0",
"id": "GHSA-h6xm-c6r4-vmwf",
"modified": "2024-12-23T19:29:44Z",
"published": "2024-12-23T19:29:44Z",
"aliases": [],
"summary": "Unsound usages of `u8` type casting in spl-token-swap",
"details": "The library provides a safe public API `unpack` to cast `u8` array to arbitrary types, which can cause to undefined behaviors. The length check of array can only prevent out-of-bound access on the return type. However, it can't prevent misaligned pointer when casting `u8` pointer to a type aligned to larger bytes. For example, if we assign `u16` to `T`, **misaligned raw pointer dereference** could happen and cause to panic. Even if we pass the type aligned to same byte as `u8` (e.g., `bool`), it could construct a illegal type since `bool` can only have 0 or 1 as bit patterns, which is also an undefined behavior. The further exploits of the bug here are still not clear, so we would report this issue as unsound. \n\nThe details of PoC to reproduce undefined behavior are provided in the [issue](https://github.com/solana-labs/solana-program-library/issues/5243). \n",
"severity": [],
"affected": [
{
"package": {
"ecosystem": "crates.io",
"name": "spl-token-swap"
},
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"last_affected": "3.0.0"
}
]
}
]
}
],
"references": [
{
"type": "WEB",
"url": "https://github.com/solana-labs/solana-program-library/issues/5243"
},
{
"type": "PACKAGE",
"url": "https://github.com/solana-labs/solana-program-library"
},
{
"type": "WEB",
"url": "https://rustsec.org/advisories/RUSTSEC-2024-0426.html"
}
],
"database_specific": {
"cwe_ids": [],
"severity": "MODERATE",
"github_reviewed": true,
"github_reviewed_at": "2024-12-23T19:29:44Z",
"nvd_published_at": null
}
}