{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2024-39482","id":"CVE-2024-39482","title":"bcache: fix variable length array abuse in btree_iter","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nbcache: fix variable length array abuse in btree_iter\n\nbtree_iter is used in two ways: either allocated on the stack with a\nfixed size MAX_BSETS, or from a mempool with a dynamic size based on the\nspecific cache set. Previously, the struct had a fixed-length array of\nsize MAX_BSETS which was indexed out-of-bounds for the dynamica","descriptionLong":"In the Linux kernel, the following vulnerability has been resolved:\n\nbcache: fix variable length array abuse in btree_iter\n\nbtree_iter is used in two ways: either allocated on the stack with a\nfixed size MAX_BSETS, or from a mempool with a dynamic size based on the\nspecific cache set. Previously, the struct had a fixed-length array of\nsize MAX_BSETS which was indexed out-of-bounds for the dynamically-sized\niterators, which causes UBSAN to complain.\n\nThis patch uses the same approach as in bcachefs's sort_iter and splits\nthe iterator into a btree_iter with a flexible array member and a\nbtree_iter_stack which embeds a btree_iter as well as a fixed-length\ndata array.","published":"2024-07-05T06:55:10.599Z","updated":"2026-10-28T02:31:12.474106467Z","reserved":"2024-06-25T14:23:23.746Z","status":"Modified","rejected":false,"assigner":"Linux","metric":{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"Linux"},"metrics":[{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"Linux"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67"},{"version":"3.1","score":5.5,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","rating":"medium","source":"NVD"},{"version":"3.1","score":7.8,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","rating":"high","source":"OSV"}],"rating":"high","products":["Linux"],"affectedProducts":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"2c3d7b03b658dc8bfa6112b194b67b92a87e081b","status":"affected","versionType":"git"},{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"5a1922adc5798b7ec894cd3f197afb6f9591b023","status":"affected","versionType":"git"},{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"934e1e4331859183a861f396d7dfaf33cb5afb02","status":"affected","versionType":"git"},{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"6479b9f41583b013041943c4602e1ad61cec8148","status":"affected","versionType":"git"},{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"0c31344e22dd8d6b1394c6e4c41d639015bdc671","status":"affected","versionType":"git"},{"version":"cafe563591446cf80bfbc2fe3bc72a2e36cf1060","lessThan":"3a861560ccb35f2a4f0a4b8207fa7c2a35fc7f31","status":"affected","versionType":"git"}],"platforms":[]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"3.10","status":"affected"},{"version":"0","lessThan":"3.10","status":"unaffected","versionType":"semver"},{"version":"5.10.221","lessThanOrEqual":"5.10.*","status":"unaffected","versionType":"semver"},{"version":"5.15.162","lessThanOrEqual":"5.15.*","status":"unaffected","versionType":"semver"},{"version":"6.1.94","lessThanOrEqual":"6.1.*","status":"unaffected","versionType":"semver"},{"version":"6.6.34","lessThanOrEqual":"6.6.*","status":"unaffected","versionType":"semver"},{"version":"6.9.5","lessThanOrEqual":"6.9.*","status":"unaffected","versionType":"semver"},{"version":"6.10","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}],"platforms":[]}],"packages":[],"cwes":["CWE-770"],"aliases":[],"references":[{"url":"https://git.kernel.org/stable/c/2c3d7b03b658dc8bfa6112b194b67b92a87e081b","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://git.kernel.org/stable/c/5a1922adc5798b7ec894cd3f197afb6f9591b023","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://git.kernel.org/stable/c/934e1e4331859183a861f396d7dfaf33cb5afb02","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://git.kernel.org/stable/c/6479b9f41583b013041943c4602e1ad61cec8148","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://git.kernel.org/stable/c/0c31344e22dd8d6b1394c6e4c41d639015bdc671","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://git.kernel.org/stable/c/3a861560ccb35f2a4f0a4b8207fa7c2a35fc7f31","tags":["x_transferred","Mailing List","Patch","web"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-265688.html","tags":["web"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-613116.html","tags":["web"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-355557.html","tags":["web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/39xxx/CVE-2024-39482.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-39482","tags":["advisory"]},{"url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","tags":["package"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial"},"epss":0.00238,"epssPercentile":0.15031,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2024-39482","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-39482","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2024-39482","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2024-39482","ok":true,"note":"scored 2026-11-18"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}