libkernel: sceKernelAvailableDirectMemorySize, sceKernelGetDirectMemoryType and sceKernelDirectMemoryQuery fault on invalid memory pointers #13566
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by pushkarreddyy on 2026-10-30T18:30:13Z.
Environment
0a90776f7f(main)Describe the bug
sceKernelAvailableDirectMemorySize,sceKernelGetDirectMemoryType, andsceKernelDirectMemoryQuerydirectly dereference guest output pointers (phys_addr_out,size_out,memory_type,start,end, andinfo). When a guest passes a non-null pointer into unmapped or read-only memory, the host process crashes withSIGSEGVinstead of returningSCE_KERNEL_ERROR_EFAULT(0x8002000e).Expected behavior
Invalid or unwritable guest pointers should be safely checked via
GuestCopyOut_nid_no_patchand returnSCE_KERNEL_ERROR_EFAULT.