Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp241265ybe; Mon, 2 Sep 2019 00:24:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqySSiklC2nqq2hZjWTDw5Op+hiDr0yo4jNc4j1JWgWIwsgdRikcq0+i3ea841lEionjNvN2 X-Received: by 2002:a62:1b0c:: with SMTP id b12mr32354991pfb.17.1567409085644; Mon, 02 Sep 2019 00:24:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567409085; cv=none; d=google.com; s=arc-20160816; b=04fWtBLjXpfBpMhfaHu9tPbTmOJr3uGOEK2VOUV7s4mhQApNltztyc2fE5DlEK6NfX /MWBG+qDpS4xwicaInCfBvj7EOR1hTwImz0EkZYQFOqzeqqac9wTlESl59qAb+uVXfSa Et3tIaRSpu8RgWBtqmvxx7s/0AlD1GOTOIlvC9PTeh10Tx+GNpQ8aHKChaUZRw4WtdN3 4Nw7zYyXBMBwUNvT6CxEutGwlqKxozTnK997wH7Z/ZJ8f2SpGbrkMdzZezjjDxgz+/T1 ueEYC5RGqwsO0MzWM6Bsna3RZV6EDPdIk39VG33LkpCfQPzMboSIPURv0mNi2TGStpnJ ujqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=vbtmjNkECAAB4ShWXp7lmKBQ4kBd5L/urPWDlTCKZcg=; b=s10NCSMEcxe1CBx68G6v/5bzBMC99fbycriT3O+UUw5eI7DnfXfsmyB3PIMEUXv1dk DzCUOZZcY9gpvG8MQnh3ZR6EWHT/zIQ+5cqaWz95K+j+HDzNM0O65VpbTgQB2k4es+Dv V9HEh1vkwhO+G03WskWLk0ln5dUnE74OVc4nnH3SmVge5hJcm0pCPojd/1sy6mB75uwI 27iQDn5o7bQnpzzn7wLwRdgnMC54KTHWscc7Sh8mexPM1kdFuspo2Yzcx2klIhXt56Lw juQ6wdZhjtjLm9tm+E+5U0x5zd7b5RreggRinV3+I7nxd1/IFWTpss0Zr03on8RLiqfp PqXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Lrlp9G1r; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 67si13899324pfv.74.2019.09.02.00.24.30; Mon, 02 Sep 2019 00:24:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Lrlp9G1r; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729692AbfIBHXS (ORCPT + 99 others); Mon, 2 Sep 2019 03:23:18 -0400 Received: from mail.skyhub.de ([5.9.137.197]:59826 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729529AbfIBHXS (ORCPT ); Mon, 2 Sep 2019 03:23:18 -0400 Received: from zn.tnic (p200300EC2F064300254E15554D301ABC.dip0.t-ipconnect.de [IPv6:2003:ec:2f06:4300:254e:1555:4d30:1abc]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 2D6AC1EC0B67; Mon, 2 Sep 2019 09:23:16 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1567408997; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=vbtmjNkECAAB4ShWXp7lmKBQ4kBd5L/urPWDlTCKZcg=; b=Lrlp9G1rKo0o3iGeLwxWbhOFLXkf1Aj7hxnjT73vIIJpRr9ZiFeeX7u/bBhiBLNAd7fNf+ 9xsP77wURf7byYUvBYGWI49eKcZR53jRPys5t3tEpjeczZ/hVt1E2SGGZuEgFjA2ukiNtB v6cf8iAhaWE1KXKBSyCCeRSTqcXgcbc= Date: Mon, 2 Sep 2019 09:23:10 +0200 From: Borislav Petkov To: John S Gruber Cc: john.hubbard@gmail.com, hpa@zytor.com, jhubbard@nvidia.com, linux-kernel@vger.kernel.org, mingo@redhat.com, tglx@linutronix.de, x86@kernel.org, stable@vger.kernel.org Subject: Re: [PATCH V2] x86/boot: Fix regression--secure boot info loss from bootparam sanitizing Message-ID: <20190902072310.GA9605@zn.tnic> References: <20190731054627.5627-2-jhubbard@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 02, 2019 at 12:00:54AM +0200, John S Gruber wrote: > From: "John S. Gruber" > > commit a90118c445cc ("x86/boot: Save fields explicitly, zero out everything > else") now zeros the secure boot information passed by the boot loader or > by the kernel's efi handover mechanism. Include boot-params.secure_boot > in the preserve field list. > > I noted a change in my computers between running signed 5.3-rc4 and 5.3-rc6 > with signed kernels using the efi handoff protocol with grub. The kernel > log message "Secure boot enabled" becomes "Secure boot could not be > determined". The efi_main function in arch/x86/boot/compressed/eboot.c sets > this field early but it is subsequently zeroed by the above referenced > commit in the file arch/x86/include/asm/bootparam_utils.h > > Fixes: commit a90118c445cc ("x86/boot: Save fields explicitly, zero > out everything else") > Signed-off-by: John S. Gruber > --- > > Adjusted the patch for John Hubbard's comments. > > arch/x86/include/asm/bootparam_utils.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/x86/include/asm/bootparam_utils.h > b/arch/x86/include/asm/bootparam_utils.h > index 9e5f3c7..981fe92 100644 > --- a/arch/x86/include/asm/bootparam_utils.h > +++ b/arch/x86/include/asm/bootparam_utils.h > @@ -70,6 +70,7 @@ static void sanitize_boot_params(struct boot_params > *boot_params) gmail has managed to chew this patch: checking file arch/x86/include/asm/bootparam_utils.h patch: **** malformed patch at line 48: *boot_params) See: https://www.kernel.org/doc/html/latest/process/email-clients.html#gmail-web-gui You might find a better client in there if you wanna send more patches in the future. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.