aboutsummaryrefslogtreecommitdiffstats
path: root/security/security.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2018-04-06 18:39:26 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2018-04-06 18:39:26 -0400
commit9eda2d2dca830f0f8923b1f377d0fb70f576af1d (patch)
tree5bdc06d14182e67ebdf20e5543de2a407563662f /security/security.c
parent6ad11bdd57ad31182850a54235f0e947cbfd5ad0 (diff)
parent6b6bc6205d98796361962ee282a063f18ba8dc57 (diff)
Merge tag 'selinux-pr-20180403' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux
Pull SELinux updates from Paul Moore: "A bigger than usual pull request for SELinux, 13 patches (lucky!) along with a scary looking diffstat. Although if you look a bit closer, excluding the usual minor tweaks/fixes, there are really only two significant changes in this pull request: the addition of proper SELinux access controls for SCTP and the encapsulation of a lot of internal SELinux state. The SCTP changes are the result of a multi-month effort (maybe even a year or longer?) between the SELinux folks and the SCTP folks to add proper SELinux controls. A special thanks go to Richard for seeing this through and keeping the effort moving forward. The state encapsulation work is a bit of janitorial work that came out of some early work on SELinux namespacing. The question of namespacing is still an open one, but I believe there is some real value in the encapsulation work so we've split that out and are now sending that up to you" * tag 'selinux-pr-20180403' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux: selinux: wrap AVC state selinux: wrap selinuxfs state selinux: fix handling of uninitialized selinux state in get_bools/classes selinux: Update SELinux SCTP documentation selinux: Fix ltp test connect-syscall failure selinux: rename the {is,set}_enforcing() functions selinux: wrap global selinux state selinux: fix typo in selinux_netlbl_sctp_sk_clone declaration selinux: Add SCTP support sctp: Add LSM hooks sctp: Add ip option support security: Add support for SCTP security hooks netlabel: If PF_INET6, check sk_buff ip header version
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 02d734e69955..af53d2834e20 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