Skip to content
BSD syscall#185

svc · unix #185

sys_panic_with_data

Privileged syscall used to trigger a kernel panic with an attached userspace payload.

Prototype

int sys_panic_with_data(uuid_t uuid, void *addr, uint32_t len, uint32_t flags, const char *msg);

Returns: int

Arguments

NameTypeDirDescription
uuiduuid_t-
addrvoid-
lenuint32_t-
flagsuint32_t-
msgconst char-

Version history

XNU tagmacOS#
xnu-10002.1.13macOS 14.0 Sonoma185
xnu-11215.1.10macOS 15.0 Sequoia185
xnu-11417.101.15macOS 15.4 Sequoia185
xnu-12377.1.9macOS 26.0 Tahoe185
xnu-10002.41.9185
xnu-10002.61.3185
xnu-10002.81.5185
xnu-10063.101.15185
xnu-10063.121.3185
xnu-10063.141.1185
xnu-11215.41.3185
xnu-11215.61.5185
xnu-11215.81.4185
xnu-11417.121.6185
xnu-11417.140.69185
xnu-12377.101.15185
xnu-12377.41.6185
xnu-12377.61.12185
xnu-12377.81.4185

Notes

Apple-internal diagnostic primitive: a tightly-entitled tool can ask the kernel to panic, attaching up to 1 KiB of context that ends up in the resulting panic.ips. Used by RootlessJB-era debug builds and by Apple QA to harvest crash dumps after a userspace anomaly. On release builds it requires com.apple.private.allow-panic-with-data and is otherwise ENOSYS.

Detection

By definition any successful call generates a panic; the system reboots and the resulting panic.ips appears in /Library/Logs/DiagnosticReports. Treat any such artifact whose calling image is not Apple-signed as a critical incident.

Related APIs

os_fault_with_payloadproc_trace_logReportCrashsysctlbyname