CVE-2024-50222 iov_iter: fix copy_page_from_iter_atomic() if KMAP_LOCAL_FORCE_MAP

High 7.0 Published Updated

A local attacker can cause a system hang and warning in the Linux kernel when specific highmem debug configurations are enabled.

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-2024-50222?

CVE-2024-50222 is a high-severity denial of service vulnerability in Linux kernel, published on 9 Nov 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:

iov_iter: fix copy_page_from_iter_atomic() if KMAP_LOCAL_FORCE_MAP

generic/077 on x86_32 CONFIG_DEBUG_KMAP_LOCAL_FORCE_MAP=y with highmem, on huge=always tmpfs, issues a warning and then hangs (interruptibly):

WARNING: CPU: 5 PID: 3517 at mm/highmem.c:622 kunmap_local_indexed+0x62/0xc9 CPU: 5 UID: 0 PID: 3517 Comm: cp Not tainted 6.12.0-rc4 #2 ... copy_page_from_iter_atomic+0xa6/0x5ec generic_perform_write+0xf6/0x1b4 shmem_file_write_iter+0x54/0x67

Fix copy_page_from_iter_atomic() by limiting it in that case (include/linux/skbuff.h skb_frag_must_loop() does similar).

But going forward, perhaps CONFIG_DEBUG_KMAP_LOCAL_FORCE_MAP is too surprising, has outlived its usefulness, and should just be removed?

Which versions are affected by CVE-2024-50222?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2024-50222?

Apply the vendor's patch.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is CVE-2024-50222 being exploited?

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

All Linux kernel vulnerabilities

Sources

Also known as AZL-53156, BELL-CVE-2024-50222, DEBIAN-CVE-2024-50222, GHSA-78hj-7cr6-hq8q, UBUNTU-CVE-2024-50222.

Is CVE-2024-50222 in your software?

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

Check your SBOMs for free