Re: [PATCH] binfmt_misc: add two-steps registration (opt-in)

From: Kees Cook
Date: Thu Mar 10 2022 - 11:13:44 EST


On Tue, Mar 01, 2022 at 02:28:22PM +0100, Domenico Andreoli wrote:
> From: Domenico Andreoli <domenico.andreoli@xxxxxxxxx>
>
> Experimenting with new interpreter configurations can lead to annoying
> failures, when the system is left unable to load ELF binaries power
> cycling is the only way to get it back operational.
>
> This patch tries to mitigate such conditions by adding an opt-in
> two-steps registration.
>
> A new optional field is added to the configuration string, it's an
> expiration interval for the newly added interpreter. If the user is
> not able to confirm in time, possibly because the system is broken,
> the new interpreter is automatically disabled.

Hi!

As this both changes the userspace API and adds timers, I'd like the
change to be really well justified. Can you explain the conditions you
get into that can't be escaped by just disabling the bad binfmt_misc
entry?

-Kees

--
Kees Cook