kexec: Disable at runtime if the kernel is locked down
authorMatthew Garrett <matthew.garrett@nebula.com>
Wed, 8 Nov 2017 15:11:32 +0000 (15:11 +0000)
committerSalvatore Bonaccorso <carnil@debian.org>
Tue, 20 Mar 2018 08:31:07 +0000 (08:31 +0000)
commitfd094314f2039f9e14421785734dfb50e8b6ec97
tree064e603f460a02065bf064838573741d4768bd6c
parent125cf403d6bd050c0a2e5934b889d488ac4634be
kexec: Disable at runtime if the kernel is locked down

kexec permits the loading and execution of arbitrary code in ring 0, which
is something that lock-down is meant to prevent. It makes sense to disable
kexec in this situation.

This does not affect kexec_file_load() which can check for a signature on the
image to be booted.

Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
Reviewed-by: "Lee, Chun-Yi" <jlee@suse.com>
Reviewed-by: James Morris <james.l.morris@oracle.com>
cc: kexec@lists.infradead.org

Gbp-Pq: Topic features/all/lockdown
Gbp-Pq: Name 0006-kexec-Disable-at-runtime-if-the-kernel-is-locked-dow.patch
kernel/kexec.c