diff options
| author | Kees Cook <keescook@chromium.org> | 2018-10-10 20:18:24 -0400 |
|---|---|---|
| committer | James Morris <james.morris@microsoft.com> | 2018-10-10 23:40:22 -0400 |
| commit | 07aed2f2af5a5892ced035dbcf3993f630825fc3 (patch) | |
| tree | 2065a155d92f1a170c4b180162346db809b30a82 /security | |
| parent | 3d6e5f6dcf6561e57b6466e43e14029fb196028d (diff) | |
LSM: Record LSM name in struct lsm_info
In preparation for making LSM selections outside of the LSMs, include
the name of LSMs in struct lsm_info.
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Casey Schaufler <casey@schaufler-ca.com>
Signed-off-by: James Morris <james.morris@microsoft.com>
Diffstat (limited to 'security')
| -rw-r--r-- | security/apparmor/lsm.c | 1 | ||||
| -rw-r--r-- | security/integrity/iint.c | 1 | ||||
| -rw-r--r-- | security/selinux/hooks.c | 1 | ||||
| -rw-r--r-- | security/smack/smack_lsm.c | 1 | ||||
| -rw-r--r-- | security/tomoyo/tomoyo.c | 1 |
5 files changed, 5 insertions, 0 deletions
diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c index c4863956c832..dca4b7dbf368 100644 --- a/security/apparmor/lsm.c +++ b/security/apparmor/lsm.c | |||
| @@ -1607,5 +1607,6 @@ alloc_out: | |||
| 1607 | } | 1607 | } |
| 1608 | 1608 | ||
| 1609 | DEFINE_LSM(apparmor) = { | 1609 | DEFINE_LSM(apparmor) = { |
| 1610 | .name = "apparmor", | ||
| 1610 | .init = apparmor_init, | 1611 | .init = apparmor_init, |
| 1611 | }; | 1612 | }; |
diff --git a/security/integrity/iint.c b/security/integrity/iint.c index 94e8e1820748..1ea05da2323d 100644 --- a/security/integrity/iint.c +++ b/security/integrity/iint.c | |||
| @@ -176,6 +176,7 @@ static int __init integrity_iintcache_init(void) | |||
| 176 | return 0; | 176 | return 0; |
| 177 | } | 177 | } |
| 178 | DEFINE_LSM(integrity) = { | 178 | DEFINE_LSM(integrity) = { |
| 179 | .name = "integrity", | ||
| 179 | .init = integrity_iintcache_init, | 180 | .init = integrity_iintcache_init, |
| 180 | }; | 181 | }; |
| 181 | 182 | ||
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 6ca2e89ddbd6..9651bccae270 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
| @@ -7203,6 +7203,7 @@ void selinux_complete_init(void) | |||
| 7203 | /* SELinux requires early initialization in order to label | 7203 | /* SELinux requires early initialization in order to label |
| 7204 | all processes and objects when they are created. */ | 7204 | all processes and objects when they are created. */ |
| 7205 | DEFINE_LSM(selinux) = { | 7205 | DEFINE_LSM(selinux) = { |
| 7206 | .name = "selinux", | ||
| 7206 | .init = selinux_init, | 7207 | .init = selinux_init, |
| 7207 | }; | 7208 | }; |
| 7208 | 7209 | ||
diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c index c62e26939a69..2fb56bcf1316 100644 --- a/security/smack/smack_lsm.c +++ b/security/smack/smack_lsm.c | |||
| @@ -4883,5 +4883,6 @@ static __init int smack_init(void) | |||
| 4883 | * all processes and objects when they are created. | 4883 | * all processes and objects when they are created. |
| 4884 | */ | 4884 | */ |
| 4885 | DEFINE_LSM(smack) = { | 4885 | DEFINE_LSM(smack) = { |
| 4886 | .name = "smack", | ||
| 4886 | .init = smack_init, | 4887 | .init = smack_init, |
| 4887 | }; | 4888 | }; |
diff --git a/security/tomoyo/tomoyo.c b/security/tomoyo/tomoyo.c index b2d833999910..1b5b5097efd7 100644 --- a/security/tomoyo/tomoyo.c +++ b/security/tomoyo/tomoyo.c | |||
| @@ -551,5 +551,6 @@ static int __init tomoyo_init(void) | |||
| 551 | } | 551 | } |
| 552 | 552 | ||
| 553 | DEFINE_LSM(tomoyo) = { | 553 | DEFINE_LSM(tomoyo) = { |
| 554 | .name = "tomoyo", | ||
| 554 | .init = tomoyo_init, | 555 | .init = tomoyo_init, |
| 555 | }; | 556 | }; |
