PT-2026-151674
CVE-2026-99463
·
Publicado
2026-11-19
·
Atualizado
2026-11-19
Descrição por
Pontuação
N/A
Não disponívelNão há classificações de severidade ou métricas disponíveis. Quando houver, atualizaremos as informações correspondentes na página.
In the Linux kernel, the following vulnerability has been resolved:
mm/rmap: don't discard lazyfree THPs at PMD level
discard anon folio pmd locked() clears a lazyfree THP's PMD before it
determines whether the folio can be discarded, and restores it if the
folio is dirty or has extra references. It is done under only the PMD
lock and the anon vma read lock inside try to unmap one() and no mmap lock
is held. The temporarily none PMD causes UAF.
A parallel munmap() or mremap() is supposed to serialize with it on the
PMD lock, but zap pmd range() (called by munmap()) and move page tables()
(called by mremap()) do not take the lock when they see the temporarily
none PMD and skip the PMD. There is no more page table walk after the
none PMD is restored:
-
munmap(): free pgtables() waits in unlink anon vmas() for the anon vma lock, then free pmd range() drops the restored PMD as bad without removing the rmap, so the folio keeps a stale mapcount.
-
whole-VMA MREMAP DONTUNMAP: dontunmap complete() unlinks the source VMA from its anon vma while the restored PMD still maps the folio.
-
plain mremap(): the THP is not moved but unmapped, so the THP's data is lost.
In the first two cases, the folio stays mapped, but no VMA that maps it is
linked to its anon vma. When the anon vma is freed, it is still reachable
when one rmap walks the folio. Racing lazyfree reclaim against
MREMAP DONTUNMAP as an unprivileged user reproduces a KASAN use-after-free
in folio lock anon vma read() as reported in the Closes link.
One solution is to use an invalidated PMD instead of a cleared one until
the discard is committed, but it needs arch fixes first.
- GUP-fast still follows an invalidated PMD on riscv, LoongArch and s390.
- sparc64 miscounts thp pte count when an invalidated PMD is set again or cleared.
To keep the fix simple for backport, stop discarding lazyfree THPs at PMD
level instead. try to unmap one() splits the PMD and discards the folio at
PTE level.
unmap huge pmd locked() and discard anon folio pmd locked() are left in
place, unused, to minimize this fix for backport and the invalidated PMD
approach is planned as a follow-up series to use them again.
Encontrou algum problema na descrição? Tem algo a acrescentar? Fique à vontade para nos escrever 👾