CVE-2026-98575: nfc: pn533: fix OOB read in pn533_acr122_is_rx_frame_valid()
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
nfc: pn533: fix OOB read in pn533_acr122_is_rx_frame_valid()
frame->ccid.datalen is read directly from the USB response frame and used, unchecked, as an index into frame->data[]. A malicious or malfunctioning device can set this field to an arbitrary value, causing the driver to read far outside the received buffer.
Bound ccid.datalen against the maximum possible ACR122 frame size before using it. This replaces the existing datalen == 0 check, since datalen < 2 already covers that case and additionally rejects datalen == 1, which would still underflow the "datalen - 2" offset used below.
The Linux kernel CVE team has assigned CVE-2026-98575 to this issue.
Affected and fixed versions
===========================
Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 5.10.271 with commit 8db3b1e012a8b25078dfa1efabe3d0cd2916dcba Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 5.15.222 with commit 74b3fbc60907ee97e3af3249091f57351b53a6d6 Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 6.1.189 with commit 8a0f1bb790d964893db7fc59febda9a534db07b3 Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 6.6.158 with commit ea82b7576793219fa10a8b545f8338998b2a9ce2 Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 6.12.112 with commit 72b8b2126e854d6756a1aa4bdc66d7457b832294 Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 6.18.55 with commit e72cbedc4596e808d22dd2b9fff666ece76f8dd6 Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 7.2.9 with commit 2450a388367231fb7dd798538f393af227c00c4d Issue introduced in 4.7 with commit 9815c7cf22daceabfb919ddcd6f2c80e049c1fbc and fixed in 7.3-rc5 with commit b61732f47316d45f27706db7812950145d3327b5
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-2026-98575
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/nfc/pn533/usb.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/8db3b1e012a8b25078dfa1efabe3d0cd2916dcba https://git.kernel.org/stable/c/74b3fbc60907ee97e3af3249091f57351b53a6d6 https://git.kernel.org/stable/c/8a0f1bb790d964893db7fc59febda9a534db07b3 https://git.kernel.org/stable/c/ea82b7576793219fa10a8b545f8338998b2a9ce2 https://git.kernel.org/stable/c/72b8b2126e854d6756a1aa4bdc66d7457b832294 https://git.kernel.org/stable/c/e72cbedc4596e808d22dd2b9fff666ece76f8dd6 https://git.kernel.org/stable/c/2450a388367231fb7dd798538f393af227c00c4d https://git.kernel.org/stable/c/b61732f47316d45f27706db7812950145d3327b5