函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Implement PR_CAPBSET_DROP. Attempt to remove the specified capability from* the current task's bounding set. Returns 0 on success, -ve on error.

函数原型:static int cap_prctl_drop(unsigned long cap)

返回类型:int

参数:

类型参数名称
unsigned longcap
1143  如果非ns_capable(current_user_ns(), Without VFS support for capabilities:* Transfer any capability in your permitted set to any pid,* remove any capability in your permitted set from any pid* With VFS support for capabilities (neither of above, but)* Add any capability from current's )则返回:负EPERM
1145  如果非cap_valid(cap)则返回:负EINVAL
1148  new等于prepare_creds - Prepare a new set of credentials for modification* Prepare a new set of task credentials for modification
1149  如果非new则返回:负ENOMEM
1151  cap_lower( capability bounding set , cap)
1152  返回:mmit_creds - Install new credentials upon the current task*@new: The credentials to be assigned* Install a new set of credentials to the current task, using RCU to replace* the old set. Both the objective and the subjective credentials pointers are
调用者
名称描述
cap_task_prctlap_task_prctl - Implement process control functions for this security module*@option: The process control function requested*@arg2, @arg3, @arg4, @arg5: The argument data for this function* Allow process control functions (sys_prctl()) to alter