Skip to content

Commit 1341b78

Browse files
rddunlapgregkh
authored andcommitted
lsm: CONFIG_LSM can depend on CONFIG_SECURITY
[ Upstream commit 54d94c4 ] When CONFIG_SECURITY is not set, CONFIG_LSM (builtin_lsm_order) does not need to be visible and settable since builtin_lsm_order is defined in security.o, which is only built when CONFIG_SECURITY=y. So make CONFIG_LSM depend on CONFIG_SECURITY. Fixes: 13e735c ("LSM: Introduce CONFIG_LSM") Signed-off-by: Randy Dunlap <[email protected]> [PM: subj tweak] Signed-off-by: Paul Moore <[email protected]> Signed-off-by: Sasha Levin <[email protected]>
1 parent 788bfdb commit 1341b78

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

security/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,7 @@ endchoice
269269

270270
config LSM
271271
string "Ordered list of enabled LSMs"
272+
depends on SECURITY
272273
default "landlock,lockdown,yama,loadpin,safesetid,smack,selinux,tomoyo,apparmor,ipe,bpf" if DEFAULT_SECURITY_SMACK
273274
default "landlock,lockdown,yama,loadpin,safesetid,apparmor,selinux,smack,tomoyo,ipe,bpf" if DEFAULT_SECURITY_APPARMOR
274275
default "landlock,lockdown,yama,loadpin,safesetid,tomoyo,ipe,bpf" if DEFAULT_SECURITY_TOMOYO

0 commit comments

Comments
 (0)