Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\smack\smack_lsm.c Create Date:2022-07-28 19:22:38
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:smack_socket_post_create - finish socket setup*@sock: the socket*@family: protocol family*@type: unused*@protocol: unused*@kern: unused* Sets the netlabel information on the socket* Returns 0 on success, and error code otherwise

Proto:static int smack_socket_post_create(struct socket *sock, int family, int type, int protocol, int kern)

Type:int

Parameter:

TypeParameterName
struct socket *sock
intfamily
inttype
intprotocol
intkern
2755  If (sk == NULL) Then Return 0
2761  If Value for the false possibility is greater at compile time(flags & I am a kernel thread ) Then
2762  ssp = sk_security
2763  inbound label = smack_known_web
2764  outbound label = smack_known_web
2767  If family != PF_INET Then Return 0
2772  Return smack_netlabel - Set the secattr on a socket*@sk: the socket*@labeled: socket label scheme* Convert the outbound smack value (smk_out) to a* secattr and attach it to the socket.* Returns 0 on success or an error code