函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:mod_check_sig - check that the given signature is sane*@ms: Signature to check.*@file_len: Size of the file to which @ms is appended.*@name: What is being checked. Used for error messages.

函数原型:int mod_check_sig(const struct module_signature *ms, size_t file_len, const char *name)

返回类型:int

参数:

类型参数名称
const struct module_signature *ms
size_tfile_len
const char *name
24  如果be32_to_cpu(Length of signature data )大于等于file_lenms的长度则返回:负EBADMSG
27  如果Key identifier type [PKEY_ID_PKCS7] 不等于 Signature in PKCS#7 message
28  打印错误信息("%s: Module is not signed with expected PKCS#7 message\n", name)
30  返回:负ENOPKG
33  如果Public-key crypto algorithm [0] 不等于0或Digest algorithm [0] 不等于0或Length of signer's name [0] 不等于0或Length of key identifier [0] 不等于0或__pad[0]不等于0或__pad[1]不等于0或__pad[2]不等于0则
40  打印错误信息("%s: PKCS#7 signature info has unexpected non-zero params\n", name)
42  返回:负EBADMSG
45  返回:0
调用者
名称描述
mod_verify_sigVerify the signature on a module.
ima_read_modsigma_read_modsig - Read modsig from buf.* Return: 0 on success, error code otherwise.