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 6132115E5B8 for ; Thu, 27 Feb 2025 02:18:59 +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=1740622739; cv=none; b=WULLzD8rOqOny5a5pMR00SbM5cFW5gK28kVAh2Z/FpezyGDWjgKgI3ue+MlqaTn7fPPn9NTxwcr/8OlzId9rRX6gHio/mWDmjYGdhelsbbZgQL3tn0+oMSW5fXfrz7qAg3/TjHO4tUUQhRfWZxPQFNq1A0TNI1bFO9E3D9fgqH4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740622739; c=relaxed/simple; bh=JU9neaXRv4MLTmQseIdIojhv/4UfoU+7zYvDdm5z7Rc=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=eI/HIXI2GuoX2FQ0MF/YM/1v1LzAm/4qNkOpYOvEaPd/8w0Q/NmXx7n64hvpL61bRfXv9eMgQYZsijiSZOnNwZunshGzYe6qHgemJ6ZZGDmd3hUr8NG2EuendUU6YnrexTVKD7frRomQxpbc5nykZy2BvTKzYs4f+DSDgEX9M10= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=aTPD6Ulw; 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="aTPD6Ulw" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 35BB3C4CED6; Thu, 27 Feb 2025 02:18:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740622739; bh=JU9neaXRv4MLTmQseIdIojhv/4UfoU+7zYvDdm5z7Rc=; h=From:To:Cc:Subject:Date:Reply-to:From; b=aTPD6Ulwjc8se1dWKVTVRyA9QzkN2NAyTZSU1GthYxR/gFha5Kj1/+e1pTvXEMlv0 oz/oV4tMp1SfnOswA5CiR5xVR6kFL9mWZLmogdF7qiry8KdxUt1mJK+TRgiIk1t2b6 aJDa+D8qslrb52Hfo0h/Y+xeRAfvr0dGAVO5RmBI= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2024-57834: media: vidtv: Fix a null-ptr-deref in vidtv_mux_stop_thread Date: Wed, 26 Feb 2025 18:17:07 -0800 Message-ID: <2025022602-CVE-2024-57834-f004@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=4801; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=JU9neaXRv4MLTmQseIdIojhv/4UfoU+7zYvDdm5z7Rc=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7T8upruXecODqTJG3WyW6RSe8c3Hcu26myYz25ksPb Z8IaO1Q64hlYRBkYpAVU2T5so3n6P6KQ4pehranYeawMoEMYeDiFICJMM1mWHBsl3dWXV7RhgsZ vWZzs22/8TTvNGJYMGP3w52s39mkLsbH8ZywFbsvPc/EBAA= 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: media: vidtv: Fix a null-ptr-deref in vidtv_mux_stop_thread syzbot report a null-ptr-deref in vidtv_mux_stop_thread. [1] If dvb->mux is not initialized successfully by vidtv_mux_init() in the vidtv_start_streaming(), it will trigger null pointer dereference about mux in vidtv_mux_stop_thread(). Adjust the timing of streaming initialization and check it before stopping it. [1] KASAN: null-ptr-deref in range [0x0000000000000128-0x000000000000012f] CPU: 0 UID: 0 PID: 5842 Comm: syz-executor248 Not tainted 6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 RIP: 0010:vidtv_mux_stop_thread+0x26/0x80 drivers/media/test-drivers/vidtv/vidtv_mux.c:471 Code: 90 90 90 90 66 0f 1f 00 55 53 48 89 fb e8 82 2e c8 f9 48 8d bb 28 01 00 00 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <0f> b6 04 02 84 c0 74 02 7e 3b 0f b6 ab 28 01 00 00 31 ff 89 ee e8 RSP: 0018:ffffc90003f2faa8 EFLAGS: 00010202 RAX: dffffc0000000000 RBX: 0000000000000000 RCX: ffffffff87cfb125 RDX: 0000000000000025 RSI: ffffffff87d120ce RDI: 0000000000000128 RBP: ffff888029b8d220 R08: 0000000000000005 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000003 R12: ffff888029b8d188 R13: ffffffff8f590aa0 R14: ffffc9000581c5c8 R15: ffff888029a17710 FS: 00007f7eef5156c0(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f7eef5e635c CR3: 0000000076ca6000 CR4: 00000000003526f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: vidtv_stop_streaming drivers/media/test-drivers/vidtv/vidtv_bridge.c:209 [inline] vidtv_stop_feed+0x151/0x250 drivers/media/test-drivers/vidtv/vidtv_bridge.c:252 dmx_section_feed_stop_filtering+0x90/0x160 drivers/media/dvb-core/dvb_demux.c:1000 dvb_dmxdev_feed_stop.isra.0+0x1ee/0x270 drivers/media/dvb-core/dmxdev.c:486 dvb_dmxdev_filter_stop+0x22a/0x3a0 drivers/media/dvb-core/dmxdev.c:559 dvb_dmxdev_filter_free drivers/media/dvb-core/dmxdev.c:840 [inline] dvb_demux_release+0x92/0x550 drivers/media/dvb-core/dmxdev.c:1246 __fput+0x3f8/0xb60 fs/file_table.c:450 task_work_run+0x14e/0x250 kernel/task_work.c:239 get_signal+0x1d3/0x2610 kernel/signal.c:2790 arch_do_signal_or_restart+0x90/0x7e0 arch/x86/kernel/signal.c:337 exit_to_user_mode_loop kernel/entry/common.c:111 [inline] exit_to_user_mode_prepare include/linux/entry-common.h:329 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline] syscall_exit_to_user_mode+0x150/0x2a0 kernel/entry/common.c:218 do_syscall_64+0xda/0x250 arch/x86/entry/common.c:89 entry_SYSCALL_64_after_hwframe+0x77/0x7f The Linux kernel CVE team has assigned CVE-2024-57834 to this issue. Affected and fixed versions =========================== Fixed in 6.1.129 with commit 86307e443c5844f38e1b98e2c51a4195c55576cd Fixed in 6.6.79 with commit 2c5601b99d79d196fe4a37159e3dfb38e778ea18 Fixed in 6.12.16 with commit 95432a37778c9c5dd105b7b9f19e9695c9e166cf Fixed in 6.13.4 with commit 904a8323cc8afa7eb9ce3e67303a2b3f2f787306 Fixed in 6.14-rc1 with commit 1221989555db711578a327a9367f1be46500cb48 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-2024-57834 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/media/test-drivers/vidtv/vidtv_bridge.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/86307e443c5844f38e1b98e2c51a4195c55576cd https://git.kernel.org/stable/c/2c5601b99d79d196fe4a37159e3dfb38e778ea18 https://git.kernel.org/stable/c/95432a37778c9c5dd105b7b9f19e9695c9e166cf https://git.kernel.org/stable/c/904a8323cc8afa7eb9ce3e67303a2b3f2f787306 https://git.kernel.org/stable/c/1221989555db711578a327a9367f1be46500cb48