CVE-2021-3640 Use after free in kernel

High 7.0 Published Updated

A local privileged user can exploit a use-after-free race condition in the Linux kernel HCI subsystem to crash the system or escalate privileges.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2021-3640?

CVE-2021-3640 is a high-severity use after free vulnerability in Canonical Ubuntu Linux, published on 3 Mar 2022. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

A flaw use-after-free in function sco_sock_sendmsg() of the Linux kernel HCI subsystem was found in the way user calls ioct UFFDIO_REGISTER or other way triggers race condition of the call sco_conn_del() together with the call sco_sock_sendmsg() with the expected controllable faulting memory page. A privileged local user could use this flaw to crash the system or escalate their privileges on the system.

Weakness: CWE-416, CWE-362

Which versions are affected by CVE-2021-3640?

It affects 12 products.

Products include Canonical Ubuntu Linux, Debian Debian Linux, Fedoraproject Fedora, Linux kernel, Netapp H300e Firmware, Netapp H300s Firmware and 6 more.

How do I fix CVE-2021-3640?

Apply the vendor's patch.

Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.

Is CVE-2021-3640 being exploited?

There is no known exploitation of CVE-2021-3640 in the wild and no public exploit code.

All Canonical Ubuntu Linux vulnerabilities

Sources

Also known as DEBIAN-CVE-2021-3640, GHSA-c8w8-4f3f-5v3j, OESA-2021-1336, UBUNTU-CVE-2021-3640.

Is CVE-2021-3640 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free