First published: Wed May 01 2024(Updated: )
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 <samsun1006219@gmail.com> Reported by: xingwei lee <xrivendell7@gmail.com>
Credit: 416baaa9-dc9f-4396-8d5f-8c081fb06d67 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Affected Software | Affected Version | How to fix |
---|---|---|
Linux Linux kernel | >=4.4<4.19.312 | |
Linux Linux kernel | >=4.20.0<5.4.274 | |
Linux Linux kernel | >=5.5.0<5.10.215 | |
Linux Linux kernel | >=5.11.0<5.15.154 | |
Linux Linux kernel | >=5.16.0<6.1.84 | |
Linux Linux kernel | >=6.2.0<6.6.24 | |
Linux Linux kernel | >=6.7.0<6.7.12 | |
Linux Linux kernel | >=6.8.0<6.8.3 | |
Linux Linux kernel | =6.9-r1 | |
redhat/kernel | <4.19.312 | 4.19.312 |
redhat/kernel | <5.4.274 | 5.4.274 |
redhat/kernel | <5.10.215 | 5.10.215 |
redhat/kernel | <5.15.154 | 5.15.154 |
redhat/kernel | <6.1.84 | 6.1.84 |
redhat/kernel | <6.6.24 | 6.6.24 |
redhat/kernel | <6.7.12 | 6.7.12 |
redhat/kernel | <6.8.3 | 6.8.3 |
redhat/kernel | <6.9 | 6.9 |
debian/linux | 5.10.223-1 5.10.226-1 6.1.115-1 6.1.119-1 6.12.5-1 6.12.6-1 |
Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.