aboutsummaryrefslogtreecommitdiffstats
path: root/security
diff options
context:
space:
mode:
authorPaul Moore <pmoore@redhat.com>2013-07-23 17:38:40 -0400
committerEric Paris <eparis@redhat.com>2013-07-25 13:02:08 -0400
commitd1b17b09f390369271ecfbc7e4a4d0d0dcff1b1b (patch)
treed9e0e6a00e248c0941952819c3f839e174a892ba /security
parente21936958000a4f2298193b3875b707fbcbc8f7b (diff)
selinux: cleanup the XFRM header
Remove the unused get_sock_isec() function and do some formatting fixes. Signed-off-by: Paul Moore <pmoore@redhat.com> Signed-off-by: Eric Paris <eparis@redhat.com>
Diffstat (limited to 'security')
-rw-r--r--security/selinux/include/xfrm.h19
1 files changed, 5 insertions, 14 deletions
diff --git a/security/selinux/include/xfrm.h b/security/selinux/include/xfrm.h
index b463f210f1af..60774bcf61b3 100644
--- a/security/selinux/include/xfrm.h
+++ b/security/selinux/include/xfrm.h
@@ -10,7 +10,7 @@
10#include <net/flow.h> 10#include <net/flow.h>
11 11
12int selinux_xfrm_policy_alloc(struct xfrm_sec_ctx **ctxp, 12int selinux_xfrm_policy_alloc(struct xfrm_sec_ctx **ctxp,
13 struct xfrm_user_sec_ctx *sec_ctx); 13 struct xfrm_user_sec_ctx *uctx);
14int selinux_xfrm_policy_clone(struct xfrm_sec_ctx *old_ctx, 14int selinux_xfrm_policy_clone(struct xfrm_sec_ctx *old_ctx,
15 struct xfrm_sec_ctx **new_ctxp); 15 struct xfrm_sec_ctx **new_ctxp);
16void selinux_xfrm_policy_free(struct xfrm_sec_ctx *ctx); 16void selinux_xfrm_policy_free(struct xfrm_sec_ctx *ctx);
@@ -23,18 +23,8 @@ void selinux_xfrm_state_free(struct xfrm_state *x);
23int selinux_xfrm_state_delete(struct xfrm_state *x); 23int selinux_xfrm_state_delete(struct xfrm_state *x);
24int selinux_xfrm_policy_lookup(struct xfrm_sec_ctx *ctx, u32 fl_secid, u8 dir); 24int selinux_xfrm_policy_lookup(struct xfrm_sec_ctx *ctx, u32 fl_secid, u8 dir);
25int selinux_xfrm_state_pol_flow_match(struct xfrm_state *x, 25int selinux_xfrm_state_pol_flow_match(struct xfrm_state *x,
26 struct xfrm_policy *xp, const struct flowi *fl); 26 struct xfrm_policy *xp,
27 27 const struct flowi *fl);
28/*
29 * Extract the security blob from the sock (it's actually on the socket)
30 */
31static inline struct inode_security_struct *get_sock_isec(struct sock *sk)
32{
33 if (!sk->sk_socket)
34 return NULL;
35
36 return SOCK_INODE(sk->sk_socket)->i_security;
37}
38 28
39#ifdef CONFIG_SECURITY_NETWORK_XFRM 29#ifdef CONFIG_SECURITY_NETWORK_XFRM
40extern atomic_t selinux_xfrm_refcount; 30extern atomic_t selinux_xfrm_refcount;
@@ -74,7 +64,8 @@ static inline int selinux_xfrm_postroute_last(u32 sk_sid, struct sk_buff *skb,
74 return 0; 64 return 0;
75} 65}
76 66
77static inline int selinux_xfrm_decode_session(struct sk_buff *skb, u32 *sid, int ckall) 67static inline int selinux_xfrm_decode_session(struct sk_buff *skb, u32 *sid,
68 int ckall)
78{ 69{
79 *sid = SECSID_NULL; 70 *sid = SECSID_NULL;
80 return 0; 71 return 0;