From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.158.5]) by mx.groups.io with SMTP id smtpd.web11.10768.1631105211657169063 for ; Wed, 08 Sep 2021 05:46:51 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@ibm.com header.s=pp1 header.b=MRyUAVyw; spf=none, err=permanent DNS error (domain: linux.vnet.ibm.com, ip: 148.163.158.5, mailfrom: stefanb@linux.vnet.ibm.com) Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 188CXq5q145220; Wed, 8 Sep 2021 08:46:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=pp1; bh=F+cm4S7NIkYIcVKwfI1Pz23u8muTvVB2BXtizA0abgA=; b=MRyUAVyw4bHOq7cgpb0lEScU+XvVYkrgdtRdwNvKjWSEmLhvyrqMMzo3c5VDLS+A8QHY ymMgAc+6zloymWMmcWkSyWY0UHDmC+09j/j4viWKWzS5UCocybhppJE5ndUDZF513XeI aagadnYoRh09kgwwXbzAb0P77fbB6gCjpT+fJkMbrOS7UzApo/Ivruwb3mXholIfcYrT 6rLAzg11V6nWa4r5WWC0LFwcgkoIr1BTMnBRB1jCvfBWAJf9BY8q1k/5KgdCkPVe1R91 B71K3jZCJ4q8e/1LA7M2x3SEgn4F9EEgCwML/ckj6RDlrZYM2ePki6u2iTuH0cQF5K0J 8Q== Received: from pps.reinject (localhost [127.0.0.1]) by mx0b-001b2d01.pphosted.com with ESMTP id 3axhcer3hk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 Sep 2021 08:46:50 -0400 Received: from m0098414.ppops.net (m0098414.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.43/8.16.0.43) with SMTP id 188CYLZh146608; Wed, 8 Sep 2021 08:46:50 -0400 Received: from ppma01dal.us.ibm.com (83.d6.3fa9.ip4.static.sl-reverse.com [169.63.214.131]) by mx0b-001b2d01.pphosted.com with ESMTP id 3axhcer3h7-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 Sep 2021 08:46:50 -0400 Received: from pps.filterd (ppma01dal.us.ibm.com [127.0.0.1]) by ppma01dal.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 188Cg4ro013839; Wed, 8 Sep 2021 12:46:49 GMT Received: from b01cxnp22034.gho.pok.ibm.com (b01cxnp22034.gho.pok.ibm.com [9.57.198.24]) by ppma01dal.us.ibm.com with ESMTP id 3axcnq64p7-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 Sep 2021 12:46:49 +0000 Received: from b01ledav004.gho.pok.ibm.com (b01ledav004.gho.pok.ibm.com [9.57.199.109]) by b01cxnp22034.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 188CkmVK44761348 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 8 Sep 2021 12:46:48 GMT Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 138E611206E; Wed, 8 Sep 2021 12:46:48 +0000 (GMT) Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 0EFB8112069; Wed, 8 Sep 2021 12:46:48 +0000 (GMT) Received: from sbct-2.pok.ibm.com (unknown [9.47.158.152]) by b01ledav004.gho.pok.ibm.com (Postfix) with ESMTP; Wed, 8 Sep 2021 12:46:48 +0000 (GMT) From: Stefan Berger To: devel@edk2.groups.io Cc: mhaeuser@posteo.de, spbrogan@outlook.com, marcandre.lureau@redhat.com, kraxel@redhat.com, jiewen.yao@intel.com, Stefan Berger , Stefan Berger Subject: [PATCH v6 7/9] SecurityPkg: Disable TPM platform hierarchy if TPM resume fails (S3 resume) Date: Wed, 8 Sep 2021 08:46:42 -0400 Message-Id: <20210908124644.816856-8-stefanb@linux.vnet.ibm.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210908124644.816856-1-stefanb@linux.vnet.ibm.com> References: <20210908124644.816856-1-stefanb@linux.vnet.ibm.com> MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: nnHwymOlbSdhfg62uSYL4RXj3zlKXZnC X-Proofpoint-ORIG-GUID: hS_CCiCiHFMfRQMZWeVXf9EsiPMx2Feb X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391,18.0.790 definitions=2021-09-08_05:2021-09-07,2021-09-08 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=999 priorityscore=1501 adultscore=0 phishscore=0 impostorscore=0 clxscore=1015 mlxscore=0 malwarescore=0 suspectscore=0 lowpriorityscore=0 spamscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2109030001 definitions=main-2109080080 Content-Transfer-Encoding: quoted-printable If Tpm2Startup(TPM_SU_STATE) fails, call ConfigureTPMPlatformHierarchy() to disable the platform hierarchy. Signed-off-by: Stefan Berger --- SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c | 2 ++ SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.inf | 1 + 2 files changed, 3 insertions(+) diff --git a/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c b/SecurityPkg/Tcg/Tcg2Pei/Tc= g2Pei.c index 93a8803ff6..63323b9509 100644 --- a/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c +++ b/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c @@ -30,6 +30,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include =0D #include =0D #include =0D +#include =0D #include =0D #include =0D #include =0D @@ -1050,6 +1051,7 @@ PeimEntryMA ( if (!EFI_ERROR(Status)) {=0D S3ErrorReport =3D TRUE;=0D }=0D + ConfigureTpmPlatformHierarchy ();=0D }=0D } else {=0D Status =3D Tpm2Startup (TPM_SU_CLEAR);=0D diff --git a/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.inf b/SecurityPkg/Tcg/Tcg2Pei/= Tcg2Pei.inf index 06c26a2904..2f4988eb6b 100644 --- a/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.inf +++ b/SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.inf @@ -55,6 +55,7 @@ ReportStatusCodeLib=0D ResetSystemLib=0D PrintLib=0D + TpmPlatformHierarchyLib=0D =0D [Guids]=0D gTcgEventEntryHobGuid ## = PRODUCES ## HOB=0D --=20 2.31.1