函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:aa_task_setrlimit - test permission to set an rlimit*@label - label confining the task (NOT NULL)*@task - task the resource is being set on*@resource - the resource being set*@new_rlim - the new resource limit (NOT NULL)

函数原型:int aa_task_setrlimit(struct aa_label *label, struct task_struct *task, unsigned int resource, struct rlimit *new_rlim)

返回类型:int

参数:

类型参数名称
struct aa_label *label
struct task_struct *task
unsigned intresource
struct rlimit *new_rlim
109  error等于0
111  _read_lock() - mark the beginning of an RCU read-side critical section* When synchronize_rcu() is invoked on one CPU while other CPUs* are within RCU read-side critical sections, then the* synchronize_rcu() is guaranteed to block until after all the other
112  peer等于aa_get_newest_cred_label - obtain the newest label on a cred*@cred: cred to obtain label from (NOT NULL)* Returns: newest version of confining label
113  _read_unlock() - marks the end of an RCU read-side critical section.* In most situations, rcu_read_unlock() is immune from deadlock.* However, in kernels built with CONFIG_RCU_BOOST, rcu_read_unlock()
122  如果label不等于peeraa_capable - test permission to use capability*@label: label being tested for capability (NOT NULL)*@cap: capability to be tested*@opts: CAP_OPT_NOAUDIT bit determines whether audit record is generated* Look up capability in profile capability set.不等于0则error等于fn_for_each(label, profile, audit_resource - audit setting resource limit*@profile: profile being enforced (NOT NULL)*@resource: rlimit being auditing*@value: value being set*@error: error value* Returns: 0 or sa->error else other error code on failure)
128  否则error等于fn_for_each_confined(label, profile, profile_setrlimit(profile, resource, new_rlim))
131  aa_put_label(peer)
133  返回:error
调用者
名称描述
apparmor_task_setrlimit