diff options
author | Richard Haines <richard_c_haines@btinternet.com> | 2018-02-13 20:53:21 +0000 |
---|---|---|
committer | Paul Moore <paul@paul-moore.com> | 2018-02-22 15:01:32 -0500 |
commit | 72e89f50084c6dbc58a00aeedf92c450dc1a8b1c (patch) | |
tree | 65c175daec4c170bcb389ed8b8b1a8ec9b9c85af /security | |
parent | 213d7f94775322ba44e0bbb55ec6946e9de88cea (diff) | |
download | op-kernel-dev-72e89f50084c6dbc58a00aeedf92c450dc1a8b1c.zip op-kernel-dev-72e89f50084c6dbc58a00aeedf92c450dc1a8b1c.tar.gz |
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')
-rw-r--r-- | security/security.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/security/security.c b/security/security.c index 1cd8526..133bc99 100644 --- a/security/security.c +++ b/security/security.c @@ -1473,6 +1473,7 @@ void security_inet_conn_established(struct sock *sk, { call_void_hook(inet_conn_established, sk, skb); } +EXPORT_SYMBOL(security_inet_conn_established); int security_secmark_relabel_packet(u32 secid) { @@ -1528,6 +1529,27 @@ int security_tun_dev_open(void *security) } EXPORT_SYMBOL(security_tun_dev_open); +int security_sctp_assoc_request(struct sctp_endpoint *ep, struct sk_buff *skb) +{ + return call_int_hook(sctp_assoc_request, 0, ep, skb); +} +EXPORT_SYMBOL(security_sctp_assoc_request); + +int security_sctp_bind_connect(struct sock *sk, int optname, + struct sockaddr *address, int addrlen) +{ + return call_int_hook(sctp_bind_connect, 0, sk, optname, + address, addrlen); +} +EXPORT_SYMBOL(security_sctp_bind_connect); + +void security_sctp_sk_clone(struct sctp_endpoint *ep, struct sock *sk, + struct sock *newsk) +{ + call_void_hook(sctp_sk_clone, ep, sk, newsk); +} +EXPORT_SYMBOL(security_sctp_sk_clone); + #endif /* CONFIG_SECURITY_NETWORK */ #ifdef CONFIG_SECURITY_INFINIBAND |