函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:apable_wrt_inode_uidgid - Check nsown_capable and uid and gid mapped*@inode: The inode in question*@cap: The capability in question* Return true if the current task has the given capability targeted at* its own user namespace and that the given inode's

函数原型:bool capable_wrt_inode_uidgid(const struct inode *inode, int cap)

返回类型:bool

参数:

类型参数名称
const struct inode *inode
intcap
504  ns等于current_user_ns()
506  返回:ns_capable(ns, cap)且privileged_wrt_inode_uidgid - Do capabilities in the namespace work over the inode?*@ns: The user namespace in question*@inode: The inode in question* Return true if the inode uid and gid are within the namespace.
调用者
名称描述
cap_inode_removexattrap_inode_removexattr - Determine whether an xattr may be removed*@dentry: The inode/dentry being altered*@name: The name of the xattr to be changed* Determine whether an xattr may be removed from an inode, returning 0 if
generic_permissiongeneric_permission - check for access rights on a Posix-like filesystem*@inode: inode to check access rights for*@mask: right to check for (%MAY_READ, %MAY_WRITE, %MAY_EXEC,
__check_sticky
inode_init_ownerde_init_owner - Init uid,gid,mode for new inode according to posix standards*@inode: New inode*@dir: Directory inode*@mode: mode of the new inode
chown_ok
chgrp_ok
setattr_preparesetattr_prepare - check if attribute changes to a dentry are allowed*@dentry: dentry to check*@attr: attributes to change* Check if we are allowed to change the attributes contained in @attr* in the given dentry
setattr_copysetattr_copy - copy simple metadata updates into the generic inode*@inode: the inode to be updated*@attr: the new attributes* setattr_copy must be called with i_mutex held.* setattr_copy updates the inode's metadata with that specified* in attr
posix_acl_update_modeposix_acl_update_mode - update mode in set_acl*@inode: target inode*@mode_p: mode (pointer) for update*@acl: acl pointer* Update the file mode when setting an ACL: compute the new file permission* bits based on the ACL
cap_convert_nscapUser requested a write of security.capability. If needed, update the* xattr to change from v2 to v3, or to fixup the v3 rootid.* If all is ok, we return the new size, on error return < 0.