函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:handle_privileged_root - Handle case of privileged root*@bprm: The execution parameters, including the proposed creds*@has_fcap: Are any file capabilities set?*@effective: Do we have effective root privilege?*@root_uid: This namespace' root UID WRT

函数原型:static void handle_privileged_root(struct linux_binprm *bprm, bool has_fcap, bool *effective, kuid_t root_uid)

返回类型:void

参数:

类型参数名称
struct linux_binprm *bprm
boolhas_fcap
bool *effective
kuid_troot_uid
716  old等于current_cred - Access the current task's subjective credentials* Access the subjective credentials of the current task. RCU-safe,* since nobody else can modify it.()
717  new等于w credentials
719  如果非root_privileged()则返回
726  如果has_fcap__is_suid(root_uid, new)则
727  If a non-root user executes a setuid-root binary in* !secure(SECURE_NOROOT) mode, then we raise capabilities
728  返回
735  如果__is_eff(root_uid, new)或__is_real(root_uid, new)则
737  caps we're permitted 等于cap_combine( capability bounding set , caps our children can inherit )
743  如果__is_eff(root_uid, new)则 * effective = true
调用者
名称描述
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()