From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mx.groups.io with SMTP id smtpd.web12.13903.1663689229854637178 for ; Tue, 20 Sep 2022 08:53:50 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=NO6ndd3A; spf=pass (domain: intel.com, ip: 134.134.136.100, 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=1663689229; x=1695225229; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=cuoeWPO+I3JxhXIy+1okW9bTdBPy92iVyY3Yu3TikNM=; b=NO6ndd3A1K2MhCPZm8lHoxcVgbKCEZS4oNFG5Vy4ZzU+2aRinNeGySVG FVp2oUMcOPrnPCKz0hrKOs7GxeIP3YTBTxcEMWjcAR/AQekamVHVtxkFr Lvg43wg9rHQVPsc/SkPREYSHrZ0J7fhxnipp1QXRQkr2ivUnZ+rUm8H+s oywJ/lFYGWZbEg5eknp6Nsf+tRGqCHeeS6XhABjTK6luVqJwTdzBzt07i UK7rARhn992hh1ydjF7YFyD61pjWwOwM/w3oEc3n3oIkVbbu64lzgOrf0 l6AEkm3L4ryL8Pg9rRIYlpjxq24aRwasFhc8HabZyr5TgtyP3OUGe3+FO Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10476"; a="363693232" X-IronPort-AV: E=Sophos;i="5.93,331,1654585200"; d="scan'208";a="363693232" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Sep 2022 08:53:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,331,1654585200"; d="scan'208";a="947724744" Received: from orsmsx601.amr.corp.intel.com ([10.22.229.14]) by fmsmga005.fm.intel.com with ESMTP; 20 Sep 2022 08:53:48 -0700 Received: from orsmsx609.amr.corp.intel.com (10.22.229.22) by ORSMSX601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 20 Sep 2022 08:53:48 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX609.amr.corp.intel.com (10.22.229.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 20 Sep 2022 08:53:48 -0700 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31 via Frontend Transport; Tue, 20 Sep 2022 08:53:48 -0700 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.177) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2375.31; Tue, 20 Sep 2022 08:53:47 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UyNlZ/DqVs6SZtrasbSdvf8T4wnnxYsJK3Fr2MUXosH4CdkVkagMfiQ0qk/Acu8kS7P4UpkKggRbyK14t3ZVYXWDthDi0RxgKvAuuUO40amatYn0v1hZDTI9QlGIamulotOfbxY5n7b/LeOrPxPH1Pzh+aMViGBVfl9aTW17Jie24jDrR0fIL0l1IBSw/ZmWHgIqv2b328OPY6+YpJQ9lmx+xmoGSZ/C4v7IA97wKC5qLTlnIGBGKevSXsqs48wwkQLNDg2+Oxbr04a8n61a/VpFEXz4kFxxWFwWWQqLL4qPqfNJZcSJywzLl2TFpn8eMnHedkqQcVRk6odxuBAlPg== 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=Ek9uxfRERIqtisIQg7AJzR+MCAyTdA3CJlOMcAOJzUc=; b=n21BNDLW6SZLPsegQAbQgBz9/sNcSZHnvMgzjcZSWB++n21LHr5LMPiAHlZyi+dy/A/3ss4XNWi5uRjyk0LPkjcpI8vgu/TuikcQuOV8ouOunauRuIM3BSNCf6r6CIb1GDF6SP4apuzxJ2Bx1BPwDmdXl+RJiPiy/Wp5V95/yCUyL2emQVu6sXIOt510Pm7fcSN2TsLxfQgBQYcH7ZqNCj9l+ygo5Po9tRSyt1lANOffFu1/2LQXeyEOHGXLwJIqKiyremy72Z2rgpmQc2Yc6H9qNUy1re4QVlkZZTLgpW81+QTEULjzqYnHhlWfbCtYYn9z6o5854BCdeTtY7ei4A== 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 SJ0PR11MB5678.namprd11.prod.outlook.com (2603:10b6:a03:3b8::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5654.14; Tue, 20 Sep 2022 15:53:45 +0000 Received: from MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::c17d:f1c9:e958:b5e]) by MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::c17d:f1c9:e958:b5e%6]) with mapi id 15.20.5632.016; Tue, 20 Sep 2022 15:53:45 +0000 From: "Yao, Jiewen" To: "Zhang, Qi1" , "devel@edk2.groups.io" CC: "Wang, Jian J" , "Lu, Xiaoyu1" , "Jiang, Guomin" Subject: Re: [PATCH 0/4] CryptoPkg: add AeadAesGcm support. Thread-Topic: [PATCH 0/4] CryptoPkg: add AeadAesGcm support. Thread-Index: AQHYu4NajGgEBuyuJk2xEp4f4omxf63omzVw Date: Tue, 20 Sep 2022 15:53:45 +0000 Message-ID: References: <20220829084254.8624-1-qi1.zhang@intel.com> In-Reply-To: <20220829084254.8624-1-qi1.zhang@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.6.500.17 dlp-product: dlpe-windows dlp-reaction: no-action 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_|SJ0PR11MB5678:EE_ x-ms-office365-filtering-correlation-id: b38744cc-4506-4d28-fa8e-08da9b204cba x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: zCUH+5x2781PTsMGDJDEnv34pOlfnYSwhSvPT94ocud1Dcjt69ahG+h1HEBjtiqyYG1yvDXMx96huIlC8u46JGtDNPFl13PlpicRLLP0dleLAEIGVy5NGz/gxrfPkYZtjbr4dDfK45wOf/+mUGgEpST23Ky2mluf7ujrq/OhpIzZR/hVzOzcUb1wk99hxclEYsUG8G5i6Vzz/4yfsaPfv/bWgJrIAk2+k6FPBW9ogAc1bvSS8lA+wK80oH6y04DWVlgo11pkQwjOLiFiFt0vtmktiXAfCKk4oXU4F7FgrYMDiQHaFsUKfBIH6P+4n3ektjTjNyAyCPNsEmOkfi1dXBMn42FR3Hh8Ba8jzPoCIZDtAdUC//ycMzuvuTiGk8XuDa9qee93P2uoiweSJlvWiI4V4fAGLVI7Qc8T0kKUlTtyHbjrfGYrACKGJyutOKDEtO7QfTpe0GOLsVGO5TyWUNXUowQH0CDFs2ltyF5CrY0KnLELMgADFSJltVwxmo4acBUGuM+qxq471z63UrUDrKu1zk0tiZeewEEyepN5wwkoKGw/SLvQvnvkkIcmyHRF8/USfAMeoxJzgJafe/btelAeOUe/78Tcy3buAxGvWKEWiR47Xo1fPKQbNL9Uzbhwm8xnBq4ayk6CNwCSEjd0X9qA9n/+t80riblbueXVS+y2qhrEO3b3GQqF0HN39D8GRMIlJUIOgDmB8XLOMCEEgM2mxoAE1pvH1skEPsV2wgGcqmg/n4Nv7N2qfeuxDyPDjIdqq/1eiQhImlLyCmeYbjRG6UIAZURss5Gtt+hf+NZXxyZvH9IuZx1zHArSdkkKW+aOPOHXQ42z5q9eHRLw8Q== 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)(366004)(346002)(376002)(136003)(396003)(39860400002)(451199015)(478600001)(66556008)(966005)(76116006)(66946007)(110136005)(54906003)(33656002)(71200400001)(107886003)(66446008)(64756008)(4326008)(41300700001)(8676002)(86362001)(6506007)(7696005)(53546011)(52536014)(66476007)(38070700005)(8936002)(26005)(55016003)(122000001)(83380400001)(38100700002)(5660300002)(9686003)(82960400001)(316002)(186003)(2906002);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?n/E46O6mQBtkIk0ah2OIQa7umRs/jkqxNu/sS/tBk/fYmhG3Q/tthQo7VI0+?= =?us-ascii?Q?NwMZ5yXI2uxXwdamrxYsxUzr/+ZF9T9mikIGhe48v89FA3gsStQZ/ZZ6U7g9?= =?us-ascii?Q?HStC9DDxQ4D6fXAftZGkRmNVUxGRIopLaSaR0stgVDjCC7boudjByivrmYYg?= =?us-ascii?Q?2B1ZnmVKKwK0hqPlstsW/FVXsM0GqJUynbJ7RXQjq4ysWorg0hCYKRKIYNgf?= =?us-ascii?Q?nbLKDofvjp86H9s468MJ0Z+hQxj8C3SI9jgq2B3zCSAl01gE8tkUgyjM6pPg?= =?us-ascii?Q?6MJTj7BDO447R2WQ2sv3wRyM315Kv7cgzs9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nq3jaKnOCVoHOAkdSzym1Yn2n7f8r0hQFeXI/BqX3RTBKQU/TN5ul73Uy?= =?us-ascii?Q?SRXqP17LDmwWGgWI0B++nOxGVKileuN+kIXwu83Qx5NSBr6rdj67om+CtY+T?= =?us-ascii?Q?vU+WDHo1eHs7ovXVCc01M25KPJNMh/02/Hs2DIpRy0fgytpa+mg/T26Ys6Q0?= =?us-ascii?Q?DtBxQgSLW7WkhB44uQYWrmxqcnhdYuSDeBgDPEPpf0j/wPEADhXdIT1JDwvQ?= =?us-ascii?Q?bAM44jpojeFK1NfRkAbLc3DhjEwmM/9CMSy+kaoArIlPvXI6zQZtcljMC8nT?= =?us-ascii?Q?ATJ8/iYA/BedArtcJmyuN0jSS8CfZncMTB8dkR5HuMgmnxM9MfMucqPfB7u2?= =?us-ascii?Q?A+0tk7YJftfbuberiE5+cPj90fxH1sgvA6cOEvJD?= 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: b38744cc-4506-4d28-fa8e-08da9b204cba X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Sep 2022 15:53:45.4615 (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: KfZklM+QSgQZ8suumGGauw/y4b8AnJaqV6qQexxT1dZhTmTav9oVT1mxFavruY9xy2Om+l3pRrejo0feOdRWlQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR11MB5678 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 Thanks for the patch. Please 1) Update the EDKII_CRYPTO_VERSION to higher version With that change, reviewed-by: Jiewen Yao > -----Original Message----- > From: Zhang, Qi1 > Sent: Monday, August 29, 2022 4:43 PM > To: devel@edk2.groups.io > Cc: Zhang, Qi1 ; Yao, Jiewen > ; Wang, Jian J ; Lu, Xiaoyu1 > ; Jiang, Guomin > Subject: [PATCH 0/4] CryptoPkg: add AeadAesGcm support. >=20 > Add AeadAesGcm Encrypt and Decrypt. > With this change, the size increase of BaseCyrptLib is about 60K bytes. > The new functions are verifed by the Host UnitTest. > And also it has been integratd in > https://github.com/tianocore/edk2-staging/tree/DeviceSecurity and been > verified. >=20 > All the code change is on the PR > https://github.com/tianocore/edk2/pull/3252. >=20 >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4036 >=20 > Signed-off-by: Qi Zhang > Cc: Jiewen Yao > Cc: Jian J Wang > Cc: Xiaoyu Lu > Cc: Guomin Jiang >=20 > Qi Zhang (4): > CryptoPkg: add AeadAesGcm function() definition. > CryptoPkg: add AeadAesGcm support. > CryptoPkg: add AeadAesGcm to Crypto Service. > CryptoPkg: add UnitTest for AeadAesGcm. >=20 > CryptoPkg/CryptoPkg.dsc | 2 + > CryptoPkg/Driver/Crypto.c | 94 +++++- > CryptoPkg/Include/Library/BaseCryptLib.h | 87 ++++++ > .../Pcd/PcdCryptoServiceFamilyEnable.h | 7 + > .../Library/BaseCryptLib/BaseCryptLib.inf | 1 + > .../BaseCryptLib/Cipher/CryptAeadAesGcm.c | 279 > ++++++++++++++++++ > .../BaseCryptLib/Cipher/CryptAeadAesGcmNull.c | 100 +++++++ > .../Library/BaseCryptLib/PeiCryptLib.inf | 1 + > .../Library/BaseCryptLib/RuntimeCryptLib.inf | 1 + > .../Library/BaseCryptLib/SmmCryptLib.inf | 1 + > .../BaseCryptLib/UnitTestHostBaseCryptLib.inf | 1 + > .../BaseCryptLibNull/BaseCryptLibNull.inf | 1 + > .../Cipher/CryptAeadAesGcmNull.c | 100 +++++++ > .../BaseCryptLibOnProtocolPpi/CryptLib.c | 93 ++++++ > CryptoPkg/Private/Protocol/Crypto.h | 86 ++++++ > .../Library/BaseCryptLib/AeadAesGcmTests.c | 112 +++++++ > .../BaseCryptLib/BaseCryptLibUnitTests.c | 1 + > .../Library/BaseCryptLib/TestBaseCryptLib.h | 3 + > .../BaseCryptLib/TestBaseCryptLibHost.inf | 1 + > .../BaseCryptLib/TestBaseCryptLibShell.inf | 1 + > 20 files changed, 971 insertions(+), 1 deletion(-) > create mode 100644 > CryptoPkg/Library/BaseCryptLib/Cipher/CryptAeadAesGcm.c > create mode 100644 > CryptoPkg/Library/BaseCryptLib/Cipher/CryptAeadAesGcmNull.c > create mode 100644 > CryptoPkg/Library/BaseCryptLibNull/Cipher/CryptAeadAesGcmNull.c > create mode 100644 > CryptoPkg/Test/UnitTest/Library/BaseCryptLib/AeadAesGcmTests.c >=20 > -- > 2.26.2.windows.1