В ядре Linux была устранена следующая уязвимость: Bluetooth: hci_conn: исправить SCO setup context lifetime hci_setup_sync() очереди conn_handle_t с NULL destroy callback, поэтому контекст освобождается только в том случае, если hci_enhanced_setup_sync() на самом деле запущен. Вместо этого происходит утечка записи, так как _hci_cmd_sync_cancel_entry() не выпускает entry->data, когда нет обратного вызова, а hci_cmd_sync_clear() отменяет каждую ожидающую запись, когда контроллер не зарегистрирован. Контекст также хранит голый указатель hci_conn, поэтому соединение может быть освобождено во время очереди работы.
Очередь в hci_conn_del() также не покрывает его, так как она совпадает с entry->data conn, а entry->data является обёрткой здесь. Same problem as commit 2f5d635ad590 ("Bluetooth: hci_sync: hold conn in hci_connect_acl/le_sync() callbacks"). Удерживайте соединение и освобождайте обоих от обратного вызова.
Путь отказа отправки падает оба, так как hci_cmd_sync_submit () не вызывает обратный вызов уничтожает, когда он не в очереди.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: Bluetooth: hci_conn: fix the SCO setup context lifetime hci_setup_sync() queues a conn_handle_t with a NULL destroy callback, so the context is only freed if hci_enhanced_setup_sync() actually runs. An entry that is cancelled instead is leaked, as _hci_cmd_sync_cancel_entry() does not release entry->data when there is no destroy callback, and hci_cmd_sync_clear() cancels every pending entry when the controller is unregistered. The context also stores a bare hci_conn pointer, so the connection can be freed while the work is queued. The dequeue in hci_conn_del() does not cover it either, as it matches on entry->data == conn and entry->data is the wrapper here. Same problem as commit 2f5d635ad590 ("Bluetooth: hci_sync: hold conn in hci_connect_acl/le_sync() callbacks"). Hold the connection and release both from a destroy callback. The submission failure path drops both, since hci_cmd_sync_submit() does not call the destroy callback when it fails to queue.
Характеристики атаки
Последствия
Строка CVSS v3.1