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 7B1F4290D81 for ; Tue, 30 Dec 2025 12:10:51 +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=1767096651; cv=none; b=FovmVNZhWG+nBateuhZ9lpCXKPBDV8yWT7l8kx6xoJTFwuRV9XCIYWFXFOiaFqYtWBKu6jHHrDZ09sslNdFc2tqAImHcQkYDTB3R8Rqw+6/QK0BQa3kUYWDForox518rPWdEXAi1EHd7S7JadRvwZLtfbq29+vPMzNibW155k84= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767096651; c=relaxed/simple; bh=1k9mVXPed/l7SgoSNpPWDu+BuPJpWmoBgqzw79Aejss=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=jyOHksJwEqdeOpwzs9gjJ2STAUYZZ+HjF/y8Iu1Tj2siSATWtP9rG16EFM3HH2pUXnatSkff4fVqHHzcYg7Y7GRP8jKkcF6Djg4nQzeewRLovXQZEyJKuhNAECPOHIthZjRrj/Wpn0fWa8+34J8/pfu9eRP1RKXs/fsn2C0Fl0w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=gaphCQAP; 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="gaphCQAP" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0AFFAC4CEFB; Tue, 30 Dec 2025 12:10:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1767096651; bh=1k9mVXPed/l7SgoSNpPWDu+BuPJpWmoBgqzw79Aejss=; h=From:To:Cc:Subject:Date:Reply-To:From; b=gaphCQAP8nrenHvjoJHnjbiu28KYdMtHJjgckqLARj8WvBHT5Ob3KJFHoFEOxAJes J8wTLMzNhpN8ilCsrGvMinQnO4Gmuesk3YEPYnzPVVydmKqBNkNV/Cc8O3OEwyplK8 fn3e6Y8dNv0PVb7hfKBgVpaTkRbF4gELNFFetGt8= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-50817: net: hsr: avoid possible NULL deref in skb_clone() Date: Tue, 30 Dec 2025 13:09:21 +0100 Message-ID: <2025123015-CVE-2022-50817-55d8@gregkh> X-Mailer: git-send-email 2.52.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=4799; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=cJwmxgTpgsR7KxZEKeH8ZYxYfX5b8lxCuApwi5U/VOw=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnBB143nj+R3uBy+K94f9Bzm6DVvZ67Gj8J/JbQPbdR0 u+vltTzjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZgI51+G+XkCTAmuW0OrTwjr V3oWRZzo5FyTyjCbNWVZNe96h2f7emc+3Hz6vrX9him+AA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: net: hsr: avoid possible NULL deref in skb_clone() syzbot got a crash [1] in skb_clone(), caused by a bug in hsr_get_untagged_frame(). When/if create_stripped_skb_hsr() returns NULL, we must not attempt to call skb_clone(). While we are at it, replace a WARN_ONCE() by netdev_warn_once(). [1] general protection fault, probably for non-canonical address 0xdffffc000000000f: 0000 [#1] PREEMPT SMP KASAN KASAN: null-ptr-deref in range [0x0000000000000078-0x000000000000007f] CPU: 1 PID: 754 Comm: syz-executor.0 Not tainted 6.0.0-syzkaller-02734-g0326074ff465 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022 RIP: 0010:skb_clone+0x108/0x3c0 net/core/skbuff.c:1641 Code: 93 02 00 00 49 83 7c 24 28 00 0f 85 e9 00 00 00 e8 5d 4a 29 fa 4c 8d 75 7e 48 b8 00 00 00 00 00 fc ff df 4c 89 f2 48 c1 ea 03 <0f> b6 04 02 4c 89 f2 83 e2 07 38 d0 7f 08 84 c0 0f 85 9e 01 00 00 RSP: 0018:ffffc90003ccf4e0 EFLAGS: 00010207 RAX: dffffc0000000000 RBX: ffffc90003ccf5f8 RCX: ffffc9000c24b000 RDX: 000000000000000f RSI: ffffffff8751cb13 RDI: 0000000000000000 RBP: 0000000000000000 R08: 00000000000000f0 R09: 0000000000000140 R10: fffffbfff181d972 R11: 0000000000000000 R12: ffff888161fc3640 R13: 0000000000000a20 R14: 000000000000007e R15: ffffffff8dc5f620 FS: 00007feb621e4700(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007feb621e3ff8 CR3: 00000001643a9000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: hsr_get_untagged_frame+0x4e/0x610 net/hsr/hsr_forward.c:164 hsr_forward_do net/hsr/hsr_forward.c:461 [inline] hsr_forward_skb+0xcca/0x1d50 net/hsr/hsr_forward.c:623 hsr_handle_frame+0x588/0x7c0 net/hsr/hsr_slave.c:69 __netif_receive_skb_core+0x9fe/0x38f0 net/core/dev.c:5379 __netif_receive_skb_one_core+0xae/0x180 net/core/dev.c:5483 __netif_receive_skb+0x1f/0x1c0 net/core/dev.c:5599 netif_receive_skb_internal net/core/dev.c:5685 [inline] netif_receive_skb+0x12f/0x8d0 net/core/dev.c:5744 tun_rx_batched+0x4ab/0x7a0 drivers/net/tun.c:1544 tun_get_user+0x2686/0x3a00 drivers/net/tun.c:1995 tun_chr_write_iter+0xdb/0x200 drivers/net/tun.c:2025 call_write_iter include/linux/fs.h:2187 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x9e9/0xdd0 fs/read_write.c:584 ksys_write+0x127/0x250 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd The Linux kernel CVE team has assigned CVE-2022-50817 to this issue. Affected and fixed versions =========================== Issue introduced in 3.17 with commit f266a683a4804dc499efc6c2206ef68efed029d0 and fixed in 5.10.152 with commit ff7ba766758313129794f150bbc4d351b5e17a53 Issue introduced in 3.17 with commit f266a683a4804dc499efc6c2206ef68efed029d0 and fixed in 5.15.76 with commit 35ece858660eae13ee0242496a1956c39d29418e Issue introduced in 3.17 with commit f266a683a4804dc499efc6c2206ef68efed029d0 and fixed in 6.0.6 with commit c46f2e0fcd1ecfc6046e5cf785ff89f0572f94e4 Issue introduced in 3.17 with commit f266a683a4804dc499efc6c2206ef68efed029d0 and fixed in 6.1 with commit d8b57135fd9ffe9a5b445350a686442a531c5339 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-2022-50817 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: net/hsr/hsr_forward.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/ff7ba766758313129794f150bbc4d351b5e17a53 https://git.kernel.org/stable/c/35ece858660eae13ee0242496a1956c39d29418e https://git.kernel.org/stable/c/c46f2e0fcd1ecfc6046e5cf785ff89f0572f94e4 https://git.kernel.org/stable/c/d8b57135fd9ffe9a5b445350a686442a531c5339