From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mx.groups.io with SMTP id smtpd.web10.108401.1671035091982476395 for ; Wed, 14 Dec 2022 08:24:52 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=m6epKOPN; spf=pass (domain: intel.com, ip: 192.55.52.120, mailfrom: jiewen.yao@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1671035091; x=1702571091; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=3rICLI7QN6IpVg3nBteIy9Vv/COOIfxTGSAdaCYmWX8=; b=m6epKOPNxYQKXNmOdkN4xw6xtmgvWHXVS1DMHfssgUL5oHTklRYZOsza s0sQxH5OHDqFM02IPxmik19vxUa+SpG48xJGFYiMVGCLqwMt853azDVfM o1tNAZ2H22uQc5fuH3CaAX8Cvl6lkJaiRG+IYOaQyAkmCZIFRzlnMloWd 3kvKhOLvK/tDYE8yZOs3KCvXbfgzoUNeaHGgyUu50gBr70Mx2SId5RQc1 kvXhpiGxNbOOUbAt9tnyyrK5h3xnoGfLX7+2qZ3q3Lc19IzBydH1u7PIF sf5vZgES1lo2N2YgIpUGFmjbR72Y4J3oNLPNIxAQc1OyXkmifil2V3bVy Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10561"; a="317154591" X-IronPort-AV: E=Sophos;i="5.96,244,1665471600"; d="scan'208";a="317154591" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Dec 2022 08:24:51 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10561"; a="791347636" X-IronPort-AV: E=Sophos;i="5.96,244,1665471600"; d="scan'208";a="791347636" Received: from fmsmsx603.amr.corp.intel.com ([10.18.126.83]) by fmsmga001.fm.intel.com with ESMTP; 14 Dec 2022 08:24:51 -0800 Received: from fmsmsx602.amr.corp.intel.com (10.18.126.82) by fmsmsx603.amr.corp.intel.com (10.18.126.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 14 Dec 2022 08:24:51 -0800 Received: from fmsedg602.ED.cps.intel.com (10.1.192.136) by fmsmsx602.amr.corp.intel.com (10.18.126.82) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16 via Frontend Transport; Wed, 14 Dec 2022 08:24:51 -0800 Received: from NAM04-MW2-obe.outbound.protection.outlook.com (104.47.73.171) by edgegateway.intel.com (192.55.55.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.16; Wed, 14 Dec 2022 08:24:51 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bfpnFqNMtKsrusL3gkw7POcQ8fSqx4GpZHazT5ddY1gw4BGU1eoypn7RE4EdQmT6gQHPN8EOhdEuQQKCILKha+em/WuihEFO4su6vX5VH54nO6nwLfnlrNkJuBAsHAWaqCFSXcDKS0Ttz0pmPugaOne5JFpCI2Ev+jHw5McMppHmtJLopiTAAR+fw15UxBOJbVzN84kh+i/0n48IH2Wi4wXrETkxZNy++102snrO4L4o2qsYpyDmaKUxU5323RLAw4TN3y9nGl7wmkqvuayml1hZHXfn+px8NISMQX0MweRCmgQ4EPZsX+5jjtZg6PisXE5bXm3MAFoEQDO2a/MZ1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fDUemcjy5DVKwFk7iTIAsEKEtidzpDBUvSPh9Hk9Yp0=; b=QNLJdIbWonPxTPt5AJReV/3LrWSBlp4dVN9nXGhVqSxOi/nv5nIfEJ0hWWPOyqSmQA0hMpygKRd4u5XsuUoS9Q/zivjJ3reBxXJH90JpjAEua3za8HDDrspmgAoQeNe8fXBnjVaADAWf2FhtUmFQZOtidT/vycrf2ko8vvAMSbQW7DZw/kC9BKtywnE6d/osDtIIVk9joHxdZTFQuxtI1sLAgclM9b4uRW4oraL3vX7ZenJwkGHlfyr1o3jmPRMYAi/vdDJ6B5CYb9Wcp+BzWCTWkogxK69VgaMkwAKSVYvu3P3hQQXCq5/z78dhqLON8uL4nHwQPR0NSWkO5zQK0w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from MW4PR11MB5872.namprd11.prod.outlook.com (2603:10b6:303:169::14) by CO1PR11MB4785.namprd11.prod.outlook.com (2603:10b6:303:6f::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5880.19; Wed, 14 Dec 2022 16:24:48 +0000 Received: from MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::5f56:1bdc:2eae:c041]) by MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::5f56:1bdc:2eae:c041%9]) with mapi id 15.20.5880.019; Wed, 14 Dec 2022 16:24:47 +0000 From: "Yao, Jiewen" To: "Xu, Min M" , "devel@edk2.groups.io" CC: "Aktas, Erdem" , James Bottomley , Tom Lendacky , Arti Gupta Subject: Re: [PATCH V1 0/3] Fix incorrect implementation in CcMeasurement Thread-Topic: [PATCH V1 0/3] Fix incorrect implementation in CcMeasurement Thread-Index: AQHZD4vZQpYZq6acZ0C7rgb2GsgMV65tkfig Date: Wed, 14 Dec 2022 16:24:47 +0000 Message-ID: References: <20221214071419.1813-1-min.m.xu@intel.com> In-Reply-To: <20221214071419.1813-1-min.m.xu@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: MW4PR11MB5872:EE_|CO1PR11MB4785:EE_ x-ms-office365-filtering-correlation-id: 682daabf-e47f-4b53-4d30-08daddefb7f3 x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: xY3e0NQJh38gbwTbL+Pya/alBeHickIluhu5s3T/xjywWWfQUoaqdhSl6ldav//98JmlViODnGTDLLeC8jcb+XExjv+LREoYElg7k0f2oPwvsJBYKV/OU+fNLk65asjS0t6lzI172ZYZz7+FtyUlN8P85qhPyFyCzvcSUSmhbYtuSylY96NCY+uCnXmUYBAZ6Mz+u8sWU8/u3Wfl/oToaiH9Lcb8ueFFlAI9pPpp3UKqeh2PJx+bT0d0yI2slf78jWDozGM3afJuRrwGwbUFizMOG88zii1GRrDnnDVlebEyKgfVTuiTNeGJBvWZQHipo9mMEggbCzyAAlMrmICGy4L076Y0z+MLCvvz6HMKK1aPpEmsUEbtu3x+BASOkruedy/QTXIA6LiWPbsu1UdVja+tHU2sfFJ0R5vJDpIuP9y/gKH8W27Pfzl9f4IkoleCaU8VyTziCgNuFEBS8+Hn3MPitnmPLtB26TiZ+MZIwKqAeYQJdgs7w1u4YV3/73DPaIusLKMWcYuqhOUfaapcMg6tP6rvLsyoM0XRimdStdxI1zC/TdtoOxvAadkFkRA9Lpkz9pT0ORvD5dg0XxCqQtQnIS8ustfbmtPNEK6zv/+QJEKaP+vYWourcnKB3uRqB3bkFmBI7KFnRwKi70Y4wqkw3Nf4fBriZkvzJdLqhslDzwxMYDL+0kKk0dRGEA6Y0RVne8umBNHMKCAT4boxMPYLVHZKop06nC0clCZ3acNPSj3IGG6A3pnnxYmU5GPZ30RHEtKbOZyB0sEgEfRrRA== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW4PR11MB5872.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(6029001)(136003)(346002)(376002)(366004)(39860400002)(396003)(451199015)(66946007)(76116006)(41300700001)(4326008)(5660300002)(64756008)(8676002)(38070700005)(66476007)(66446008)(66556008)(54906003)(316002)(33656002)(19627235002)(186003)(110136005)(9686003)(8936002)(2906002)(52536014)(86362001)(478600001)(71200400001)(26005)(6506007)(966005)(7696005)(53546011)(122000001)(38100700002)(55016003)(82960400001)(83380400001);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?s3BUyBTAjKgZyvlFTN6C/25HafdJAEA1CFamUR8RUKgD/XmjoN0O/1cqF7l8?= =?us-ascii?Q?uq4EJwHe3uZ+AItAH/BYIf2mx1GfrV2yQ3J+9FlFf/yRgaXUi1hbL7bUkFM7?= =?us-ascii?Q?mP/b68wXKznFGGBrA90mjCs7ReWmK+ZdA6Mi2JrwFdl2OeoM4Ht91o4wkyBw?= =?us-ascii?Q?aEhlkJCFZEnJFzSdgfDnbVMFPC4QvwVTpvF799YQoCIKrbKdTzhLuNdNVnkr?= =?us-ascii?Q?5jSD30Ok7Y5e9tSX6AqO/x6Jr+qW0+NPBySvA8bwgZIuE7tMmkAG92dyYm24?= =?us-ascii?Q?vl0SBiGEoll6ILtbXhlQAJqilytrfwGUwf3dAFFDCOR7WIzKKbuFfZgOl1lN?= =?us-ascii?Q?XYuOJ2zV/dU1KprW6WOCERk5/tlltok+gVmoTgLwTgyBEl/1HeNnO6kGPgi4?= =?us-ascii?Q?T/CWuBpN17xM+OFTPDxvU2BCK7zte6UcYhfW6Bagoun3UHGGnRmDidI7qMBR?= =?us-ascii?Q?BAaT9S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FscOK2LY/gw/vYeA?= =?us-ascii?Q?kCHBm9oDex6G6uv9kR5JLekGOQNRto6pjjSUUHLpH3FBCZVzUSeVaBsnseT5?= =?us-ascii?Q?dpLT4vnBj/34eindjIBN1C7pwkXwJ03+BpplN8CykrwVr2DIDliAdNTjZMaG?= =?us-ascii?Q?zGqoLNqj/j+uxNko3E5GvYbf3IOG8441Cy2GbCES6lQYvpgIsn5eiWT7/cCv?= =?us-ascii?Q?dgkHW/QDh499uZA+K/utDK9jvS17fp1rmwcCw671?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MW4PR11MB5872.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 682daabf-e47f-4b53-4d30-08daddefb7f3 X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Dec 2022 16:24:47.9288 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: /3EFaH3GZOAUB99oRmw/P8yMq4K6rfbxM517ylsOE4q5XcE6gs+P8iTaiBPLw5m6XJO/h/FyKlOzTM66Zm6y9w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR11MB4785 Return-Path: jiewen.yao@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable All Reviewed-by: Jiewen Yao > -----Original Message----- > From: Xu, Min M > Sent: Wednesday, December 14, 2022 3:14 PM > To: devel@edk2.groups.io > Cc: Xu, Min M ; Aktas, Erdem > ; James Bottomley ; Yao, > Jiewen ; Tom Lendacky > ; Arti Gupta > Subject: [PATCH V1 0/3] Fix incorrect implementation in CcMeasurement >=20 > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4179 > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4184 >=20 > This patch-set fix the incorrect implementation in CcMeasurement. >=20 > Patch#1: > Incorrect protocol and structure version >=20 > Patch#2/3: > Incorrect mapping between TPM PCR index and TDX Measurement Register > index. >=20 > Code: https://github.com/mxu9/edk2/tree/CcMapping.v1 >=20 > Cc: Erdem Aktas [ruleof2] > Cc: James Bottomley [jejb] > Cc: Jiewen Yao [jyao1] > Cc: Tom Lendacky [tlendacky] > Cc: Arti Gupta > Reported-by: Arti Gupta > Signed-off-by: Min Xu >=20 > Min M Xu (3): > OvmfPkg/TdTcg2Dxe: Fix incorrect protocol and structure version > OvmfPkg/TdTcg2Dxe: Fix the mapping error between PCR index and MR > index > OvmfPkg/SecTpmMeasurementLib: Fix the mapping error of PCR and RTMR > index >=20 > OvmfPkg/IntelTdx/TdTcg2Dxe/TdTcg2Dxe.c | 93 ++++++++++++------- > .../SecTpmMeasurementLibTdx.c | 7 +- > 2 files changed, 65 insertions(+), 35 deletions(-) >=20 > -- > 2.29.2.windows.2