{"schema":"/api/v1/schema/cve.json","api_version":"1","id":"CVE-2024-42161","published":"2024-07-30T08:15:07.447000Z","last_modified":"2026-06-17T07:48:57.520000Z","status":"Modified","cvss":{"version":"3.1","score":6.3,"severity":"MEDIUM","vector":"CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:L/I:H/A:H","source":"nvd@nist.gov","primary":true},"auth":true,"cwes":["CWE-908"],"cpes":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_end_excluding":"5.10.222"},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_start_including":"5.11","version_end_excluding":"5.15.163"},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_start_including":"5.16","version_end_excluding":"6.1.98"},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_start_including":"6.2","version_end_excluding":"6.6.39"},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","part":"o","vendor":"linux","product":"linux_kernel","version_start_including":"6.7","version_end_excluding":"6.9.9"}],"cpes_truncated":false,"vendors":["linux"],"products":["linux/linux_kernel"],"ssvc":{"exploitation":"none","automatable":"no","technical_impact":"partial"},"epss":{"score":0.00307,"percentile":0.16003,"date":"2026-11-30","model_version":"v2026.06.15"},"cat":"os","platform":"linux","eol":false,"packages":[],"severity":"medium","priority_score":38,"links":{"html_es":"/es/cve/CVE-2024-42161/","html_en":"/en/cve/CVE-2024-42161/","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2024-42161","cve_org":"https://www.cve.org/CVERecord?id=CVE-2024-42161"},"untrusted":{"vendor_name":"Linux","product_name":"Linux Kernel","desc_en":"In the Linux kernel, the following vulnerability has been resolved:\n\nbpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD\n\n[Changes from V1:\n - Use a default branch in the switch statement to initialize `val'.]\n\nGCC warns that `val' may be used uninitialized in the\nBPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as:\n\n\t[...]\n\tunsigned long long val;\t\t\t\t\t\t      \\\n\t[...]\t\t\t\t\t\t\t\t      \\\n\tswitch (__CORE_RELO(s, field, BYTE_SIZE)) {\t\t\t      \\\n\tcase 1: val = *(const unsigned char *)p; break;\t\t\t      \\\n\tcase 2: val = *(const unsigned short *)p; break;\t\t      \\\n\tcase 4: val = *(const unsigned int *)p; break;\t\t\t      \\\n\tcase 8: val = *(const unsigned long long *)p; break;\t\t      \\\n        }       \t\t\t\t\t\t\t      \\\n\t[...]\n\tval;\t\t\t\t\t\t\t\t      \\\n\t}\t\t\t\t\t\t\t\t      \\\n\nThis patch adds a default entry in the switch statement that sets\n`val' to zero in order to avoid the warning, and random values to be\nused in case __builtin_preserve_field_info returns unexpected values\nfor BPF_FIELD_BYTE_SIZE.\n\nTested in bpf-next master.\nNo regressions.","affected":[{"untrusted_vendor":"Linux","untrusted_product":"Linux","versions":[]}],"references":[{"url":"https://git.kernel.org/stable/c/009367099eb61a4fc2af44d4eb06b6b4de7de6db","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/3364c2ed1c241989847f19cf83e3db903ce689e3","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/7e5471b5efebc30dd0bc035cda86693a5c73d45f","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/a21d76bd0b0d39518e9a4c19f6cf7c042a974aff","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/b694989bb13ed5f166e633faa1eb0f21c6d261a6","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/ff941a8449e712eaf7efca1a13bfb9afd3d99fc2","tags":["Patch"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html","tags":[]}]}}