CVE-2021-4202: Use After Free
A flaw was found in the Linux kernel. Similar to the CVE-2021-35373, the ncirequest() function in NFC NCI code also suffers from a data race. This race will allow ncirequest() to be awaken while the device is getting removed and cause UAF. The attacker can spray the released object to gain powerful primitive.
Upstream commit:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=86cdf8e38792545161dbe3350a7eced558ba4d15 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=48b71a9e66c2eab60564b1b1c85f4928ed04e406 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=3e3b5dfcd16a3e254aab61bd1e8c417dd4503102 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=aedddb4e45b34426cfbfa84454b6f203712733c5
Other sources
A use-after-free flaw was found in ncirequest in net/nfc/nci/core.c in NFC Controller Interface (NCI) in the Linux kernel. This flaw could allow a local attacker with user privileges to cause a data race problem while the device is getting removed, leading to a privilege escalation problem.
— Launchpad
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
debian/linuxto a version that resolves this vulnerability.Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.25-1Fixed in 6.12.27-1 - Upgrade
Upgrade
redhat/kernelto a version that resolves this vulnerability.Fixed in 5.16 - Upgrade
Upgrade
Linux kernelto a version that resolves this vulnerability.Patch 3e3b5dfcd16a3e254aab61bd1e8c417dd4503102 - Upgrade
Upgrade
Linux kernelto a version that resolves this vulnerability.Patch 48b71a9e66c2eab60564b1b1c85f4928ed04e406 - Upgrade
Upgrade
Linux kernelto a version that resolves this vulnerability.Patch 86cdf8e38792545161dbe3350a7eced558ba4d15 - Upgrade
Upgrade
Linux kernelto a version that resolves this vulnerability.Patch aedddb4e45b34426cfbfa84454b6f203712733c5
Event History
Frequently Asked Questions
What is the severity of CVE-2021-4202?
CVE-2021-4202 is classified as a medium-severity vulnerability due to the potential for data races within the Linux kernel.
How do I fix CVE-2021-4202?
To mitigate CVE-2021-4202, upgrade to the Linux kernel version 5.16 or higher.
Which systems are affected by CVE-2021-4202?
CVE-2021-4202 affects multiple versions of the Linux kernel, specifically those between versions 3.2 and 5.15.
What component in the kernel is affected by CVE-2021-4202?
The vulnerability in CVE-2021-4202 is found in the nci_request() function within the NFC NCI code of the Linux kernel.
Is CVE-2021-4202 similar to any other vulnerabilities?
Yes, CVE-2021-4202 is similar to CVE-2021-35373 as both involve data races in the Linux kernel.