aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/netlabel.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/netlabel.h')
-rw-r--r--include/net/netlabel.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/include/net/netlabel.h b/include/net/netlabel.h
index 4e223aa25e5b..d605d7954013 100644
--- a/include/net/netlabel.h
+++ b/include/net/netlabel.h
@@ -111,11 +111,17 @@ struct netlbl_lsm_cache {
111 void (*free) (const void *data); 111 void (*free) (const void *data);
112 void *data; 112 void *data;
113}; 113};
114#define NETLBL_SECATTR_NONE 0x00000000
115#define NETLBL_SECATTR_DOMAIN 0x00000001
116#define NETLBL_SECATTR_CACHE 0x00000002
117#define NETLBL_SECATTR_MLS_LVL 0x00000004
118#define NETLBL_SECATTR_MLS_CAT 0x00000008
114struct netlbl_lsm_secattr { 119struct netlbl_lsm_secattr {
120 u32 flags;
121
115 char *domain; 122 char *domain;
116 123
117 u32 mls_lvl; 124 u32 mls_lvl;
118 u32 mls_lvl_vld;
119 unsigned char *mls_cat; 125 unsigned char *mls_cat;
120 size_t mls_cat_len; 126 size_t mls_cat_len;
121 127
@@ -174,7 +180,10 @@ static inline void netlbl_secattr_cache_free(struct netlbl_lsm_cache *cache)
174 */ 180 */
175static inline void netlbl_secattr_init(struct netlbl_lsm_secattr *secattr) 181static inline void netlbl_secattr_init(struct netlbl_lsm_secattr *secattr)
176{ 182{
177 memset(secattr, 0, sizeof(*secattr)); 183 secattr->flags = 0;
184 secattr->domain = NULL;
185 secattr->mls_cat = NULL;
186 secattr->cache = NULL;
178} 187}
179 188
180/** 189/**