函数逻辑报告 |
Source Code:security\apparmor\path.c |
Create Date:2022-07-27 21:29:41 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:d_namespace_path - lookup a name associated with a given path*@path: path to lookup (NOT NULL)*@buf: buffer to store path to (NOT NULL)*@name: Returns - pointer for start of path name with in @buf (NOT NULL)*@flags: flags controlling path
函数原型:static int d_namespace_path(const struct path *path, char *buf, char **name, int flags, const char *disconnected)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
const struct path * | path | |
char * | buf | |
char ** | name | |
int | flags | |
const char * | disconnected |
92 | error等于0 |
93 | connected等于1 |
94 | isdir等于如果flags按位与 path is a directory 则1否则0 |
95 | buflen等于aa_g_path_max减isdir |
97 | 如果mnt_flags按位与MNT_INTERNAL则 |
99 | res等于dentry_path(dentry, buf, buflen) |
101 | 如果是错误则 |
105 | 如果s_magic恒等于PROC_SUPER_MAGIC且字符串指定长度比较恒等于0则 |
111 | 转到:out |
112 | 否则error等于If the path is not connected to the expected root,* check if it is a sysctl and handle specially else remove any* leading / that __d_path may have returned |
115 | 转到:out |
119 | 如果flags按位与 do path lookup relative to chroot 则 |
124 | 否则 |
151 | 如果非connected则error等于If the path is not connected to the expected root,* check if it is a sysctl and handle specially else remove any* leading / that __d_path may have returned |
160 | 如果d_unlinked(dentry)且d_is_positive(dentry)且非flags按位与 mediate deleted paths 按位或 delegate deleted files 的值的值则 |
166 | out : |
171 | 如果(!error && isdir && () != '\0' || ) != '/'))则strcpy( & buf[aa_g_path_max - 2], "/") |
174 | 返回:error |
名称 | 描述 |
---|---|
aa_path_name | aa_path_name - get the pathname to a buffer ensure dir / is appended*@path: path the file (NOT NULL)*@flags: flags controlling path name generation*@buffer: buffer to put name in (NOT NULL)*@name: Returns - the generated path name if !error (NOT |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |