logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

p_cansee — determine visibility of a process

Description

       This function can be used to determine if a given process p is visible to the thread td, where the notion
       of “visibility” may be read as “awareness of existence”.

       The function is implemented using cr_cansee(9), and the dependencies on sysctl(8) variables documented in
       the cr_cansee(9) manual page apply.

Errors

       [ESRCH]            Process p is not visible to thread td as determined by cr_cansee(9).

       [ESRCH]            Thread td has been jailed and process p does not belong to the same jail as td.

       [ESRCH]            The MAC subsystem denied visibility.

Name

       p_cansee — determine visibility of a process

Return Values

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

See Also

jail(2), sysctl(8), cr_cansee(9), mac(9), p_candebug(9), prison_check(9)

Debian                                          November 19, 2006                                    P_CANSEE(9)

Synopsis

#include<sys/param.h>#include<sys/proc.h>intp_cansee(structthread*td, structproc*p);

See Also