From: Kees Cook <keescook@chromium.org>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: linux-efi@vger.kernel.org, Daniel Marth <daniel.marth@inso.tuwien.ac.at>
Subject: Re: [PATCH] efi: libstub: Disable struct randomization
Date: Mon, 22 Aug 2022 12:57:57 -0700 [thread overview]
Message-ID: <202208221257.06B78617C5@keescook> (raw)
In-Reply-To: <20220822172953.3918414-1-ardb@kernel.org>
On Mon, Aug 22, 2022 at 07:29:53PM +0200, Ard Biesheuvel wrote:
> The EFI stub is a wrapper around the core kernel that makes it look like
> a EFI compatible PE/COFF application to the EFI firmware. EFI
> applications run on top of the EFI runtime, which is heavily based on
> so-called protocols, which are struct types consisting [mostly] of
> function pointer members that are instantiated and recorded in a
> protocol database.
>
> These structs look like the ideal randomization candidates to the
> randstruct plugin (as they only carry function pointers), but of course,
> these protocols are contracts between the firmware that exposes them,
> and the EFI applications (including our stubbed kernel) that invoke
> them. This means that struct randomization for EFI protocols is not a
> great idea, and given that the stub shares very little data with the
> core kernel that is represented as a randomizable struct, we're better
> off just disabling it completely here.
>
> Reported-by: Daniel Marth <daniel.marth@inso.tuwien.ac.at>
> Tested-by: Daniel Marth <daniel.marth@inso.tuwien.ac.at>
> Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Acked-by: Kees Cook <keescook@chromium.org>
-Kees
--
Kees Cook
next prev parent reply other threads:[~2022-08-22 19:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-22 17:29 [PATCH] efi: libstub: Disable struct randomization Ard Biesheuvel
2022-08-22 19:57 ` Kees Cook [this message]
2022-08-25 9:18 ` Ard Biesheuvel
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=202208221257.06B78617C5@keescook \
--to=keescook@chromium.org \
--cc=ardb@kernel.org \
--cc=daniel.marth@inso.tuwien.ac.at \
--cc=linux-efi@vger.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