В ядре Linux устранена следующая уязвимость: rxrpc: исправлена гонка Recv-Recv завершенного вызова. Если вызов получает событие (например, входящие данные), вызов размещается. в очереди сокета, и поток в Recvmsg может быть разбужен для работы и обработать его. Как только поток принял вызов из очереди, дальнейшие события приведут к повторной постановке его в очередь, и как только блокировка сокета будет удален (recvmsg использует call->user_mutex, чтобы разрешить использование сокета в параллельно), может войти второй поток, и его команда Recvmsg может отключить вызов. очередь сокетов снова.
В таком случае первый поток будет получать информацию от вызова и
второй поток будет заблокирован при вызове->user_mutex. Первая ветка
на этом этапе может обработать как событие, для которого выбран вызов, так и
событие, для которого второй поток выбрал вызов и может его увидеть
завершить - в этом случае вызов будет «освобожден», отделив вызов
из назначенного ему идентификатора вызова пользователя (RXRPC_USER_CALL_ID в элементе управления
сообщение). Первый поток вернется нормально, но затем второй поток проснется
удерживая user_mutex, и, если он увидит, что вызов был освобожден
первый поток, это будет ОШИБКА таким образом:
ОШИБКА ядра в net/rxrpc/recvmsg.c:474!
Исправьте это, просто исключив вызов из очереди и проигнорировав его, если он замечен.
уже выпущен.
В любом случае мы не можем сообщить об этом пользовательскому пространству, поскольку пользователь вызывает Идентификатор устарел.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: rxrpc: Fix recv-recv race of completed call If a call receives an event (such as incoming data), the call gets placed on the socket's queue and a thread in recvmsg can be awakened to go and process it. Once the thread has picked up the call off of the queue, further events will cause it to be requeued, and once the socket lock is dropped (recvmsg uses call->user_mutex to allow the socket to be used in parallel), a second thread can come in and its recvmsg can pop the call off the socket queue again. In such a case, the first thread will be receiving stuff from the call and the second thread will be blocked on call->user_mutex. The first thread can, at this point, process both the event that it picked call for and the event that the second thread picked the call for and may see the call terminate - in which case the call will be "released", decoupling the call from the user call ID assigned to it (RXRPC_USER_CALL_ID in the control message). The first thread will return okay, but then the second thread will wake up holding the user_mutex and, if it sees that the call has been released by the first thread, it will BUG thusly: kernel BUG at net/rxrpc/recvmsg.c:474! Fix this by just dequeuing the call and ignoring it if it is seen to be already released. We can't tell userspace about it anyway as the user call ID has become stale.
Характеристики атаки
Последствия
Строка CVSS v3.1
Тип уязвимости (CWE)
Уязвимые продукты 9
| Конфигурация | От (включительно) | До (исключительно) |
|---|---|---|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
4.9
|
6.6.100
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.7
|
6.12.40
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.13
|
6.15.8
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc1:*:*:*:*:*:*
|
— | — |
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc2:*:*:*:*:*:*
|
— | — |
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc3:*:*:*:*:*:*
|
— | — |
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc4:*:*:*:*:*:*
|
— | — |
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc5:*:*:*:*:*:*
|
— | — |
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:6.16:rc6:*:*:*:*:*:*
|
— | — |