В ядре Linux была устранена следующая уязвимость: wifi: mac80211: сохранить парный старый chanctx Замена на месте сохраняет взаимные указатели replace_ctx между старым WILL_BE_REPLACED chanctx и новым REPLACES_OTHER chanctx. Тем не менее, ранние бесплатные пути учитывают только назначенных и зарезервированных пользователей ссылок при принятии решения о том, освобождать ли старый chanctx. Это позволяет освободить старый chanctx слишком рано, в то время как партнер по замене все еще указывает на него, либо когда последняя назначенная ссылка освобождена, либо когда эта ссылка успешно перенаправляется в другой существующий контекст.
Более поздние пути без резервирования и коммутационного завершения могут следовать за устаревшим указателем replace_ctx. Сохраняйте старый chanctx живым до тех пор, пока не будет снесена замещающая пара. Примените одну и ту же проверку к __ieee80211_link_release_channel() и ieee80211_link_use_reserved_reassign().
Если замена позже отменяется, ieee80211_link_unreserve_chanctx () уже разрывает сопряжение, прежде чем освободить старый chanctx, как только не останется пользователей.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: wifi: mac80211: keep paired old chanctx alive An in-place replacement keeps reciprocal replace_ctx pointers between the old WILL_BE_REPLACED chanctx and the new REPLACES_OTHER chanctx. However, the early free paths only consider assigned and reserved link users when deciding whether to free the old chanctx. That lets the old chanctx be freed too early while the replacement partner still points back to it, either when the last assigned link is released or when that link successfully reassigns to another existing context. Later unreserve and switch-finalization paths can then follow a stale replace_ctx pointer. Keep a paired old chanctx alive until the replacement pair has been torn down. Apply the same check to both __ieee80211_link_release_channel() and ieee80211_link_use_reserved_reassign(). If the replacement is later abandoned, ieee80211_link_unreserve_chanctx() already tears down the pairing before freeing the old chanctx once no users remain.