aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2018-09-19 16:13:25 -0700
committerKees Cook <keescook@chromium.org>2019-01-08 13:18:42 -0800
commit47008e5161fa097ce9b848dee194b43262b743a5 (patch)
tree4a2e652b63497aef5f1b6d55f7ec24c562617a25 /include
parentLinux 5.0-rc1 (diff)
downloadlinux-dev-47008e5161fa097ce9b848dee194b43262b743a5.tar.xz
linux-dev-47008e5161fa097ce9b848dee194b43262b743a5.zip
LSM: Introduce LSM_FLAG_LEGACY_MAJOR
This adds a flag for the current "major" LSMs to distinguish them when we have a universal method for ordering all LSMs. It's called "legacy" since the distinction of "major" will go away in the blob-sharing world. Signed-off-by: Kees Cook <keescook@chromium.org> Reviewed-by: Casey Schaufler <casey@schaufler-ca.com> Reviewed-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/lsm_hooks.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/lsm_hooks.h b/include/linux/lsm_hooks.h
index 9a0bdf91e646..318d93f918c3 100644
--- a/include/linux/lsm_hooks.h
+++ b/include/linux/lsm_hooks.h
@@ -2042,8 +2042,11 @@ extern char *lsm_names;
extern void security_add_hooks(struct security_hook_list *hooks, int count,
char *lsm);
+#define LSM_FLAG_LEGACY_MAJOR BIT(0)
+
struct lsm_info {
const char *name; /* Required. */
+ unsigned long flags; /* Optional: flags describing LSM */
int (*init)(void); /* Required. */
};