函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\inode.c Create Date:2022-07-29 10:38:08
Last Modify:2020-03-18 19:19:59 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Return mask of changes for notify_change() that need to be done as a* response to write or truncate. Return 0 if nothing has to be changed.* Negative value on error (change should be denied).

函数原型:int dentry_needs_remove_privs(struct dentry *dentry)

返回类型:int

参数:

类型参数名称
struct dentry *dentry
1804  inode等于获得目录项的索引节点
1805  mask等于0
1808  如果IS_NOSEC(inode)则返回:0
1811  mask等于The logic we want is* if suid or (sgid and xgrp)* remove privs
1812  ret等于security_inode_need_killpriv(dentry)
1813  如果ret小于0则返回:ret
1815  如果retmask或等于ATTR_KILL_PRIV
1817  返回:mask
调用者
名称描述
file_remove_privsRemove special file priviledges (suid, capabilities) when file is written* to or truncated.