В ядре Linux устранена следующая уязвимость: wifi: iwlwifi: mld: очищает асинхронные уведомления при nic ошибке Это исправляет панику ядра при отказе реконфигурации: 1. у нас есть BSS соединение 2. у нас есть NAN соединение 3. FW error occurs 4. reconfig restores the BSS connection 5. however, restoring the NAN connection fails due to a FW error. 6. ошибочно, ieee80211_handle_reconfig_failure вызывается и маркирует все интерфейсы как not-in-driver (будет исправлен в другом патче). 7. mac80211 освобождает звенья соединения BSS, но не сообщает об этом водителю, так как считает, что этого vif нет в драйвере. 8. в ieee80211_stop_device, *ALL* wiphy работы получают промывку (ошибочно?) 9. Поэтому async_handlers_wk выполняется, обрабатывая статистическое уведомление, которое было получено после восстановления соединения BSS. 10. обработчик уведомлений удаляет ссылки на fw_id_to_bss_conf[id], который теперь является болтающимся указателем, поскольку mac80211 уже освободил эту ссылку в (7). 11.
При первом доступе к одному из полей ссылок мы паникуем. Хотя это можно и нужно исправить, удалив вызов в ieee80211_handle_reconfig_failure в (6), это также не очень хорошая идея для переноса и, возможно, обработки уведомлений от мертвого FW. Мы удаляем уведомления, когда останавливаем FW, но при отказе перенастроек мы останавливаем FW слишком поздно, после обработки уведомлений.
Кроме того, async_handlers_wk всегда можно запланировать перед работой реконфигурации. Очистить уведомления немедленно, когда транспорт уведомляет об ошибке nic.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: wifi: iwlwifi: mld: purge async notifications upon nic error This fixes a kernel panic in reconfig failure: 1. we have a BSS connection 2. we have a NAN connection 3. FW error occurs 4. reconfig restores the BSS connection 5. however, restoring the NAN connection fails due to a FW error. 6. erroneously, ieee80211_handle_reconfig_failure is called and marks all interfaces as not-in-driver (will be fixed in a different patch). 7. mac80211 frees the links of the BSS connection but doesn't tell the driver about that, as it thinks that this vif is not in the driver. 8. in ieee80211_stop_device, *ALL* wiphy works are getting flushed (erroneously?) 9. Therefore, async_handlers_wk is being executed, processing the statistics notification that was received after we restored the BSS connection. 10. the notification handler dereferences fw_id_to_bss_conf[id], which is now a dangling pointer, as mac80211 already freed this link in (7). 11. On the first access to one of the links fields, we panic. While this can and should be fixed by removing the call to ieee80211_handle_reconfig_failure in (6), it is also not a good idea to carry and maybe handle notifications from a dead FW. We do purge the notifications when we stop the FW, but in reconfig failure we stop the FW too late, after the notifications are processed. In addition, async_handlers_wk can always be scheduled before the reconfig work. Purge the notifications immediately when transport notifies about a nic error.
Характеристики атаки
Последствия
Строка CVSS v3.1