В ядре Linux была устранена следующая уязвимость: block: fix potential valid pointer dereference В функции blk_add_partition The blk_add_partition() изначально использовалось единственное условие if (IS_ERR(part)) для проверки ошибок при добавлении раздела. Это было модифицировано для обработки конкретного случая -ENXIO отдельно, что позволило функции продолжать работу без регистрации ошибки в этом случае. Однако это изменение непреднамеренно оставило путь, по которому md_autodetect_dev() может быть вызван без подтверждения того, что часть является действительным указателем.
Эта фиксация отделяет логику обработки ошибок, разделяя исходное условие if, улучшая читабельность кода и явно обрабатывая конкретные сценарии ошибок. Функция теперь отличает общий случай ошибки от -ENXIO без изменения существующего поведения вызовов md_autodetect_dev().
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: block: fix potential invalid pointer dereference in blk_add_partition The blk_add_partition() function initially used a single if-condition (IS_ERR(part)) to check for errors when adding a partition. This was modified to handle the specific case of -ENXIO separately, allowing the function to proceed without logging the error in this case. However, this change unintentionally left a path where md_autodetect_dev() could be called without confirming that part is a valid pointer. This commit separates the error handling logic by splitting the initial if-condition, improving code readability and handling specific error scenarios explicitly. The function now distinguishes the general error case from -ENXIO without altering the existing behavior of md_autodetect_dev() calls.
Характеристики атаки
Последствия
Строка CVSS v3.1
Тип уязвимости (CWE)
Уязвимые продукты 6
| Конфигурация | От (включительно) | До (исключительно) |
|---|---|---|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
5.5
|
5.10.227
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
5.11
|
5.15.168
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
5.16
|
6.1.113
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.2
|
6.6.54
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.7
|
6.10.13
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.11
|
6.11.2
|