CVE-2024-56612 Information
Description
In the Linux kernel the following vulnerability has been resolved:
mm/gup: handle NULL pages in unpin_user_pages()
The recent addition of \pofs\ (pages or folios) handling to gup has a flaw: it assumes that unpin_user_pages() handles NULL pages in the pages array. That’s not the case as I discovered when I ran on a new configuration on my test machine.
Fix this by skipping NULL pages in unpin_user_pages() just like unpin_folios() already does.
Details: when booting on x86 with uma=fake=2 movablecore=4G\ on Linux 6.12 and running this:
tools/testing/selftests/mm/gup_longterm
…I get the following crash:
BUG: kernel NULL pointer dereference address: 0000000000000008
RIP: 0010:sanity_check_pinned_pages+0x3a/0x2d0
…
Call Trace:
Reference
https://git.kernel.org/stable/c/69d319450d1c651f3b05cd820ff285fdd810c032 https://git.kernel.org/stable/c/a1268be280d8e484ab3606d7476edd0f14bb9961
Share on: