函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Calculate the hmac and update security.evm xattr* Expects to be called with i_mutex locked.

函数原型:int evm_update_evmxattr(struct dentry *dentry, const char *xattr_name, const char *xattr_value, size_t xattr_value_len)

返回类型:int

参数:

类型参数名称
struct dentry *dentry
const char *xattr_name
const char *xattr_value
size_txattr_value_len
305  inode等于d_backing_inode - Get upper or lower inode we should be using*@upper: The upper layer* This is the helper that should be used to get at the inode that will be used* if this dentry were to be opened as a file. The inode may be on the upper
307  rc等于0
313  rc等于evm_is_immutable(dentry, inode)
314  如果rc小于0则返回:rc
316  如果rc则返回:负EPERM
319  algo等于HASH_ALGO_SHA1
320  rc等于evm_calc_hmac(dentry, xattr_name, xattr_value, xattr_value_len, & data)
322  如果rc恒等于0则
323  type等于EVM_XATTR_HMAC
324  rc等于__vfs_setxattr_noperm(dentry, XATTR_NAME_EVM, & data[1], SHA1_DIGEST_SIZE + 1, 0)
327  否则如果rc恒等于负ENODATAi_opflags按位与IOP_XATTR
328  rc等于__vfs_removexattr(dentry, XATTR_NAME_EVM)
330  返回:rc
调用者
名称描述
evm_inode_post_setxattrvm_inode_post_setxattr - update 'security
evm_inode_post_removexattrvm_inode_post_removexattr - update 'security
evm_inode_post_setattrvm_inode_post_setattr - update 'security