函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:aa_sk_perm

函数原型:int aa_sk_perm(const char *op, unsigned int request, struct sock *sk)

返回类型:int

参数:

类型参数名称
const char *op
unsigned intrequest
struct sock *sk
167  AA_BUG(!sk)
168  AA_BUG(in_interrupt())
171  label等于gin_current_label_crit_section - current's confining label and update it* Returns: up to date confining label or the ns unconfined label (NOT NULL)* Not safe to call inside locks* The returned reference must be put with end_current_label_crit_section()*
172  error等于aa_label_sk_perm(label, op, request, sk)
173  d_label_crit_section - put a reference found with begin_current_label..*@label: label reference to put* Should only be used with a reference obtained with* begin_current_label_crit_section and never used in situations where the* task cred may be updated
175  返回:error
调用者
名称描述
apparmor_socket_connectapparmor_socket_connect - check perms before connecting @sock to @address
apparmor_socket_listenapparmor_socket_list - check perms before allowing listen
apparmor_socket_acceptapparmor_socket_accept - check perms before accepting a new connection.* Note: while @newsock is created and has some information, the accept* has not been done.
aa_sock_msg_perm
aa_sock_permvaliation, get/set attr, shutdown
aa_sock_opt_permvaliation, get/set attr, opt
apparmor_socket_bindapparmor_socket_bind - check perms before bind addr to socket