DTRACE_PRIV(4)
π DTRACE_PRIV(4) π
okay so bestie, welcome to the Kernel Interfaces Manual page for dtrace_priv. Yes, that's DTRACE_PRIV(4) β a DTrace provider for the kernel privilege checking API. It's giving observability, but make it cute. β¨
πΈ NAME πΈ
dtrace_priv β a DTrace provider for the kernel privilege checking API π
π¦ SYNOPSIS π¦
priv:kernel:priv_check:priv-ok
priv:kernel:priv_check:priv-err
β¨ DESCRIPTION β¨
The priv provider lets you trace the priv(9) API. No cap.
The priv:kernel:priv_check:priv-ok probe fires when a kernel privilege check succeeds. Slay. π
The priv:kernel:priv_check:priv-err probe fires when a kernel privilege check fails. π
The only argument to the priv probes, args[0], is the requested privilege number int priv. That's it β that's the whole argument situation. π«Ά
π EXAMPLES π
Example 1: Tracing Kernel Privilege Check Failures
The following script captures an array of counters, one for each stack trace leading to a failed kernel privilege check. Literally doing the most for diagnostics. π₯
priv:::priv-err
{
@traces[stack()] = count();
}
π SEE ALSO π
π AUTHORS π
The priv provider was written by Robert N. M. Watson <rwatson@FreeBSD.org>. π«‘
This manual page was written by Mateusz Piotrowski <0mp@FreeBSD.org>. π
mwah π β brought to you by the Debian crew, dated November 12, 2025 πβ¨
π¦ where this page comes from
- freebsd 14.5: base 14.5
- freebsd 15.1: base 15.1
- π the page's license: BSD-2-Clause
- Copyright (c) 2025 Mateusz Piotrowski <0mp@FreeBSD.org>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms