CVE-2021-47351 ubifs: Fix races between xattr_{set|get} and listxattr operations

High 7.8 Published Updated

A race condition in the Linux kernel UBIFS filesystem allows concurrent xattr operations to cause memory corruption or assertion failures, potentially leading to code execution or denial of service.

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-47351?

CVE-2021-47351 is a high-severity vulnerability in Linux kernel, published on 21 May 2024. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

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

ubifs: Fix races between xattr_{set|get} and listxattr operations

UBIFS may occur some problems with concurrent xattr_{set|get} and listxattr operations, such as assertion failure, memory corruption, stale xattr value[1].

Fix it by importing a new rw-lock in @ubifs_inode to serilize write operations on xattr, concurrent read operations are still effective, just like ext4.

[1] https://lore.kernel.org/linux-mtd/[email protected]

Weakness: CWE-787, CWE-617

Which versions are affected by CVE-2021-47351?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2021-47351?

Apply the vendor's patch.

Is CVE-2021-47351 being exploited?

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

All Linux kernel vulnerabilities

Sources

Also known as DEBIAN-CVE-2021-47351, GHSA-2jpv-mgvf-9659, UBUNTU-CVE-2021-47351.

Is CVE-2021-47351 in your software?

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

Check your SBOMs for free