函数逻辑报告 |
Source Code:security\smack\smack_lsm.c |
Create Date:2022-07-27 20:50:37 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:smack_file_receive - Smack file receive check*@file: the object* Returns 0 if current has access, error code otherwise
函数原型:static int smack_file_receive(struct file *file)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
struct file * | file |
1825 | may等于0 |
1827 | inode等于file_inode(file) |
1832 | 如果此条件成立可能性小(为编译器优化)(IS_PRIVATE(inode))则返回:0 |
1836 | smk_ad_setfield_u_fs_path( & ad, f_path) |
1838 | 如果s_magic恒等于SOCKFS_MAGIC则 |
1840 | ssp等于sk_security |
1841 | tsp等于smack_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.()) |
1848 | rc等于smk_access( label for access control , outbound label , MAY_WRITE, & ad) |
1849 | rc等于smk_bu_file(file, may, rc) |
1852 | rc等于smk_access( inbound label , label for access control , MAY_WRITE, & ad) |
1853 | rc等于smk_bu_file(file, may, rc) |
1854 | 返回:rc |
1859 | 如果f_mode按位与le is open for reading 则may等于MAY_READ |
1861 | 如果f_mode按位与le is open for writing 则may或等于MAY_WRITE |
1865 | rc等于smk_bu_file(file, may, rc) |
1866 | 返回:rc |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |