/security/selinux/include/ |
H A D | netlabel.h | 34 #include <net/sock.h> 57 void selinux_netlbl_inet_csk_clone(struct sock *sk, u16 family); 58 int selinux_netlbl_socket_post_create(struct sock *sk, u16 family); 63 int selinux_netlbl_socket_setsockopt(struct socket *sock, 66 int selinux_netlbl_socket_connect(struct sock *sk, struct sockaddr *addr); 109 static inline int selinux_netlbl_conn_setsid(struct sock *sk, 120 static inline void selinux_netlbl_inet_csk_clone(struct sock *sk, u16 family) 124 static inline int selinux_netlbl_socket_post_create(struct sock *sk, 136 static inline int selinux_netlbl_socket_setsockopt(struct socket *sock, argument 142 static inline int selinux_netlbl_socket_connect(struct sock *s [all...] |
H A D | avc.h | 35 struct sock;
|
/security/selinux/ |
H A D | netlabel.c | 35 #include <net/sock.h> 81 static struct netlbl_lsm_secattr *selinux_netlbl_sock_genattr(struct sock *sk) 113 const struct sock *sk, 244 struct sock *sk; 278 * will get preserved when a full sock is created once the connection handshake 301 * selinux_netlbl_inet_csk_clone - Initialize the newly created sock 302 * @sk: the new sock 307 * we need to set the NetLabel state here since we now have a sock structure. 310 void selinux_netlbl_inet_csk_clone(struct sock *sk, u16 family) 322 * @sock 425 selinux_netlbl_socket_setsockopt(struct socket *sock, int level, int optname) argument [all...] |
H A D | hooks.c | 54 #include <net/sock.h> 2212 /* Reset fs, key, and sock SIDs on execve. */ 4054 static int sock_has_perm(struct task_struct *task, struct sock *sk, u32 perms) 4090 static int selinux_socket_post_create(struct socket *sock, int family, argument 4094 struct inode_security_struct *isec = SOCK_INODE(sock)->i_security; 4110 if (sock->sk) { 4111 sksec = sock->sk->sk_security; 4114 err = selinux_netlbl_socket_post_create(sock->sk, family); 4124 static int selinux_socket_bind(struct socket *sock, struct sockaddr *address, int addrlen) argument 4126 struct sock *s 4223 selinux_socket_connect(struct socket *sock, struct sockaddr *address, int addrlen) argument 4279 selinux_socket_listen(struct socket *sock, int backlog) argument 4284 selinux_socket_accept(struct socket *sock, struct socket *newsock) argument 4304 selinux_socket_sendmsg(struct socket *sock, struct msghdr *msg, int size) argument 4310 selinux_socket_recvmsg(struct socket *sock, struct msghdr *msg, int size, int flags) argument 4316 selinux_socket_getsockname(struct socket *sock) argument 4321 selinux_socket_getpeername(struct socket *sock) argument 4326 selinux_socket_setsockopt(struct socket *sock, int level, int optname) argument 4337 selinux_socket_getsockopt(struct socket *sock, int level, int optname) argument 4343 selinux_socket_shutdown(struct socket *sock, int how) argument 4348 selinux_socket_unix_stream_connect(struct sock *sock, struct sock *other, struct sock *newsk) argument 4382 selinux_socket_unix_may_send(struct socket *sock, struct socket *other) argument 4523 selinux_socket_getpeersec_stream(struct socket *sock, char __user *optval, int __user *optlen, unsigned len) argument 4557 selinux_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb, u32 *secid) argument [all...] |
H A D | netlink.c | 25 static struct sock *selnl;
|
H A D | avc.c | 26 #include <net/sock.h>
|
/security/ |
H A D | security.c | 1106 int security_netlink_send(struct sock *sk, struct sk_buff *skb) 1155 int security_unix_stream_connect(struct sock *sock, struct sock *other, struct sock *newsk) argument 1157 return security_ops->unix_stream_connect(sock, other, newsk); 1161 int security_unix_may_send(struct socket *sock, struct socket *other) argument 1163 return security_ops->unix_may_send(sock, other); 1172 int security_socket_post_create(struct socket *sock, int family, argument 1175 return security_ops->socket_post_create(sock, famil 1179 security_socket_bind(struct socket *sock, struct sockaddr *address, int addrlen) argument 1184 security_socket_connect(struct socket *sock, struct sockaddr *address, int addrlen) argument 1189 security_socket_listen(struct socket *sock, int backlog) argument 1194 security_socket_accept(struct socket *sock, struct socket *newsock) argument 1199 security_socket_sendmsg(struct socket *sock, struct msghdr *msg, int size) argument 1204 security_socket_recvmsg(struct socket *sock, struct msghdr *msg, int size, int flags) argument 1210 security_socket_getsockname(struct socket *sock) argument 1215 security_socket_getpeername(struct socket *sock) argument 1220 security_socket_getsockopt(struct socket *sock, int level, int optname) argument 1225 security_socket_setsockopt(struct socket *sock, int level, int optname) argument 1230 security_socket_shutdown(struct socket *sock, int how) argument 1241 security_socket_getpeersec_stream(struct socket *sock, char __user *optval, int __user *optlen, unsigned len) argument 1247 security_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb, u32 *secid) argument [all...] |
H A D | capability.c | 596 static int cap_unix_stream_connect(struct sock *sock, struct sock *other, argument 597 struct sock *newsk) 602 static int cap_unix_may_send(struct socket *sock, struct socket *other) argument 612 static int cap_socket_post_create(struct socket *sock, int family, int type, argument 618 static int cap_socket_bind(struct socket *sock, struct sockaddr *address, argument 624 static int cap_socket_connect(struct socket *sock, struct sockaddr *address, argument 630 static int cap_socket_listen(struct socket *sock, int backlog) argument 635 static int cap_socket_accept(struct socket *sock, struc argument 640 cap_socket_sendmsg(struct socket *sock, struct msghdr *msg, int size) argument 645 cap_socket_recvmsg(struct socket *sock, struct msghdr *msg, int size, int flags) argument 651 cap_socket_getsockname(struct socket *sock) argument 656 cap_socket_getpeername(struct socket *sock) argument 661 cap_socket_setsockopt(struct socket *sock, int level, int optname) argument 666 cap_socket_getsockopt(struct socket *sock, int level, int optname) argument 671 cap_socket_shutdown(struct socket *sock, int how) argument 681 cap_socket_getpeersec_stream(struct socket *sock, char __user *optval, int __user *optlen, unsigned len) argument 688 cap_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb, u32 *secid) argument [all...] |
H A D | lsm_audit.c | 20 #include <net/sock.h> 306 struct sock *sk = a->u.net->sk;
|
H A D | commoncap.c | 60 int cap_netlink_send(struct sock *sk, struct sk_buff *skb)
|
/security/tomoyo/ |
H A D | tomoyo.c | 447 * @sock: Pointer to "struct socket". 452 static int tomoyo_socket_listen(struct socket *sock, int backlog) argument 454 return tomoyo_socket_listen_permission(sock); 460 * @sock: Pointer to "struct socket". 466 static int tomoyo_socket_connect(struct socket *sock, struct sockaddr *addr, argument 469 return tomoyo_socket_connect_permission(sock, addr, addr_len); 475 * @sock: Pointer to "struct socket". 481 static int tomoyo_socket_bind(struct socket *sock, struct sockaddr *addr, argument 484 return tomoyo_socket_bind_permission(sock, addr, addr_len); 490 * @sock 496 tomoyo_socket_sendmsg(struct socket *sock, struct msghdr *msg, int size) argument [all...] |
H A D | network.c | 617 * @sk: Pointer to "struct sock". 621 static u8 tomoyo_sock_family(struct sock *sk) 641 * @sock: Pointer to "struct socket". 645 int tomoyo_socket_listen_permission(struct socket *sock) argument 648 const u8 family = tomoyo_sock_family(sock->sk); 649 const unsigned int type = sock->type; 656 const int error = sock->ops->getname(sock, (struct sockaddr *) 674 * @sock: Pointer to "struct socket". 680 int tomoyo_socket_connect_permission(struct socket *sock, argument 717 tomoyo_socket_bind_permission(struct socket *sock, struct sockaddr *addr, int addr_len) argument 752 tomoyo_socket_sendmsg_permission(struct socket *sock, struct msghdr *msg, int size) argument [all...] |
H A D | realpath.c | 223 struct socket *sock = inode ? SOCKET_I(inode) : NULL; local 224 struct sock *sk = sock ? sock->sk : NULL;
|
H A D | common.h | 31 #include <net/sock.h> 985 int tomoyo_socket_bind_permission(struct socket *sock, struct sockaddr *addr, 987 int tomoyo_socket_connect_permission(struct socket *sock, 989 int tomoyo_socket_listen_permission(struct socket *sock); 990 int tomoyo_socket_sendmsg_permission(struct socket *sock, struct msghdr *msg,
|
/security/smack/ |
H A D | smack_lsm.c | 1241 struct socket *sock; local 1262 sock = SOCKET_I(ip); 1263 if (sock == NULL || sock->sk == NULL) 1266 ssp = sock->sk->sk_security; 2061 static int smack_sk_alloc_security(struct sock *sk, int family, gfp_t gfp_flags) 2085 static void smack_sk_free_security(struct sock *sk) 2137 static int smack_netlabel(struct sock *sk, int labeled) 2179 static int smack_netlabel_send(struct sock *sk, struct sockaddr_in *sap) 2216 * @sock 2221 smk_ipv6_port_label(struct socket *sock, struct sockaddr *address) argument 2382 struct socket *sock; local 2441 smack_socket_post_create(struct socket *sock, int family, int type, int protocol, int kern) argument 2462 smack_socket_bind(struct socket *sock, struct sockaddr *address, int addrlen) argument 2481 smack_socket_connect(struct socket *sock, struct sockaddr *sap, int addrlen) argument 3283 smack_unix_stream_connect(struct sock *sock, struct sock *other, struct sock *newsk) argument 3332 smack_unix_may_send(struct socket *sock, struct socket *other) argument 3364 smack_socket_sendmsg(struct socket *sock, struct msghdr *msg, int size) argument 3591 smack_socket_getpeersec_stream(struct socket *sock, char __user *optval, int __user *optlen, unsigned len) argument 3626 smack_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb, u32 *secid) argument [all...] |
H A D | smack.h | 134 struct sock *smk_sock; /* socket initialized on */ 388 struct sock *sk) 420 struct sock *sk)
|
/security/selinux/ss/ |
H A D | mls.h | 53 bool sock);
|
H A D | mls.c | 510 bool sock) 553 if ((tclass == policydb.process_class) || (sock == true)) 505 mls_compute_sid(struct context *scontext, struct context *tcontext, u16 tclass, u32 specified, struct context *newcontext, bool sock) argument
|
H A D | services.c | 1571 bool sock; local 1591 sock = security_is_socket_class(orig_tclass); 1594 sock = security_is_socket_class(map_class(tclass)); 1639 if ((tclass == policydb.process_class) || (sock == true)) 1651 if ((tclass == policydb.process_class) || (sock == true)) { 1705 &newcontext, sock);
|
/security/apparmor/ |
H A D | lsm.c | 26 #include <net/sock.h>
|