CVE-2024-27073: media: ttpci: fix two memleaks in budget_av_attach
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
media: ttpci: fix two memleaks in budget_av_attach
When saa7146_register_device and saa7146_vv_init fails, budget_av_attach should free the resources it allocates, like the error-handling of ttpci_budget_init does. Besides, there are two fixme comment refers to such deallocations.
The Linux kernel CVE team has assigned CVE-2024-27073 to this issue.
Affected and fixed versions
===========================
Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 5.4.273 with commit af37aed04997 Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 5.10.214 with commit 910363473e4b Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 5.15.153 with commit 24e51d6eb578 Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 6.1.83 with commit 55ca0c7eae84 Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 6.6.23 with commit 7393c681f9aa Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 6.7.11 with commit 1597cd1a88cf Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 6.8.2 with commit 656b8cc123d7 Issue introduced in 2.6.12 with commit 1da177e4c3f4 and fixed in 6.9-rc1 with commit d0b07f712bf6
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-27073
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/pci/ttpci/budget-av.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/af37aed04997e644f7e1b52b696b62dcae3cc016 https://git.kernel.org/stable/c/910363473e4bf97da3c350e08d915546dd6cc30b https://git.kernel.org/stable/c/24e51d6eb578b82ff292927f14b9f5ec05a46beb https://git.kernel.org/stable/c/55ca0c7eae8499bb96f4e5d9b26af95e89c4e6a0 https://git.kernel.org/stable/c/7393c681f9aa05ffe2385e8716989565eed2fe06 https://git.kernel.org/stable/c/1597cd1a88cfcdc4bf8b1b44cd458fed9a5a5d63 https://git.kernel.org/stable/c/656b8cc123d7635dd399d9f02594f27aa797ac3c https://git.kernel.org/stable/c/d0b07f712bf61e1a3cf23c87c663791c42e50837