В ядре Linux была устранена следующая уязвимость: net/sched: sch_qfq: предотвращает агрегированную самозамену qfq_change_class() снимков текущих параметров агрегации при удержании замка дерева qdisc, но сбрасывает блокировку перед выбором агрегата назначения. Во время этого разрыва qfq_enqueue () может перемещать класс в агрегат, соответствующий запрошенным параметрам. Когда qfq_change_class () возобновляется, qfq_find_agg () затем возвращает cl->agg.
Если это синглтон, qfq_deact_rm_from_agg() освобождает агрегат до того, как qfq_add_to_agg() немедленно обращается к тому же указателю, вызывая use-after-free. Удерживая блокировку дерева, пропустите замену, когда пункт назначения уже является текущим агрегатом. Любая замена оценщика уже завершена, поэтому изменение класса может закончиться нормально.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: net/sched: sch_qfq: prevent aggregate self-replacement qfq_change_class() snapshots the current aggregate settings while holding the qdisc tree lock, but drops the lock before selecting the destination aggregate. During that gap, qfq_enqueue() can move the class to an aggregate matching the requested settings. When qfq_change_class() resumes, qfq_find_agg() then returns cl->agg. If it is a singleton, qfq_deact_rm_from_agg() frees the aggregate before qfq_add_to_agg() immediately accesses the same pointer, causing a use-after-free. While holding the tree lock, skip the replacement when the destination is already the current aggregate. Any estimator replacement has already completed, so the class change can finish normally.
Характеристики атаки
Последствия
Строка CVSS v3.1