Skip to contentSkip to conversation

CVE-2024-50097: net: fec: don't save PTP state if PTP is unsupported

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Nov 5, 2024

lore
Share & tools
lore
#0 lore raw

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

net: fec: don't save PTP state if PTP is unsupported

Some platforms (such as i.MX25 and i.MX27) do not support PTP, so on these platforms fec_ptp_init() is not called and the related members in fep are not initialized. However, fec_ptp_save_state() is called unconditionally, which causes the kernel to panic. Therefore, add a condition so that fec_ptp_save_state() is not called if PTP is not supported.

The Linux kernel CVE team has assigned CVE-2024-50097 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 6.6.55 with commit dc5fb264168c and fixed in 6.6.57 with commit 7745e14f4c03
	Issue introduced in 6.11.3 with commit 5763541f24d8 and fixed in 6.11.4 with commit 3192e8d4a1ef
	Issue introduced in 6.12-rc2 with commit a1477dc87dc4 and fixed in 6.12-rc3 with commit 6be063071a45
	Issue introduced in 6.10.14 with commit cf53d7e76f1f

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-50097

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/ethernet/freescale/fec_main.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/7745e14f4c036ce94a5eb05d06e49b0d84b306f9
	https://git.kernel.org/stable/c/3192e8d4a1ef9fc9bd7a59cdce51543367e5edd6
	https://git.kernel.org/stable/c/6be063071a457767ee229db13f019c2ec03bfe44