В ядре Linux устранена следующая уязвимость: media: imon: fix use-after-free в display_close через dev_dbg ictx->dev является сырым указателем на встроенное устройство usb_interface's. При отключении usb_disconnect() может отбросить последнюю ссылку на интерфейс и освободить ее, пока пользовательское пространство fd для /dev/lcd0 все еще открыто. Когда эта fd будет позже закрыта, display_close() отсылает теперь свободную ictx->dev через dev_dbg(), вызывая use-after-free.
Удалите вызовы dev_dbg(), которые отсылают ictx->dev в display_close() и free_imon_context(), вместо того, чтобы ссылаться на устройство.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: media: imon: fix use-after-free in display_close via dev_dbg ictx->dev is a raw pointer to the usb_interface's embedded device. On disconnect, usb_disconnect() can drop the last reference on the interface and free it while a userspace fd for /dev/lcd0 is still open. When that fd is later closed, display_close() dereferences the now-freed ictx->dev via dev_dbg(), causing a use-after-free. Remove the dev_dbg() calls that dereference ictx->dev in display_close() and free_imon_context(), rather than taking a reference on the device.