函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:moyo_inet_entry - Check permission for INET network operation.*@address: Pointer to "struct tomoyo_addr_info".* Returns 0 on success, negative value otherwise.

函数原型:static int tomoyo_inet_entry(const struct tomoyo_addr_info *address)

返回类型:int

参数:

类型参数名称
const struct tomoyo_addr_info *address
469  idx等于moyo_read_lock - Take lock for protecting policy.* Returns index number for tomoyo_read_unlock().
471  error等于0
472  type等于Mapping table from "enum tomoyo_network_acl_index" to* "enum tomoyo_mac_index" for inet domain socket.[protocol][operation]
474  如果typetomoyo_init_request_info( & r, NULL, type)不等于TOMOYO_CONFIG_DISABLED
476  param_type等于TOMOYO_TYPE_INET_ACL
477  One of values smaller than TOMOYO_SOCK_MAX. 等于protocol
478  One of values in "enum tomoyo_network_acl_index". 等于operation
479  is_ipv6等于is_ipv6
480  address等于In network byte order.
481  port等于ntohs(In network byte order. )
482  循环
485 error恒等于Retry this request. Returned by tomoyo_supervisor() if policy violation has* occurred in enforcing mode and the userspace daemon decided to retry.* We must choose a positive value in order to distinguish "granted" (which is循环
487  moyo_read_unlock - Release lock for protecting policy.*@idx: Index number returned by tomoyo_read_lock().* Returns nothing.
488  返回:error
调用者
名称描述
tomoyo_check_inet_addressmoyo_check_inet_address - Check permission for inet domain socket's operation.*@addr: Pointer to "struct sockaddr".*@addr_len: Size of @addr.*@port: Port number.*@address: Pointer to "struct tomoyo_addr_info".