CVE-2024-42161
In the Linux kernel, the following vulnerability has been resolved: bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD [Changes from V1: - Use a default branch in the switch statement to i...
Affects 3 products across 2 vendors.
The Linux kernel contains a vulnerability in the BPF_CORE_READ_BITFIELD macro where the variable `val` may be used uninitialized, potentially leading to undefined behavior.
BSID: BS-2024-GLOBAL-203293-M • Model: /workspace/models/qwen2.5-coder-32b-instruct-bf16 • Confidence: MEDIUM
Is this CVE in your environment?
BreachSpider monitors your ICS/OT environment for vulnerabilities like this one. No agents or network access required. Free to start.
Check My Environment →What is CVE-2024-42161?
What is the CVSS score for CVE-2024-42161?
Is CVE-2024-42161 actively exploited?
How do I remediate CVE-2024-42161?
What systems are affected by CVE-2024-42161?
| CVE ID | CVE-2024-42161 |
|---|---|
| BSID | BS-2024-GLOBAL-203293-M BreachSpider Global ID |
| CVSS Vector | CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:L/I:H/A:H |
| Published | 2024-07-30 |
| Last Modified | 2025-11-03 |
| ICS Relevance | 65% |
| Weakness (CWE) | |
| Verticals | |
| Source | NVD |
In the Linux kernel, the following vulnerability has been resolved: bpf: Avoid uninitialized value in BPF_CORE_READ_BITFIELD [Changes from V1: - Use a default branch in the switch statement to initialize `val'.] GCC warns that `val' may be used uninitialized in the BPF_CRE_READ_BITFIELD macro, defined in bpf_core_read.h as: [...] unsigned long long val; \ [...] \ switch (__CORE_RELO(s, field, BYTE_SIZE)) { \ case 1: val = *(const unsigned char *)p; break; \ case 2: val = *(const unsigned short *)p; break; \ case 4: val = *(const unsigned int *)p; break; \ case 8: val = *(const unsigned long long *)p; break; \ } \ [...] val; \ } \ This patch adds a default entry in the switch statement that sets `val' to zero in order to avoid the warning, and random values to be used in case __builtin_preserve_field_info returns unexpected values for BPF_FIELD_BYTE_SIZE. Tested in bpf-next master. No regressions.
Source: NIST NVD / MITRE CVE Database
An attacker could exploit this vulnerability by crafting a BPF program that triggers the use of the uninitialized `val` variable, potentially leading to information disclosure or other unspecified impacts.
Exploitation Likelihood: MEDIUM
| Vendor | Product | Affected Versions |
|---|---|---|
| Linux | Linux Kernel | < 5.10.222 ≥ 5.11, < 5.15.163 ≥ 5.16, < 6.1.98 ≥ 6.2, < 6.6.39 ≥ 6.7, < 6.9.9 |
| Siemens | Ruggedcom Rst2428P (device & firmware) | < 3.1 |
| CISA known-exploited | Not in KEV catalog |
|---|---|
| Public Exploit | Not confirmed |
| PoC Code | Not confirmed |
AI Enrichment Record — provenance & audit hash
| Model | /workspace/models/qwen2.5-coder-32b-instruct-bf16 |
|---|---|
| Confidence | MEDIUM |
| Enriched At | 2026-05-24 |
| SHA-512 Audit Hash | e1c0306ba86f7772f1638321b285c45b197d863cb4abdc4fa83df7dcd447eb067de6a8531768ca2918b8e7b6b70ee3d09ca98d4579bb82f79690e01a582dfdd6 |
ICS/OT Vulnerability Intelligence for Your Environment
BreachSpider tracks 384,000+ CVEs and matches them to your ICS/OT assets by exact version, with AI analysis, NERC CIP mapping, and vendor PSIRT contacts.
Create a free account →