lkml.org 
[lkml]   [2022]   [Nov]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] lockdown: kexec_file: prevent unsigned kernel image when KEXEC_SIG not enabled
Hi Mimi,

On Mon, Nov 21, 2022 at 01:23:57PM -0500, Mimi Zohar wrote:
>Hi Coiby,
>
>On Mon, 2022-11-21 at 15:29 +0800, Coiby Xu wrote:
>> A kernel builder may not enable KEXEC_SIG and some architectures like
>> ppc64 simply don't have KEXEC_SIG. In these cases, unless both
>> IMA_ARCH_POLICY and secure boot also enabled, lockdown doesn't prevent
>> unsigned kernel image from being kexec'ed via the kexec_file_load
>> syscall whereas it could prevent one via the kexec_load syscall. Mandate
>> signature verification for those cases.
>>
>> Fixes: 155bdd30af17 ("kexec_file: Restrict at runtime if the kernel is locked down")
>> Cc: Matthew Garrett <mjg59@srcf.ucam.org>
>> Cc: Jiri Bohac <jbohac@suse.cz>
>> Cc: David Howells <dhowells@redhat.com>
>> Cc: kexec@lists.infradead.org
>> Cc: linux-integrity@vger.kernel.org
>> Signed-off-by: Coiby Xu <coxu@redhat.com>
>
>Other than correcting the function name to mandate_signature_verificati
>on(),

Applied to v2, thanks for correcting me! Btw, I realize I overwrote the
return code of kexec_image_verify_sig with
mandate_signature_verification's. v2 has fixed this issue as well.

>
>Reviewed-by: Mimi Zohar <zohar@linux.ibm.com>

And thanks for the review!

--
Best regards,
Coiby

--
Best regards,
Coiby

\
 
 \ /
  Last update: 2022-11-22 03:38    [W:0.064 / U:1.428 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site