From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 34495156230 for ; Thu, 27 Feb 2025 02:09:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740622149; cv=none; b=ggj1mQDa+3jP4s6d0M8QUcJTWbx9h6KI5TfVl67JE9us5/y18xEqLovfXrLz6L/+ACxK/g6/c1v5Hk2hSCKyh0SNxqs8iMi4xVMHiVI4pudhXuqlfeNKJIrCU6ko92NOWji6Zzbb4RjIRYLitnM/6PSj2l1JIgJrSvnrczl+jZM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740622149; c=relaxed/simple; bh=kHakJS/8lem3rORgDY50VSpX5/23YWSsMCzGdGEdPWQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=KTsO/UmtJgZjtINsU0lk0HeoK1ytbHePv8GpG9cFpWZaHiKdfmy7V5bGUH26WW9eBsp6/EXAH1iYrZnEk7JLXrqQrsXoq7h6XtM6TUcPWQYGpcTMh05mB15Jww+8UbQwWmmNCsz2gnbfgw7xM997MfW/kzSgPeHkCISJH3uGvYA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=XeLlqN8K; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="XeLlqN8K" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 08D33C4CED6; Thu, 27 Feb 2025 02:09:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740622149; bh=kHakJS/8lem3rORgDY50VSpX5/23YWSsMCzGdGEdPWQ=; h=From:To:Cc:Subject:Date:Reply-to:From; b=XeLlqN8KPE5QqlRhYYaIaRba10mbISlblU6QV/Thjj8Wpk+QDG9ud4L9TU/zx6GMo PD5LXS95L9qnPHCUNEoMvokIeGy5hd5PBfuCAT4fd3GDH1ZFvQn6Jk+n7vC4ykP8q0 TZBMA0nXsAHG6nLfqbG7BWnMKFJWRAspvKpJgAos= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-21716: vxlan: Fix uninit-value in vxlan_vnifilter_dump() Date: Wed, 26 Feb 2025 18:06:11 -0800 Message-ID: <2025022646-CVE-2025-21716-3afa@gregkh> X-Mailer: git-send-email 2.48.1 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=5422; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=kHakJS/8lem3rORgDY50VSpX5/23YWSsMCzGdGEdPWQ=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7T1RZhFbIsy+YcdFxS8Oe3bJ/z7J9mjhhl1geS9e+m k2LfQ8LdsSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBEttozzI+Zql0kPJnLryfx 5+xdB9bq6r80PcywYEtwnLTeDAX+h4LMHmr5andL6l/oAgA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: vxlan: Fix uninit-value in vxlan_vnifilter_dump() KMSAN reported an uninit-value access in vxlan_vnifilter_dump() [1]. If the length of the netlink message payload is less than sizeof(struct tunnel_msg), vxlan_vnifilter_dump() accesses bytes beyond the message. This can lead to uninit-value access. Fix this by returning an error in such situations. [1] BUG: KMSAN: uninit-value in vxlan_vnifilter_dump+0x328/0x920 drivers/net/vxlan/vxlan_vnifilter.c:422 vxlan_vnifilter_dump+0x328/0x920 drivers/net/vxlan/vxlan_vnifilter.c:422 rtnl_dumpit+0xd5/0x2f0 net/core/rtnetlink.c:6786 netlink_dump+0x93e/0x15f0 net/netlink/af_netlink.c:2317 __netlink_dump_start+0x716/0xd60 net/netlink/af_netlink.c:2432 netlink_dump_start include/linux/netlink.h:340 [inline] rtnetlink_dump_start net/core/rtnetlink.c:6815 [inline] rtnetlink_rcv_msg+0x1256/0x14a0 net/core/rtnetlink.c:6882 netlink_rcv_skb+0x467/0x660 net/netlink/af_netlink.c:2542 rtnetlink_rcv+0x35/0x40 net/core/rtnetlink.c:6944 netlink_unicast_kernel net/netlink/af_netlink.c:1321 [inline] netlink_unicast+0xed6/0x1290 net/netlink/af_netlink.c:1347 netlink_sendmsg+0x1092/0x1230 net/netlink/af_netlink.c:1891 sock_sendmsg_nosec net/socket.c:711 [inline] __sock_sendmsg+0x330/0x3d0 net/socket.c:726 ____sys_sendmsg+0x7f4/0xb50 net/socket.c:2583 ___sys_sendmsg+0x271/0x3b0 net/socket.c:2637 __sys_sendmsg net/socket.c:2669 [inline] __do_sys_sendmsg net/socket.c:2674 [inline] __se_sys_sendmsg net/socket.c:2672 [inline] __x64_sys_sendmsg+0x211/0x3e0 net/socket.c:2672 x64_sys_call+0x3878/0x3d90 arch/x86/include/generated/asm/syscalls_64.h:47 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd9/0x1d0 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f Uninit was created at: slab_post_alloc_hook mm/slub.c:4110 [inline] slab_alloc_node mm/slub.c:4153 [inline] kmem_cache_alloc_node_noprof+0x800/0xe80 mm/slub.c:4205 kmalloc_reserve+0x13b/0x4b0 net/core/skbuff.c:587 __alloc_skb+0x347/0x7d0 net/core/skbuff.c:678 alloc_skb include/linux/skbuff.h:1323 [inline] netlink_alloc_large_skb+0xa5/0x280 net/netlink/af_netlink.c:1196 netlink_sendmsg+0xac9/0x1230 net/netlink/af_netlink.c:1866 sock_sendmsg_nosec net/socket.c:711 [inline] __sock_sendmsg+0x330/0x3d0 net/socket.c:726 ____sys_sendmsg+0x7f4/0xb50 net/socket.c:2583 ___sys_sendmsg+0x271/0x3b0 net/socket.c:2637 __sys_sendmsg net/socket.c:2669 [inline] __do_sys_sendmsg net/socket.c:2674 [inline] __se_sys_sendmsg net/socket.c:2672 [inline] __x64_sys_sendmsg+0x211/0x3e0 net/socket.c:2672 x64_sys_call+0x3878/0x3d90 arch/x86/include/generated/asm/syscalls_64.h:47 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd9/0x1d0 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f CPU: 0 UID: 0 PID: 30991 Comm: syz.4.10630 Not tainted 6.12.0-10694-gc44daa7e3c73 #29 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.3-3.fc41 04/01/2014 The Linux kernel CVE team has assigned CVE-2025-21716 to this issue. Affected and fixed versions =========================== Issue introduced in 5.18 with commit f9c4bb0b245cee35ef66f75bf409c9573d934cf9 and fixed in 6.1.129 with commit cb1de9309a48cc5b771115781eec05075fd67039 Issue introduced in 5.18 with commit f9c4bb0b245cee35ef66f75bf409c9573d934cf9 and fixed in 6.6.76 with commit a84d511165d6ba7f331b90ae6b6ce180ec534daa Issue introduced in 5.18 with commit f9c4bb0b245cee35ef66f75bf409c9573d934cf9 and fixed in 6.12.13 with commit f554bce488605d2f70e06eeab5e4d2448c813713 Issue introduced in 5.18 with commit f9c4bb0b245cee35ef66f75bf409c9573d934cf9 and fixed in 6.13.2 with commit 1693d1fade71646a0731b6b213298cb443d186ea Issue introduced in 5.18 with commit f9c4bb0b245cee35ef66f75bf409c9573d934cf9 and fixed in 6.14-rc1 with commit 5066293b9b7046a906eff60e3949a887ae185a43 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2025-21716 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/net/vxlan/vxlan_vnifilter.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/cb1de9309a48cc5b771115781eec05075fd67039 https://git.kernel.org/stable/c/a84d511165d6ba7f331b90ae6b6ce180ec534daa https://git.kernel.org/stable/c/f554bce488605d2f70e06eeab5e4d2448c813713 https://git.kernel.org/stable/c/1693d1fade71646a0731b6b213298cb443d186ea https://git.kernel.org/stable/c/5066293b9b7046a906eff60e3949a887ae185a43