From: "Jarkko Sakkinen" <jarkko@kernel.org>
To: "Jan Hendrik Farr" <kernel@jfarr.cc>, <linux-kernel@vger.kernel.org>
Cc: <kexec@lists.infradead.org>, <x86@kernel.org>,
<tglx@linutronix.de>, <dhowells@redhat.com>, <vgoyal@redhat.com>,
<keyrings@vger.kernel.org>, <akpm@linux-foundation.org>,
<bhe@redhat.com>, <bhelgaas@google.com>, <lennart@poettering.net>,
"Luca Boccassi" <bluca@debian.org>
Subject: Re: [PATCH 0/1] x86/kexec: UKI support
Date: Tue, 12 Sep 2023 13:33:07 +0300 [thread overview]
Message-ID: <CVGVCYUGNKAI.1WYRZGI9HYDMC@suppilovahvero> (raw)
In-Reply-To: <1d974586-1bf7-42e8-9dae-e5e41a3dbc9f@app.fastmail.com>
On Tue Sep 12, 2023 at 1:54 AM EEST, Jan Hendrik Farr wrote:
> > What the heck is UKI?
>
> UKI (Unified Kernel Image) is the kernel image + initrd + cmdline (+
> some other optional stuff) all packaged up together as one EFI
> application.
>
> This EFI application can then be launched directly by the UEFI without
> the need for any additional stuff (or by systemd-boot). It's all self
> contained. One benefit is that this is a convenient way to distribute
> kernels all in one file. Another benefit is that the whole combination
> of kernel image, initrd, and cmdline can all be signed together so
> only that particular combination can be executed if you are using
> secure boot.
Is this also for generic purpose distributions? I mean it is not
uncommon having to tweak the command-line in a workstation.
> The format itself is rather simple. It's just a PE file (as required
> by the UEFI spec) that contains a small stub application in the .text,
> .data, etc sections that is responsible for invoking the contained
> kernel and initrd with the contained cmdline. The kernel image is
> placed into a .kernel section, the initrd into a .initrd section, and
> the cmdline into a .cmdline section in the PE executable.
How does this interact with the existing EFI stub support in linux?
> If we want to kexec a UKI we could obviously just have userspace pick
> it apart and kexec it like normal. However in lockdown mode this will
> only work if you sign the kernel image that is contained inside the
> UKI. The problem with that is that anybody can then grab that signed
> kernel and launch it with any initrd or cmdline. So instead this patch
> makes the kernel do the work instead. The kernel verifies the
> signature on the entire UKI and then passes its components on to the
> normal kexec bzimage loader.
>
> Useful Links:
> UKI format documentation: https://uapi-group.org/specifications/specs/unified_kernel_image/
> Arch wiki: https://wiki.archlinux.org/title/Unified_kernel_image
> Fedora UKI support: https://fedoraproject.org/wiki/Changes/Unified_Kernel_Support_Phase_1
BR, Jarkko
_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec
next prev parent reply other threads:[~2023-09-12 10:33 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-09 16:18 [PATCH 0/1] x86/kexec: UKI support Jan Hendrik Farr
2023-09-09 16:18 ` [PATCH 1/1] " Jan Hendrik Farr
2023-09-09 17:15 ` [PATCH 0/1] " Luca Boccassi
2023-09-09 17:57 ` Jan Hendrik Farr
2023-09-09 18:10 ` Luca Boccassi
2023-09-11 3:23 ` Jan Hendrik Farr
2023-09-11 22:02 ` Jarkko Sakkinen
2023-09-11 22:54 ` Jan Hendrik Farr
2023-09-12 10:33 ` Jarkko Sakkinen [this message]
2023-09-12 15:32 ` Jan Hendrik Farr
2023-09-12 17:41 ` Jarkko Sakkinen
2023-09-12 18:56 ` Jan Hendrik Farr
2023-09-12 19:24 ` Jarkko Sakkinen
2023-09-12 19:38 ` Jan Hendrik Farr
2023-09-12 20:49 ` Jan Hendrik Farr
2023-09-13 14:45 ` Jarkko Sakkinen
2023-09-13 15:07 ` Jan Hendrik Farr
2023-09-13 15:58 ` Jarkko Sakkinen
2023-09-14 9:11 ` Lennart Poettering
2023-09-14 12:12 ` Jarkko Sakkinen
2023-09-14 8:48 ` Lennart Poettering
2023-09-14 11:52 ` Jarkko Sakkinen
2023-09-11 23:20 ` [systemd-devel] " Neal Gompa
2023-09-12 10:37 ` Jarkko Sakkinen
2023-09-18 15:41 ` Dimitri John Ledkov
2023-09-25 16:43 ` Jarkko Sakkinen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CVGVCYUGNKAI.1WYRZGI9HYDMC@suppilovahvero \
--to=jarkko@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=bhe@redhat.com \
--cc=bhelgaas@google.com \
--cc=bluca@debian.org \
--cc=dhowells@redhat.com \
--cc=kernel@jfarr.cc \
--cc=kexec@lists.infradead.org \
--cc=keyrings@vger.kernel.org \
--cc=lennart@poettering.net \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=vgoyal@redhat.com \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox