Received: by 2002:a05:6512:2355:0:0:0:0 with SMTP id p21csp213993lfu; Wed, 30 Mar 2022 21:17:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWTp/AqEwcottlNLy8tY94VrT4iWiEZQ3Tv18isCignpr/0bKfyEFR53CcvvNuAq2X70Yv X-Received: by 2002:a65:6813:0:b0:384:b288:8702 with SMTP id l19-20020a656813000000b00384b2888702mr9193110pgt.275.1648700250025; Wed, 30 Mar 2022 21:17:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648700250; cv=none; d=google.com; s=arc-20160816; b=xu1V43JhUjone+mzKIVlI+Nj173a6ckEhO/vj+Ub9pWSEDT3cdPSjhNsT7Ha9Fi7cd b7NlDFc5J3pj8RMEg5/sJZin2lI5XmGpob/PlvqVm3FVzpzXu2ECRovWTiVUYgRVhGl+ Auue7L+YbNEakKHbQH1SR2uLqkTN3raY1tZPudAeRMcCiPpAJbSyhrw1gggBiabYykTJ PNoqPqVYPbJlucIEO/Siv41xie6DrQkI+/zXIfVPVRtDlOREHaxzgA+Pb9hhWvNMoc+I 9zeugQCIX4kSXIdSQXqWQ2wTBBHC5tuuLEHsV9z8T7YMX89LZcFH2fQHL7yDVikqEOHR Hezg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=uJ8fGWafwTAlv9l0mlHzIkRAfu4fTlLcAJxukJfW5Rs=; b=Olz6BQQqIK1N+I5r3LVXwPRoL6IrFGoDcuj7JnhSEcUyxSfm88faGnckElnLBWiXSV hNoYgIyE3dG6UKJ1NMxuEoA079B3YcnDAFyTpLtqwpOYtUwnD75qRJNcKsY3lBXDCk6c eAD80jeD+LX+zcbSbTZ+7QhA984RY0hCqqcimGSLszodhH9rkbJ8LZrxvdb6/dA58Ob+ dztZB6/PDGIqlialeRg67YExKGlwfTGCFpP1YQeS/xLghiLGj4A1KRxzCdFYZ4w4xDcO n4pLPDDwt0rK8Qk9qeZTtkvOlofpu+Kzye9YWPIGerJkgUjHbyIPnj0zir7qCU0ZmipO DQGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=pgvUDWE9; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id t15-20020a17090340cf00b00153b2d16543si21484331pld.331.2022.03.30.21.17.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Mar 2022 21:17:30 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=pgvUDWE9; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 7C32218C0D1; Wed, 30 Mar 2022 20:13:31 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243693AbiC3HOT (ORCPT + 99 others); Wed, 30 Mar 2022 03:14:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243055AbiC3HOS (ORCPT ); Wed, 30 Mar 2022 03:14:18 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2A5C3151D3E; Wed, 30 Mar 2022 00:12:34 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id DA89DB81B80; Wed, 30 Mar 2022 07:12:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8D220C34111; Wed, 30 Mar 2022 07:12:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1648624351; bh=uJ8fGWafwTAlv9l0mlHzIkRAfu4fTlLcAJxukJfW5Rs=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=pgvUDWE9UXji6tVNbju1EZUgfKHoVHnkibIlMTHQncldluAvnLmS+7VbjoxPH/+8O J6bgcoogOQVhw/uDL54psXULio0507TAKJ9bM7sm/y+vmBd0PVBz5JgCrgHEg/weG8 JwGG/nF8lD5f8MdZAYKLgglOQgPMe8QhzTXwPEI1dV6+wT2qJkPDKy7xXfvNKw19TA 99hvMjinK3OZVfRfSw+OhgCh0bJaG/vNLbO1sYZ/ILgp2v7sGeCTe8rwT51Xr17uCY fEMLHw5HFCiV84a9v6nghikBs9CPoVoAa2q/C0C/OXFyM7OcrPOHRU92dW5QlQAt38 YSNFWJce+kRvw== Received: by mail-oa1-f41.google.com with SMTP id 586e51a60fabf-deb9295679so13995637fac.6; Wed, 30 Mar 2022 00:12:31 -0700 (PDT) X-Gm-Message-State: AOAM531j0ntctz051Z4Ha1IWOHKd85rOKkinJjWFNV6S/Ql2LszwRkQs PGS8gHXgI2ca2dZi+q0PbktQmiIz3tB6j9dMF30= X-Received: by 2002:a05:6870:b027:b0:de:7fcd:fabf with SMTP id y39-20020a056870b02700b000de7fcdfabfmr1592279oae.126.1648624350700; Wed, 30 Mar 2022 00:12:30 -0700 (PDT) MIME-Version: 1.0 References: <20220329174057.GA17778@srcf.ucam.org> <20220330071103.GA809@srcf.ucam.org> In-Reply-To: <20220330071103.GA809@srcf.ucam.org> From: Ard Biesheuvel Date: Wed, 30 Mar 2022 09:12:19 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Linux DRTM on UEFI platforms To: Matthew Garrett Cc: Daniel Kiper , Alec Brown , Kanth Ghatraju , Ross Philipson , "dpsmith@apertussolutions.com" , "piotr.krol@3mdeb.com" , "krystian.hebel@3mdeb.com" , "persaur@gmail.com" , "Yoder, Stuart" , Andrew Cooper , "michal.zygowski@3mdeb.com" , James Bottomley , "lukasz@hawrylko.pl" , linux-efi , Linux Kernel Mailing List , The development of GNU GRUB , Kees Cook Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 30 Mar 2022 at 09:11, Matthew Garrett wrote: > > On Wed, Mar 30, 2022 at 09:02:18AM +0200, Ard Biesheuvel wrote: > > > Wouldn't it be better for the secure launch kernel to boot the EFI > > entrypoint directly? As it happens, I just completed a PoC last week > > for a minimal implementation of EFI (in Rust) that only carries the > > pieces that the EFI stub needs to boot Linux. It is currently just a > > proof of concept that only works on QEMU/arm64, but it should not be > > too hard to adapt it for x86 and for booting a kernel that has already > > been loaded to memory. > > The EFI stub carries out a bunch of actions that have meaningful > security impact, and that's material that should be measured. Having the > secure launch kernel execute the stub without awareness of what it does > means it would need to measure the code without measuring the state, > while the goal of DRTM solutions is to measure state rather than the > code. But how is that any different from the early kernel code?