函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\tomoyo\common.c Create Date:2022-07-27 21:03:15
Last Modify:2020-03-18 09:15:18 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:moyo_flush - Flush queued string to userspace's buffer.*@head: Pointer to "struct tomoyo_io_buffer".* Returns true if all data was flushed, false otherwise.

函数原型:static bool tomoyo_flush(struct tomoyo_io_buffer *head)

返回类型:bool

参数:

类型参数名称
struct tomoyo_io_buffer *head
215 w_pos循环
216  w等于w[0]
217  len等于strlen - Find the length of a string*@s: The string to be sized
219  如果len
222  如果非len则返回:false
224  如果copy_to_user(read_user_buf, w, len)则返回:false
226  read_user_buf_avail减等于len
227  read_user_buf加等于len
228  w加等于len
230  w[0]等于w
231  如果w则返回:false
234  如果poll
235  如果非read_user_buf_availcopy_to_user(read_user_buf, "", 1)则返回:false
238  read_user_buf_avail自减
239  read_user_buf自加
241  w_pos自减
242 len小于w_pos循环w[len]等于w[len + 1]
245  avail等于0
246  返回:true
调用者
名称描述
tomoyo_set_stringmoyo_set_string - Queue string to "struct tomoyo_io_buffer" structure
tomoyo_read_profilemoyo_read_profile - Read profile table.*@head: Pointer to "struct tomoyo_io_buffer".* Returns nothing.
tomoyo_read_managermoyo_read_manager - Read manager policy.*@head: Pointer to "struct tomoyo_io_buffer".* Caller holds tomoyo_read_lock().
tomoyo_print_conditionmoyo_print_condition - Print condition part.*@head: Pointer to "struct tomoyo_io_buffer".*@cond: Pointer to "struct tomoyo_condition".* Returns true on success, false otherwise.
tomoyo_print_entrymoyo_print_entry - Print an ACL entry.*@head: Pointer to "struct tomoyo_io_buffer".*@acl: Pointer to an ACL entry.* Returns true on success, false otherwise.
tomoyo_read_domainmoyo_read_domain - Read domain policy.*@head: Pointer to "struct tomoyo_io_buffer".* Caller holds tomoyo_read_lock().
tomoyo_read_groupmoyo_read_group - Read "struct tomoyo_path_group"/"struct tomoyo_number_group"/"struct tomoyo_address_group" list.*@head: Pointer to "struct tomoyo_io_buffer".*@idx: Index number.* Returns true on success, false otherwise.* Caller holds tomoyo_read_lock().
tomoyo_read_policymoyo_read_policy - Read "struct tomoyo_..._entry" list.*@head: Pointer to "struct tomoyo_io_buffer".*@idx: Index number.* Returns true on success, false otherwise.* Caller holds tomoyo_read_lock().
tomoyo_read_controlmoyo_read_control - read() for /sys/kernel/security/tomoyo/ interface.*@head: Pointer to "struct tomoyo_io_buffer".*@buffer: Poiner to buffer to write to.*@buffer_len: Size of @buffer.* Returns bytes read on success, negative value otherwise.