函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:sverity_ioctl_measure() - get a verity file's measurement* Retrieve the file measurement that the kernel is enforcing for reads from a* verity file

函数原型:int fsverity_ioctl_measure(struct file *filp, void __user *_uarg)

返回类型:int

参数:

类型参数名称
struct file *filp
void __user *_uarg
23  inode等于file_inode(filp)
24  __useruarg等于_uarg
29  vi等于fsverity_get_info(inode)
30  如果非vi则返回:负ENODATA
32  hash_alg等于he hash algorithm
40  如果Careful: we have to cast the result to the type of the pointer* for sign reasons( input/output , & input/output )则返回:负EFAULT
42  如果 input/output 小于digest size in bytes, e.g. 32 for SHA-256 则返回:负EOVERFLOW
45  memset( & arg, 0, arg的长度)
46  digest_algorithm等于hash_algThe hash algorithms supported by fs-verity
47  input/output 等于digest size in bytes, e.g. 32 for SHA-256
49  如果copy_to_user(uarg, & arg, arg的长度)则返回:负EFAULT
52  如果copy_to_user(digest, measurement, digest size in bytes, e.g. 32 for SHA-256 )则返回:负EFAULT
55  返回:0