diff options
Diffstat (limited to 'security/capability.c')
-rw-r--r-- | security/capability.c | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/security/capability.c b/security/capability.c index 0fe5a026aef8..579775088967 100644 --- a/security/capability.c +++ b/security/capability.c | |||
@@ -709,16 +709,31 @@ static void cap_req_classify_flow(const struct request_sock *req, | |||
709 | { | 709 | { |
710 | } | 710 | } |
711 | 711 | ||
712 | static int cap_tun_dev_alloc_security(void **security) | ||
713 | { | ||
714 | return 0; | ||
715 | } | ||
716 | |||
717 | static void cap_tun_dev_free_security(void *security) | ||
718 | { | ||
719 | } | ||
720 | |||
712 | static int cap_tun_dev_create(void) | 721 | static int cap_tun_dev_create(void) |
713 | { | 722 | { |
714 | return 0; | 723 | return 0; |
715 | } | 724 | } |
716 | 725 | ||
717 | static void cap_tun_dev_post_create(struct sock *sk) | 726 | static int cap_tun_dev_attach_queue(void *security) |
727 | { | ||
728 | return 0; | ||
729 | } | ||
730 | |||
731 | static int cap_tun_dev_attach(struct sock *sk, void *security) | ||
718 | { | 732 | { |
733 | return 0; | ||
719 | } | 734 | } |
720 | 735 | ||
721 | static int cap_tun_dev_attach(struct sock *sk) | 736 | static int cap_tun_dev_open(void *security) |
722 | { | 737 | { |
723 | return 0; | 738 | return 0; |
724 | } | 739 | } |
@@ -1050,8 +1065,11 @@ void __init security_fixup_ops(struct security_operations *ops) | |||
1050 | set_to_cap_if_null(ops, secmark_refcount_inc); | 1065 | set_to_cap_if_null(ops, secmark_refcount_inc); |
1051 | set_to_cap_if_null(ops, secmark_refcount_dec); | 1066 | set_to_cap_if_null(ops, secmark_refcount_dec); |
1052 | set_to_cap_if_null(ops, req_classify_flow); | 1067 | set_to_cap_if_null(ops, req_classify_flow); |
1068 | set_to_cap_if_null(ops, tun_dev_alloc_security); | ||
1069 | set_to_cap_if_null(ops, tun_dev_free_security); | ||
1053 | set_to_cap_if_null(ops, tun_dev_create); | 1070 | set_to_cap_if_null(ops, tun_dev_create); |
1054 | set_to_cap_if_null(ops, tun_dev_post_create); | 1071 | set_to_cap_if_null(ops, tun_dev_open); |
1072 | set_to_cap_if_null(ops, tun_dev_attach_queue); | ||
1055 | set_to_cap_if_null(ops, tun_dev_attach); | 1073 | set_to_cap_if_null(ops, tun_dev_attach); |
1056 | #endif /* CONFIG_SECURITY_NETWORK */ | 1074 | #endif /* CONFIG_SECURITY_NETWORK */ |
1057 | #ifdef CONFIG_SECURITY_NETWORK_XFRM | 1075 | #ifdef CONFIG_SECURITY_NETWORK_XFRM |