函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\commoncap.c Create Date:2022-07-27 20:10:35
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:1) Audit candidate if current->cap_effective is set* We do not bother to audit if 3 things are true:* 1) cap_effective has all caps* 2) we became root *OR* are were already root* 3) root is supposed to have all caps (SECURE_NOROOT)

函数原型:static inline bool nonroot_raised_pE(struct cred *new, const struct cred *old, kuid_t root, bool has_fcap)

返回类型:bool

参数:

类型参数名称
struct cred *new
const struct cred *old
kuid_troot
boolhas_fcap
780  bool ret = false
782  如果__cap_grew(effective, ambient, new)且非__cap_full(effective, new)且__is_eff(root, new)或__is_real(root, new)的值且root_privileged()的值或root_privileged()且__is_suid(root, new)且非__cap_full(effective, new)或非__is_setuid(new, old)且has_fcap__cap_gained(permitted, new, old)或__cap_gained(ambient, new, old)的值则ret = true
796  返回:ret
调用者
名称描述
cap_bprm_set_credsap_bprm_set_creds - Set up the proposed credentials for execve().*@bprm: The execution parameters, including the proposed creds* Set up the proposed credentials for a new execution context being* constructed by execve()