Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1168557
| From | Dave Young <dyoung@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: kexec_load(2) bypasses signature verification |
| Date | 2015-06-19 08:30 +0200 |
| Message-ID | <pCXYl-7Dj-7@gated-at.bofh.it> (permalink) |
| References | (5 earlier) <pCauC-3iI-13@gated-at.bofh.it> <pCaEi-3ui-7@gated-at.bofh.it> <pCwEN-1MB-1@gated-at.bofh.it> <pCxrb-2YR-7@gated-at.bofh.it> <pCIcV-1t5-19@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 06/18/15 at 09:30am, Vivek Goyal wrote: > On Thu, Jun 18, 2015 at 10:02:09AM +0800, Dave Young wrote: > > [..] > > > Or simply add a new config option KEXEC_VERIFY_SIG_FORCE, so we can return > > > error in kexec_load and print some error message. > > > > Just like below, does this work for you, Ted? > > > > --- > > arch/x86/Kconfig | 7 +++++++ > > kernel/kexec.c | 9 ++++++++- > > 2 files changed, 15 insertions(+), 1 deletion(-) > > > > --- linux.orig/arch/x86/Kconfig > > +++ linux/arch/x86/Kconfig > > @@ -1755,6 +1755,13 @@ config KEXEC_VERIFY_SIG > > verification for the corresponding kernel image type being > > loaded in order for this to work. > > > > +config KEXEC_VERIFY_SIG_FORCE > > + bool "Enforce kexec signature verifying" > > + depends on KEXEC_VERIFY_SIG > > + ---help--- > > + This option disable kexec_load() syscall, only kexec_file_load > > + can be used. > > + > > > Hi Dave, > > I think we might not need a new config option. A new config option makes > it little confusing. KEXEC_VERIFY_SIG already implies KEXEC_VERIFY_SIG_FORCE > (for new syscall). Now extending it to also mean that it should disable old > syscall is confusing. Hmm, it is only reasonable when kexec_file_load can support bypassing sig verifying even when CONFIG_KEXEC_VERIFY_SIG=y. So agree it is confusing to add a _FORCE new option now. > > We already have a sysctl knob to disable kexec kernel loading. But that > knob disables it on both the syscalls. > > May be we can just introduce another command line option say > "kexec_verify_sig_force" and this will work across both the syscalls and > will deny loading a unsigned kernel in following two cases. > > - Using old syscall > - Using new syscall if kernel was compiled with KEXEC_VERIFY_SIG=n. As you said KEXEC_VERIFY_SIG implies KEXEC_VERIFY_SIG_FORCE now so if one disable it in .config, we have no reason to disable kernel loading without signature verifying? > > This should be simple and get us going in short term. > > If we want to disable unsigned kernel loading at compile time, then we > really need to work on decoupling CONFIG_KEXEC and CONFIG_FILE_KEXEC. > Introducing another config option is not the way forward, IMHO. Yes, let's do it in this way since everyone is fine with it. Thanks Dave -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
kexec_load(2) bypasses signature verification Theodore Ts'o <tytso@mit.edu> - 2015-06-15 06:00 +0200
Re: kexec_load(2) bypasses signature verification Theodore Ts'o <tytso@mit.edu> - 2015-06-15 22:10 +0200
Re: kexec_load(2) bypasses signature verification ebiederm@xmission.com (Eric W. Biederman) - 2015-06-16 21:50 +0200
Re: kexec_load(2) bypasses signature verification Vivek Goyal <vgoyal@redhat.com> - 2015-06-16 22:30 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-18 03:20 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-18 04:10 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-19 08:30 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-19 10:20 +0200
Re: kexec_load(2) bypasses signature verification Vivek Goyal <vgoyal@redhat.com> - 2015-06-19 15:10 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-19 09:10 +0200
Re: kexec_load(2) bypasses signature verification Vivek Goyal <vgoyal@redhat.com> - 2015-06-19 15:10 +0200
Re: kexec_load(2) bypasses signature verification Dave Young <dyoung@redhat.com> - 2015-06-18 03:30 +0200
csiph-web