函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\tomoyo\domain.c Create Date:2022-07-27 21:08:47
Last Modify:2022-05-23 20:14:46 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:moyo_write_transition_control - Write "struct tomoyo_transition_control" list.*@param: Pointer to "struct tomoyo_acl_param".*@type: Type of this entry.* Returns 0 on success, negative value otherwise.

函数原型:int tomoyo_write_transition_control(struct tomoyo_acl_param *param, const u8 type)

返回类型:int

参数:

类型参数名称
struct tomoyo_acl_param *param
const u8type
245  struct tomoyo_transition_control e = {One of values in "enum tomoyo_transition_type". = type}
246  error等于如果is_delete则负ENOENT否则负ENOMEM
247  program等于data
248  domainname等于strstr - Find the first substring in a %NUL terminated string*@s1: The string to be searched*@s2: The string to search for
250  如果domainname
251  domainname等于'\0'
252  domainname加等于6
253  否则如果type恒等于TOMOYO_TRANSITION_CONTROL_NO_KEEPtype恒等于TOMOYO_TRANSITION_CONTROL_KEEP
255  domainname等于program
256  program = NULL
258  如果program字符串比较
259  如果非tomoyo_correct_path(program)则返回:负EINVAL
261  Maybe NULL 等于tomoyo_get_name(program)
262  如果非Maybe NULL 则转到:out
265  如果domainname字符串比较
266  如果非tomoyo_correct_domain(domainname)则
267  如果非tomoyo_correct_path(domainname)则转到:out
271  Maybe NULL 等于tomoyo_get_name(domainname)
272  如果非Maybe NULL 则转到:out
275  list等于 List of policy. [TOMOYO_ID_TRANSITION_CONTROL]
276  error等于moyo_update_policy - Update an entry for exception policy.*@new_entry: Pointer to "struct tomoyo_acl_info".*@size: Size of @new_entry in bytes.*@param: Pointer to "struct tomoyo_acl_param".*@check_duplicate: Callback function to find duplicated entry.
278  out :
279  moyo_put_name - Drop reference on "struct tomoyo_name".*@name: Pointer to "struct tomoyo_path_info". Maybe NULL.* Returns nothing.
280  moyo_put_name - Drop reference on "struct tomoyo_name".*@name: Pointer to "struct tomoyo_path_info". Maybe NULL.* Returns nothing.
281  返回:error
调用者
名称描述
tomoyo_write_exceptionmoyo_write_exception - Write exception policy.*@head: Pointer to "struct tomoyo_io_buffer".* Returns 0 on success, negative value otherwise.* Caller holds tomoyo_read_lock().