CVE-2024-26934 USB: core: Fix deadlock in usb_deauthorize_interface()

High 7.8 Published Updated

A deadlock in the Linux kernel USB core allows local attackers to cause a denial of service by triggering a race condition during interface deauthorization.

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

CVE-2024-26934 is a high-severity vulnerability in Linux kernel, published on 1 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:

USB: core: Fix deadlock in usb_deauthorize_interface()

Among the attribute file callback routines in drivers/usb/core/sysfs.c, the interface_authorized_store() function is the only one which acquires a device lock on an ancestor device: It calls usb_deauthorize_interface(), which locks the interface's parent USB device.

The will lead to deadlock if another process already owns that lock and tries to remove the interface, whether through a configuration change or because the device has been disconnected. As part of the removal procedure, device_del() waits for all ongoing sysfs attribute callbacks to complete. But usb_deauthorize_interface() can't complete until the device lock has been released, and the lock won't be released until the removal has finished.

The mechanism provided by sysfs to prevent this kind of deadlock is to use the sysfs_break_active_protection() function, which tells sysfs not to wait for the attribute callback.

Reported-and-tested by: Yue Sun <[email protected]> Reported by: xingwei lee <[email protected]>

Weakness: CWE-667

Which versions are affected by CVE-2024-26934?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2024-26934?

Apply the vendor's patch.

Is CVE-2024-26934 being exploited?

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

All Linux kernel vulnerabilities

Sources

Also known as AZL-42270, BELL-CVE-2024-26934, DEBIAN-CVE-2024-26934, GHSA-6wq5-2j9j-6rvr, UBUNTU-CVE-2024-26934.

Is CVE-2024-26934 in your software?

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

Check your SBOMs for free