Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\namei.c Create Date:2022-07-28 20:05:00
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:This does the basic permission checking

Proto:static int acl_permission_check(struct inode *inode, int mask)

Type:int

Parameter:

TypeParameterName
struct inode *inode
intmask
295  mode = i_mode
297  If Value is more likely to compile time(uid_eq(current_fsuid(), i_uid)) Then mode >>= 6
299  Else
300  If IS_POSIXACL(inode) && mode & S_IRWXG Then
302  If error != -EAGAIN Then Return error
306  If in_group_p(i_gid) Then mode >>= 3
313  If ( mask & ~mode & ( MAY_READ | MAY_WRITE | MAY_EXEC)) == 0 Then Return 0
315  Return -EACCES
Caller
NameDescribe
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,