CVE-2021-3491: Linux kernel io_uring PROVIDE_BUFFERS MAX_RW_COUNT bypass
Last updated 4 July 2026
Other sources
The iouring subsystem in the Linux kernel allowed the MAXRWCOUNT limit to be bypassed in the PROVIDEBUFFERS operation, which led to negative values being usedin memrw when reading /proc/<PID>/mem. This could be used to create a heap overflow leading to arbitrary code execution in the kernel. It was addressed via commit d1f82808877b ("iouring: truncate lengths larger than MAXRWCOUNT on provide buffers") (v5.13-rc1) and backported to the stable kernels in v5.12.4, v5.11.21, and v5.10.37. It was introduced in ddf0322db79c ("iouring: add IORINGOPPROVIDEBUFFERS") (v5.7-rc1).
— Launchpad
This vulnerability allows local attackers to escalate privileges on affected installations of Canonical Ubuntu. An attacker must first obtain the ability to execute low-privileged code on the target system in order to exploit this vulnerability. The specific flaw exists within the handling of buffers in iouring. The issue results from the lack of proper validation of user-supplied data, which can result in an integer overflow before accessing memory. An attacker can leverage this vulnerability to escalate privileges and execute arbitrary code in the context of the kernel.
— ZDI
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.259-1Fixed in 6.1.176-1Fixed in 6.1.177-1Fixed in 6.12.94-1Fixed in 6.12.95-1Fixed in 7.1.3-1Fixed in 7.1.4-1 - Upgrade
Upgrade
Linux kernel io_uringto a version that resolves this vulnerability.Fixed in 5.13-rc1Patch d1f82808877b - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 5.12.4 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 5.11.21 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 5.10.37
Event History
Frequently Asked Questions
What is the severity of CVE-2021-3491?
CVE-2021-3491 is considered a high severity vulnerability due to the potential for heap overflow.
How do I fix CVE-2021-3491?
To fix CVE-2021-3491, upgrade to the patched kernel versions such as 5.10.223-1 or higher.
What systems are affected by CVE-2021-3491?
CVE-2021-3491 affects multiple versions of the Linux kernel, particularly those between 5.7 and 5.12.4.
Can CVE-2021-3491 be exploited remotely?
CVE-2021-3491 may allow local users to exploit the vulnerability, but is not classified as a remote exploitation vulnerability.
What are the potential impacts of CVE-2021-3491?
Exploiting CVE-2021-3491 could lead to unauthorized access to memory and potentially allow attackers to execute arbitrary code.