В ядре Linux устранена следующая уязвимость: wifi: mac80211: fix mesh fast xmit path delete UAF mesh_fast_tx_cache() хранит необработанные указатели mesh_path. Удаление пути смывает кэш, а затем освобождает путь с помощью kfree_rcu(), но поиск, который уже удерживает путь, может вставить новый элемент кэша после flush. Затем кэш указывает на освобожденную память.
Установите MESH_PATH_DELETED перед промывкой и пропустите вставку кэша, если путь или путь MPP уже удалены. Проверьте это под блокировкой кэша, чтобы он был заказан со смывом. Используйте WRITE_ONCE () для обновления флага удаления, потому что проверка кэша читает флаги, не принимая state_lock.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: wifi: mac80211: fix mesh fast xmit path deletion UAF mesh_fast_tx_cache() stores raw mesh_path pointers. Path deletion flushes the cache and then frees the path with kfree_rcu(), but a lookup that already holds the path can insert a new cache entry after the flush. The cache then points at freed memory. Set MESH_PATH_DELETED before flushing, and skip inserting a cache entry if the path or MPP path is already deleted. Check this under the cache walk lock so it is ordered with the flush. Use WRITE_ONCE() for the deletion flag updates because the cache check reads flags without taking state_lock.