libkernel: sceKernelGetModuleList and sceKernelGetModuleInfo fault on invalid memory pointers #13569

Closed
opened 2026-10-30 18:31:03 +00:00 by pushkarreddyy · 0 comments
pushkarreddyy commented 2026-10-30 18:31:03 +00:00 (Migrated from github.com)
Contributor

Imported from boykopovar/AnyPS5. Originally posted by pushkarreddyy on 2026-10-30T18:31:03Z.


Environment

  • AnyPS5 commit: 0a90776f7f (main)
  • Title: PS5 system software / module query callers

Describe the bug

FillModuleList and FillModuleInfo (underlying sceKernelGetModuleList, sceKernelGetModuleList2, sceKernelGetModuleInfo, and sceKernelGetModuleInfo2) directly dereference and write through handles, actual, and info guest pointers. If a non-null invalid or unwritable guest address is passed, the host crashes with a segmentation fault (SIGSEGV) instead of returning SCE_KERNEL_ERROR_EFAULT (0x8002000e).

Expected behavior

Guest output buffers (handles, actual, info) should be verified via GuestCopyOut_nid_no_patch and GuestCopyIn_nid_no_patch, returning SCE_KERNEL_ERROR_EFAULT if guest memory is invalid or unwritable.

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:6124842374 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/13569). Originally posted by [pushkarreddyy](https://github.com/pushkarreddyy) on 2026-10-30T18:31:03Z. --- ### Environment - AnyPS5 commit: 0a90776f7f (main) - Title: PS5 system software / module query callers ### Describe the bug `FillModuleList` and `FillModuleInfo` (underlying `sceKernelGetModuleList`, `sceKernelGetModuleList2`, `sceKernelGetModuleInfo`, and `sceKernelGetModuleInfo2`) directly dereference and write through `handles`, `actual`, and `info` guest pointers. If a non-null invalid or unwritable guest address is passed, the host crashes with a segmentation fault (`SIGSEGV`) instead of returning `SCE_KERNEL_ERROR_EFAULT` (`0x8002000e`). ### Expected behavior Guest output buffers (`handles`, `actual`, `info`) should be verified via `GuestCopyOut_nid_no_patch` and `GuestCopyIn_nid_no_patch`, returning `SCE_KERNEL_ERROR_EFAULT` if guest memory is invalid or unwritable.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5#13569
No description provided.