函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:selinux_file_mprotect

函数原型:static int selinux_file_mprotect(struct vm_area_struct *vma, unsigned long reqprot, unsigned long prot)

返回类型:int

参数:

类型参数名称
struct vm_area_struct *vma
unsigned longreqprot
unsigned longprot
3739  cred等于current_cred - Access the current task's subjective credentials* Access the subjective credentials of the current task. RCU-safe,* since nobody else can modify it.()
3740  sid等于get the security ID of a set of credentials
3742  如果checkreqprotprot等于reqprot
3745  如果default_noexecprot按位与page can be executed 且非Flags, see mm.h. 按位与VM_EXEC的值则
3747  rc等于0
3770  如果rc则返回:rc
3774  返回:file_map_prot_check(File we map to (can be NULL). , prot, Flags, see mm.h. & VM_SHARED)