CVE-2024-42082

Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
29/07/2024
Last modified:
03/11/2025

Description

In the Linux kernel, the following vulnerability has been resolved:<br /> <br /> xdp: Remove WARN() from __xdp_reg_mem_model()<br /> <br /> syzkaller reports a warning in __xdp_reg_mem_model().<br /> <br /> The warning occurs only if __mem_id_init_hash_table() returns an error. It<br /> returns the error in two cases:<br /> <br /> 1. memory allocation fails;<br /> 2. rhashtable_init() fails when some fields of rhashtable_params<br /> struct are not initialized properly.<br /> <br /> The second case cannot happen since there is a static const rhashtable_params<br /> struct with valid fields. So, warning is only triggered when there is a<br /> problem with memory allocation.<br /> <br /> Thus, there is no sense in using WARN() to handle this error and it can be<br /> safely removed.<br /> <br /> WARNING: CPU: 0 PID: 5065 at net/core/xdp.c:299 __xdp_reg_mem_model+0x2d9/0x650 net/core/xdp.c:299<br /> <br /> CPU: 0 PID: 5065 Comm: syz-executor883 Not tainted 6.8.0-syzkaller-05271-gf99c5f563c17 #0<br /> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024<br /> RIP: 0010:__xdp_reg_mem_model+0x2d9/0x650 net/core/xdp.c:299<br /> <br /> Call Trace:<br /> xdp_reg_mem_model+0x22/0x40 net/core/xdp.c:344<br /> xdp_test_run_setup net/bpf/test_run.c:188 [inline]<br /> bpf_test_run_xdp_live+0x365/0x1e90 net/bpf/test_run.c:377<br /> bpf_prog_test_run_xdp+0x813/0x11b0 net/bpf/test_run.c:1267<br /> bpf_prog_test_run+0x33a/0x3b0 kernel/bpf/syscall.c:4240<br /> __sys_bpf+0x48d/0x810 kernel/bpf/syscall.c:5649<br /> __do_sys_bpf kernel/bpf/syscall.c:5738 [inline]<br /> __se_sys_bpf kernel/bpf/syscall.c:5736 [inline]<br /> __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5736<br /> do_syscall_64+0xfb/0x240<br /> entry_SYSCALL_64_after_hwframe+0x6d/0x75<br /> <br /> Found by Linux Verification Center (linuxtesting.org) with syzkaller.

Vulnerable products and versions

CPE From Up to
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 4.18 (excluding)
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 4.19 (including) 5.10.221 (excluding)
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 5.11 (including) 5.15.162 (excluding)
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 5.16 (including) 6.1.97 (excluding)
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 6.2 (including) 6.6.37 (excluding)
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* 6.7 (including) 6.9.8 (excluding)