aboutsummaryrefslogtreecommitdiffstats
path: root/security/security.c
diff options
context:
space:
mode:
authorRichard Haines <richard_c_haines@btinternet.com>2018-02-13 15:53:21 -0500
committerPaul Moore <paul@paul-moore.com>2018-02-22 15:01:32 -0500
commit72e89f50084c6dbc58a00aeedf92c450dc1a8b1c (patch)
tree65c175daec4c170bcb389ed8b8b1a8ec9b9c85af /security/security.c
parent213d7f94775322ba44e0bbb55ec6946e9de88cea (diff)
security: Add support for SCTP security hooks
The SCTP security hooks are explained in: Documentation/security/LSM-sctp.rst Signed-off-by: Richard Haines <richard_c_haines@btinternet.com> Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'security/security.c')
-rw-r--r--security/security.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/security/security.c b/security/security.c
index 1cd8526cb0b7..133bc9915f18 100644
--- a/security/security.c
+++ b/security/security.c
@@ -1473,6 +1473,7 @@ void security_inet_conn_established(struct sock *sk,
1473{ 1473{
1474 call_void_hook(inet_conn_established, sk, skb); 1474 call_void_hook(inet_conn_established, sk, skb);
1475} 1475}
1476EXPORT_SYMBOL(security_inet_conn_established);
1476 1477
1477int security_secmark_relabel_packet(u32 secid) 1478int security_secmark_relabel_packet(u32 secid)
1478{ 1479{
@@ -1528,6 +1529,27 @@ int security_tun_dev_open(void *security)
1528} 1529}
1529EXPORT_SYMBOL(security_tun_dev_open); 1530EXPORT_SYMBOL(security_tun_dev_open);
1530 1531
1532int security_sctp_assoc_request(struct sctp_endpoint *ep, struct sk_buff *skb)
1533{
1534 return call_int_hook(sctp_assoc_request, 0, ep, skb);
1535}
1536EXPORT_SYMBOL(security_sctp_assoc_request);
1537
1538int security_sctp_bind_connect(struct sock *sk, int optname,
1539 struct sockaddr *address, int addrlen)
1540{
1541 return call_int_hook(sctp_bind_connect, 0, sk, optname,
1542 address, addrlen);
1543}
1544EXPORT_SYMBOL(security_sctp_bind_connect);
1545
1546void security_sctp_sk_clone(struct sctp_endpoint *ep, struct sock *sk,
1547 struct sock *newsk)
1548{
1549 call_void_hook(sctp_sk_clone, ep, sk, newsk);
1550}
1551EXPORT_SYMBOL(security_sctp_sk_clone);
1552
1531#endif /* CONFIG_SECURITY_NETWORK */ 1553#endif /* CONFIG_SECURITY_NETWORK */
1532 1554
1533#ifdef CONFIG_SECURITY_INFINIBAND 1555#ifdef CONFIG_SECURITY_INFINIBAND