CHROMIUM: LSM: allow old style loads when locking disabled
authorOlof Johansson <olofj@chromium.org>
Fri, 7 Dec 2012 19:42:19 +0000 (11:42 -0800)
committerGerrit <chrome-bot@google.com>
Fri, 7 Dec 2012 22:41:47 +0000 (14:41 -0800)
commit4d1e6a68a43d4f4e3373cd4e8c4adc7be7121e4f
treea22ea1f5890a81c228f7fc890a57436e297f19a3
parent71b43967face4e34ee8708c1cd22b8b977f65525
CHROMIUM: LSM: allow old style loads when locking disabled

This is needed when our kernel is used with other userspaces, i.e. Ubuntu
and other distros.

Enabling old-style module init when locking is explicitly disabled doesn't
open up any security exposure for users unless they have disabled
rootfs_verification AND module load restrictions. I.e. default users have
no added exposure.

BUG=chromium-os:37055
TEST=needs a new testcase (crosbug.com/37056)

Change-Id: If5ec577a4c7be64a7fa6a0be6a76f3044de42e14
Signed-off-by: Olof Johansson <olofj@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/39383
Reviewed-by: Kees Cook <keescook@chromium.org>
security/chromiumos/lsm.c