]> git.baikalelectronics.ru Git - kernel.git/commit
security: introduce CONFIG_SECURITY_WRITABLE_HOOKS
authorJames Morris <jmorris@namei.org>
Tue, 14 Feb 2017 13:17:24 +0000 (00:17 +1100)
committerJames Morris <james.l.morris@oracle.com>
Mon, 6 Mar 2017 00:00:12 +0000 (11:00 +1100)
commit0f6bc71e0862278147cb688d27b76a7c699b157c
treee7a2b67dfdb2beaa07d42a314eb142289599d381
parentb3b343d2cf572f9c9776de7dbae6b3cf91b294f9
security: introduce CONFIG_SECURITY_WRITABLE_HOOKS

Subsequent patches will add RO hardening to LSM hooks, however, SELinux
still needs to be able to perform runtime disablement after init to handle
architectures where init-time disablement via boot parameters is not feasible.

Introduce a new kernel configuration parameter CONFIG_SECURITY_WRITABLE_HOOKS,
and a helper macro __lsm_ro_after_init, to handle this case.

Signed-off-by: James Morris <james.l.morris@oracle.com>
Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
Acked-by: Casey Schaufler <casey@schaufler-ca.com>
Acked-by: Kees Cook <keescook@chromium.org>
include/linux/lsm_hooks.h
security/Kconfig
security/selinux/Kconfig