From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by mx.groups.io with SMTP id smtpd.web09.7207.1634903849853449077 for ; Fri, 22 Oct 2021 04:57:29 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@ibm.com header.s=pp1 header.b=VkZa6dwY; spf=pass (domain: linux.ibm.com, ip: 148.163.156.1, mailfrom: stefanb@linux.ibm.com) Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 19MAoNvg003054; Fri, 22 Oct 2021 07:57:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=pp1; bh=6SI0czixY09avwHpWAiZaIMzXW27PuzsQh79EIBr100=; b=VkZa6dwYI8b8QDlSgnn8fXJ1KFZzI+PBEmIp/x8L0ASCaiFk9T6+TBGIpMlYQ23TWPay uTgCf3WLe7s+Wn7Mx7Ox6oY8kVQKOBCDL95MPGVd9kawRxELj4fIXVN9T5ctyYYcnc+d nHQRF8b/job8rJjejQJO1cnZUGY19qQEpKQx4AAU8GqGQlxJ3Ah6wiUUCJkhhWtp4zx9 OSgRObYYe2P+FaImqeh/J5BpwO/utHjV5AU7lJp00pCJ9xK9YU9O0RZJmfIWhcoT1Gua iTQhWFefeTGSFLjjobOpcbKEiQUBTCOc+fa6p+Tr0fOudArVjah5yRWsyy48x0UOeyDh oQ== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com with ESMTP id 3bub81w72v-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 22 Oct 2021 07:57:27 -0400 Received: from m0098410.ppops.net (m0098410.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.43/8.16.0.43) with SMTP id 19MBeAQJ006859; Fri, 22 Oct 2021 07:57:27 -0400 Received: from ppma04dal.us.ibm.com (7a.29.35a9.ip4.static.sl-reverse.com [169.53.41.122]) by mx0a-001b2d01.pphosted.com with ESMTP id 3bub81w72k-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 22 Oct 2021 07:57:26 -0400 Received: from pps.filterd (ppma04dal.us.ibm.com [127.0.0.1]) by ppma04dal.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 19MBlhxb001051; Fri, 22 Oct 2021 11:57:26 GMT Received: from b03cxnp08027.gho.boulder.ibm.com (b03cxnp08027.gho.boulder.ibm.com [9.17.130.19]) by ppma04dal.us.ibm.com with ESMTP id 3bqpcef22b-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 22 Oct 2021 11:57:25 +0000 Received: from b03ledav002.gho.boulder.ibm.com (b03ledav002.gho.boulder.ibm.com [9.17.130.233]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 19MBvOEe18743748 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 22 Oct 2021 11:57:24 GMT Received: from b03ledav002.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B666B136074; Fri, 22 Oct 2021 11:57:24 +0000 (GMT) Received: from b03ledav002.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 1FAAC136067; Fri, 22 Oct 2021 11:57:19 +0000 (GMT) Received: from [9.47.158.152] (unknown [9.47.158.152]) by b03ledav002.gho.boulder.ibm.com (Postfix) with ESMTP; Fri, 22 Oct 2021 11:57:18 +0000 (GMT) Subject: Re: [PATCH 4/4] OvmfPkg: add TPM2_SHA1_ENABLE build option To: jejb@linux.ibm.com, Gerd Hoffmann Cc: devel@edk2.groups.io, Min Xu , Jordan Justen , Erdem Aktas , Ard Biesheuvel , =?UTF-8?Q?Marc-Andr=c3=a9_Lureau?= , Jiewen Yao , Tom Lendacky , Brijesh Singh References: <20211021122003.2008499-1-kraxel@redhat.com> <20211021122003.2008499-5-kraxel@redhat.com> <03a75199-000f-5575-8898-6d9b113f2bee@linux.ibm.com> <20211022063948.mratwrzgponwiulg@sirius.home.kraxel.org> <46963c6b6e0eea2bf0b3629031f6f04232ea7528.camel@linux.ibm.com> From: "Stefan Berger" Message-ID: <84d94886-bc85-9b98-6c7e-59207e6ea741@linux.ibm.com> Date: Fri, 22 Oct 2021 07:57:18 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <46963c6b6e0eea2bf0b3629031f6f04232ea7528.camel@linux.ibm.com> X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: CeXIaF7cOG3O2qZRw0-XlyMkQc6ncfZL X-Proofpoint-GUID: HvmBA5trzJtGiF_uSUauXETPjctFNujC X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.0.607.475 definitions=2021-10-22_03,2021-10-21_02,2020-04-07_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 bulkscore=0 impostorscore=0 malwarescore=0 suspectscore=0 spamscore=0 adultscore=0 mlxscore=0 clxscore=1015 lowpriorityscore=0 mlxlogscore=998 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2109230001 definitions=main-2110220064 X-MIME-Autoconverted: from 8bit to quoted-printable by mx0a-001b2d01.pphosted.com id 19MAoNvg003054 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 10/22/21 7:49 AM, James Bottomley wrote: > On Fri, 2021-10-22 at 06:50 -0400, Stefan Berger wrote: > [...] >> I see this also but when I get into Linux and run tpm2_pcrread I see >> the SHA1 bank active but not having received any PCR extensions from >> the firmware, which is not supposed to happen. > That's not entirely correct: the TCG firmware profile just requires us > to log through at least one bank; it doesn't require that all active > banks be logged. I've got several physical systems with three active > banks but only one or two measured through. The problem with this is that you can then fake measured boot on that=20 system using it's unused SHA1 bank and extend into it whatever you want=20 and create a fake log along with it and the quote is going to look alrigh= t. > > The knock on problem the > linux kernel is going to have is that we do tend to expect the sha1 > bank to be extended into if any others are, so someone is going to have > to update expectations ... we should have this in hand already as sha1 > is deprecated. > >> So I think you should drop this patch and I'll change the set of >> active PCR banks on the swtpm_setup level. > Even if the firmware deactivated the sha1 bank, the kernel expectation > problem is still going to exist. Is that older Linux kernels or which part still requires sha1? A pointer=20 would be good. I would have to revert the change to not activat ethe=20 SHA1 bank from swtpm_setup if that's going to create headaches. I=20 thought some hardware TPM 2's today are only providing a SHA256 bank and=20 so it shouldn't be a problem. =C2=A0=C2=A0=C2=A0 Stefan > > James > > >