函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:aa_xattrs_match - check whether a file matches the xattrs defined in profile*@bprm: binprm struct for the process to validate*@profile: profile to match against (NOT NULL)*@state: state to start match in* Returns: number of extended attributes that

函数原型:static int aa_xattrs_match(const struct linux_binprm *bprm, struct aa_profile *profile, unsigned int state)

返回类型:int

参数:

类型参数名称
const struct linux_binprm *bprm
struct aa_profile *profile
unsigned intstate
315  char * value = NULL
316  value_size等于0, ret等于xattr_count
318  如果非bprm或非xattr_count则返回:0
320  might_sleep()
323  state等于aa_dfa_null_transition - step to next state after null character*@dfa: the dfa to match against*@start: the state of the dfa to start matching in* aa_dfa_null_transition transitions to the next state after a null* character which is not used in standard
325  d等于dentry
327 i小于xattr_count循环
328  size等于vfs_getxattr_alloc(d, xattrs[i], & value, value_size, GFP_KERNEL)
330  如果size大于等于0则
337  如果非perm按位与MAY_EXEC的值则
338  ret等于负EINVAL
339  转到:out
343  state等于aa_dfa_null_transition - step to next state after null character*@dfa: the dfa to match against*@start: the state of the dfa to start matching in* aa_dfa_null_transition transitions to the next state after a null* character which is not used in standard
344  如果size小于0则
350  如果非state
351  ret等于负EINVAL
352  转到:out
355  ret自减
359  out :
360  释放内存
361  返回:ret
调用者
名称描述
find_attachd_attach - do attachment search for unconfined processes*@bprm - binprm structure of transitioning task*@ns: the current namespace (NOT NULL)*@head - profile list to walk (NOT NULL)*@name - to match against (NOT NULL)*@info - info message if there was an
profile_transition