Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp10118667rwr; Fri, 12 May 2023 04:12:32 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4PDuf1ukpDaYXjaVg7Ct4JGlyppmiWev87M2PbaN35ujaSWf4duIEVhBURHgFuqPno+4QJ X-Received: by 2002:a17:90a:ff17:b0:24d:e937:6670 with SMTP id ce23-20020a17090aff1700b0024de9376670mr23111445pjb.19.1683889952579; Fri, 12 May 2023 04:12:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683889952; cv=none; d=google.com; s=arc-20160816; b=f+1jfGgygwc37RrNjJrtT7fy7a+QPpvVgGeLf54YFdOegb+qJ8eCRfuDZ4jlXsg8oV 94Jt+GIIw0Iv81Y4dp8hezWEeRIT/G/U9zRthsBw/1ugDpTrmGfSdETrRZIMD6hXvuCc W7dmFc8Z+szLn6vBvE7eB+aGhSWlSTfZ5KnHz3qs5/WKvPMSzYT5R0aGjcoDipgZGysw NA6jxBmOonba/MWBuh2IP2eI2aS7l5oiSEhazaNzHCcUC4FmD9/W7/LMnyEmOK6f280b 1BuIK8nEEEudJh1UR0W+UPfDYrTkdNNhIHioACEU9vvjK/zYGhHRsaEDRiA537HzF6nP ACmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=xZ/furLmQagjLHhylBJ6nNZ6ouI/uDKbds7Oi7TV9gw=; b=DKG93bEg4yQ8GwM3EJ4hOvdFX9id47g1ZYgAE3fCLkc13MIvRE7BZPMXzHXhxwggXh BRoNu1d8mAWri9wtzDY54hI+FUBNpVIQ9W5zFA5bWCadk9GkpKRU47Uuwvzom+8F1LHz gHgIAkKpSyZO242D7M4QK3jf1lnMcTq4eb3VE5tCulG5EQdlY0Z2fmWICFSPuB3EgPN1 gVaNVpBcwFqwEvFe7Jgpvqr9dJM5WL1/YlvJyDG2C6y/eNnRp19pTorc+7TPY4hV6dqk SkFxTBOQu1wnfbRLF+wCXJgF5rgq9Fzi5iczcVegqyKrv4NU3DwLcfZBmtjW0ftUok7d v25w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q13-20020a170902bd8d00b001a6b5a7db52si8623870pls.596.2023.05.12.04.12.17; Fri, 12 May 2023 04:12:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241055AbjELLFl (ORCPT + 99 others); Fri, 12 May 2023 07:05:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33528 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241022AbjELLFM (ORCPT ); Fri, 12 May 2023 07:05:12 -0400 Received: from cavan.codon.org.uk (irc.codon.org.uk [IPv6:2a00:1098:84:22e::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B9F212E92; Fri, 12 May 2023 04:04:58 -0700 (PDT) Received: by cavan.codon.org.uk (Postfix, from userid 1000) id 664F140A6F; Fri, 12 May 2023 12:04:55 +0100 (BST) Date: Fri, 12 May 2023 12:04:55 +0100 From: Matthew Garrett To: Eric Biggers Cc: Ross Philipson , linux-kernel@vger.kernel.org, x86@kernel.org, linux-integrity@vger.kernel.org, linux-doc@vger.kernel.org, linux-crypto@vger.kernel.org, iommu@lists.linux-foundation.org, kexec@lists.infradead.org, linux-efi@vger.kernel.org, dpsmith@apertussolutions.com, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, ardb@kernel.org, James.Bottomley@hansenpartnership.com, luto@amacapital.net, nivedita@alum.mit.edu, kanth.ghatraju@oracle.com, trenchboot-devel@googlegroups.com Subject: Re: [PATCH v6 06/14] x86: Add early SHA support for Secure Launch early measurements Message-ID: <20230512110455.GD14461@srcf.ucam.org> References: <20230504145023.835096-1-ross.philipson@oracle.com> <20230504145023.835096-7-ross.philipson@oracle.com> <20230510012144.GA1851@quark.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230510012144.GA1851@quark.localdomain> User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,KHOP_HELO_FCRDNS,SPF_HELO_NEUTRAL, SPF_NEUTRAL,T_SCC_BODY_TEXT_LINE autolearn=no 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-crypto@vger.kernel.org On Tue, May 09, 2023 at 06:21:44PM -0700, Eric Biggers wrote: > SHA-1 is insecure. Why are you still using SHA-1? Don't TPMs support SHA-2 > now? TXT is supported on some TPM 1.2 systems as well. TPM 2 systems are also at the whim of the firmware in terms of whether the SHA-2 banks are enabled. But even if the SHA-2 banks are enabled, if you suddenly stop extending the SHA-1 banks, a malicious actor can later turn up and extend whatever they want into them and present a SHA-1-only attestation. Ideally whatever is handling that attestation should know whether or not to expect an attestation with SHA-2, but the easiest way to maintain security is to always extend all banks.