GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
P_CANDEBUG(9) FreeBSD Kernel Developer's Manual P_CANDEBUG(9)

p_candebug
determine debuggability of a process

#include <sys/param.h>
#include <sys/proc.h>

int
p_candebug(struct thread *td, struct proc *p);

This function can be used to determine if a given process p is debuggable by the thread td.

The following sysctl(8) variables directly influence the behaviour of p_candebug():
kern.securelevel
Debugging of the init process is not allowed if this variable is 1 or greater.
security.bsd.unprivileged_proc_debug
Must be set to a non-zero value to allow unprivileged processes access to the kernel's debug facilities.

The p_candebug() function returns 0 if the process denoted by p is debuggable by thread td, or a non-zero error return value otherwise.

[]
The MAC subsystem denied debuggability.
[]
Process p is in the process of being exec()'ed.
[]
Thread td lacks super-user credentials and process p is executing a set-user-ID or set-group-ID executable.
[]
Thread td lacks super-user credentials and process p's group set is not a subset of td's effective group set.
[]
Thread td lacks super-user credentials and process p's user IDs do not match thread td's effective user ID.
[]
Process p denotes the initial process initproc() and the sysctl(8) variable kern.securelevel is greater than zero.
[]
Process p is not visible to thread td as determined by cr_seeotheruids(9) or cr_seeothergids(9).
[]
Thread td has been jailed and process p does not belong to the same jail as td.
[]
The MAC subsystem denied debuggability.

jail(2), sysctl(8), cr_seeothergids(9), cr_seeotheruids(9), mac(9), p_cansee(9), prison_check(9)
November 19, 2006 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 9 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.