В ядре Linux устранена следующая уязвимость:
Accel/amxdna: исправлены ошибки вставки страниц в amdxdna_insert_pages(). Два пути ошибки в amdxdna_insert_pages(), называемые vma->vm_ops-> close(vma)
перед возвратом кода ошибки вызывающему абоненту. Это неверно:
amdxdna_gem_obj_mmap() регистрирует уведомитель интервала HMM перед вызовом
amdxdna_insert_pages(), а в случае серьезной ошибки он переходит к hmm_unreg для отмены
та регистрация.
Вызов vm_ops->close() вручную — при этом удаляется
shmempages_pin_count и ссылка на объект GEM, который поддерживает VMA —
еще до того, как системный вызов mmap вернет результат, эти ресурсы будут
выпущен, пока VMA еще жива. Разбор ядра VMA вызовет
vm_ops->close() во второй раз, когда процесс позже отобразит диапазон,
создание опустошения счетчика ссылок. Замените оба возврата серьезных ошибок подходом с отложенной ошибкой, который сохраняет
VMA активен и пытается вставить страницу через путь ошибки диапазона HMM.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: accel/amxdna: Fix page-insertion errors in amdxdna_insert_pages() Two error paths in amdxdna_insert_pages() called vma->vm_ops->close(vma) before returning an error code to the caller. This is incorrect: amdxdna_gem_obj_mmap() registers an HMM interval notifier before calling amdxdna_insert_pages(), and on a hard error it jumps to hmm_unreg to undo that registration. Calling vm_ops->close() manually — which drops the shmem pages_pin_count and the GEM object reference that backs the VMA — before the mmap syscall has even returned causes those resources to be released while the VMA is still alive. The kernel VMA teardown will call vm_ops->close() a second time when the process later unmaps the range, producing a reference count underflow. Replace both hard-error returns with a deferred-fault approach that keeps the VMA alive and retries page insertion through the HMM range-fault path.
Характеристики атаки
Последствия
Строка CVSS v3.1
Уязвимые продукты 2
| Конфигурация | От (включительно) | До (исключительно) |
|---|---|---|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.16
|
7.1.9
|
|
Linux Linux_Kernel
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
|
6.16
|
7.2
|