On Tue, 2007-10-09 at 16:28 -0700, Randy Dunlap wrote:On Wed, 10 Oct 2007 09:19:55 +1000 (EST) James Morris wrote:
From: Eric Paris <eparis@xxxxxxxxxx>I doth protest. Enabling the entire NET subsystem thru a hidden
Changes the security/selinux/Kconfig to use select instead of depends
for most of the SELinux requirements. This allows the SELinux option to
show up when people do a make config without already knowing they had to
enable audit and other non-obvious choices. Added a depends on SECURITY
(which previously existed through SECURITY_NETWORK) so that SELinux
would not always show up, but would be easy and intuitive to find.
Signed-off-by: Eric Paris <eparis@xxxxxxxxxx>
Acked-by: Stephen Smalley <sds@xxxxxxxxxxxxx>
Signed-off-by: James Morris <jmorris@xxxxxxx>
---
security/selinux/Kconfig | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/security/selinux/Kconfig b/security/selinux/Kconfig
index b32a459..40b97e6 100644
--- a/security/selinux/Kconfig
+++ b/security/selinux/Kconfig
@@ -1,6 +1,10 @@
config SECURITY_SELINUX
bool "NSA SELinux Support"
- depends on SECURITY_NETWORK && AUDIT && NET && INET
+ depends on SECURITY
+ select SECURITY_NETWORK
+ select AUDIT
+ select NET
+ select INET
select NETWORK_SECMARK
default n
help
select is awful. Select should be used (sparingly) to enable
library code only. If someone wants NET enabled, they should
enable it overtly, not covertly.
Does that apply to all the options, or only to NET (e.g. is it ok to
select AUDIT)? I thought that this patch came out of earlier
discussions about proper use of select vs. depends. It may have gone
too far, but I'm not sure it should be discarded entirely.