From nobody Sun May 19 18:35:15 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+64347+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+64347+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1597719239; cv=none; d=zohomail.com; s=zohoarc; b=bOttfheBiFrC0bFz/MG+5nTpk9/jRrKxf9in4zOr0KNy6NODtLveCH52gb8GQP05uz0vnHIxgtA+I0EdjtP0N3nRduFRN9NFn81yWVbXine6rgj7mWoNPjSl1w07VCdLeXDWlGxtX7EHvG673VUVMenagMTYsPQzlhaPhBj042w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1597719239; h=Content-Transfer-Encoding:Cc:Date:From:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Sender:Subject:To; bh=LTLYvC5KjOurH8l1xAsHYed9UtEb73e8DwJT7EaDhls=; b=LGhcHa9MCPuP1xhisyWUdASAX1bHfLfsInpkRSOdW66Z41BB60hICAz2FUkKM+NMKaSwMbelZIJSUuEBOsY0jrfVD5h/t5hE3l36xJxlR5FhLv1CWDaf9Pks8WZceuBBWmPnVcyKIUGNdCxb06BiY3hYR+oKfmqVGwEdWjlMYlM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+64347+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1597719239238150.3987496747494; Mon, 17 Aug 2020 19:53:59 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id XW4vYY1788612xDy1WwshYiK; Mon, 17 Aug 2020 19:53:58 -0700 X-Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mx.groups.io with SMTP id smtpd.web12.58449.1597719234563567813 for ; Mon, 17 Aug 2020 19:53:54 -0700 IronPort-SDR: ggDRvagPIaueK1M+/hcRiz2FqKIUnZBhM6BHDwiz8YyjDm26+ak9Uln+1GhR1zTRXw3pLOwuJe y3P+5PWfpFkA== X-IronPort-AV: E=McAfee;i="6000,8403,9716"; a="134353394" X-IronPort-AV: E=Sophos;i="5.76,325,1592895600"; d="scan'208";a="134353394" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Aug 2020 19:53:53 -0700 IronPort-SDR: I+eTXnKSPkfCJlKP9T9joKOAjtd5f8GfBjwV5xWa4sVQn8V1So11p4IntfFbVxbntasscOI0Cr jogUXAOycbJA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.76,325,1592895600"; d="scan'208";a="296688914" X-Received: from shwdeopensfp777.ccr.corp.intel.com ([10.239.158.78]) by orsmga006.jf.intel.com with ESMTP; 17 Aug 2020 19:53:51 -0700 From: "Wang, Jian J" To: devel@edk2.groups.io Cc: Xiaoyu Lu , Jiewen Yao , Guomin Jiang , Nishant C Mistry Subject: [edk2-devel] [PATCH] CryptoPkg/BaseCryptLib: add crypto algorithms needed by variable protection Date: Tue, 18 Aug 2020 10:53:51 +0800 Message-Id: <20200818025351.37-1-jian.j.wang@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,jian.j.wang@intel.com X-Gm-Message-State: 9DxRsWkOIwsYvqYyhzuB1I0Ex1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1597719238; bh=W2baX33nS+PnqbGw12rhTgeJlym9MSwxvcpjjkCcaTw=; h=Cc:Date:From:Reply-To:Subject:To; b=nX1opLsBVQnM9Av9ao64si9QtWQVyHYQ+b6wiNLkVs+gZUpw2YFq1dyACRqkolPzBEf pYzByTiFmAm2o/OCGw0kz4ZpkuNGhjYOaNir2X5T9yFcF2vU9FuYl5GMPzKwDUX/Cfvt8 n8LxkiQRIafDpfGXAE0gDTZDZZwQFjkh/OQ= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2594 Crypto algorithms, hkdf-sha256/hmac-sha256/aes, are needed to verify integr= ity of variable data, derive hmac and encryption keys, and encrypt/decrypt vari= ble. Replacing null version source code with real implementations makes sure we = can enable full functionalities of protected variable later. Cc: Xiaoyu Lu Cc: Jiewen Yao Cc: Guomin Jiang Cc: Nishant C Mistry Signed-off-by: Jian J Wang Reviewed-by: Jiewen Yao --- CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf | 4 ++-- CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf b/CryptoPkg/Lib= rary/BaseCryptLib/PeiCryptLib.inf index c836c257f8..af87c14a8b 100644 --- a/CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf +++ b/CryptoPkg/Library/BaseCryptLib/PeiCryptLib.inf @@ -43,8 +43,8 @@ Hash/CryptSha512.c Hmac/CryptHmacMd5Null.c Hmac/CryptHmacSha1Null.c - Hmac/CryptHmacSha256Null.c - Kdf/CryptHkdfNull.c + Hmac/CryptHmacSha256.c + Kdf/CryptHkdf.c Cipher/CryptAesNull.c Cipher/CryptTdesNull.c Cipher/CryptArc4Null.c diff --git a/CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf b/CryptoPkg= /Library/BaseCryptLib/RuntimeCryptLib.inf index e5b8ececc1..d20a48cd8a 100644 --- a/CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf +++ b/CryptoPkg/Library/BaseCryptLib/RuntimeCryptLib.inf @@ -43,9 +43,9 @@ Hash/CryptSha512Null.c Hmac/CryptHmacMd5Null.c Hmac/CryptHmacSha1Null.c - Hmac/CryptHmacSha256Null.c - Kdf/CryptHkdfNull.c - Cipher/CryptAesNull.c + Hmac/CryptHmacSha256.c + Kdf/CryptHkdf.c + Cipher/CryptAes.c Cipher/CryptTdesNull.c Cipher/CryptArc4Null.c Pk/CryptRsaBasic.c --=20 2.24.0.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#64347): https://edk2.groups.io/g/devel/message/64347 Mute This Topic: https://groups.io/mt/76258273/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-