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.web10.14305.1667720130144610892 for ; Sun, 06 Nov 2022 00:35:30 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=GH+Pp/ax; spf=pass (domain: intel.com, ip: 134.134.136.100, mailfrom: judah.vang@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1667720130; x=1699256130; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=cbhp6D38Ka6gHgC1AUQivpACdIKVNPvkJIIzF5DUE6A=; b=GH+Pp/axwo1YIdhzEGOJiewH3kWTs1BjxLNHvKU66BkxnAVOhDm44njf rLIYj0pLVhqX+xWgvmaRG+2m11i0O+zLiXAiH3Jge9PNhF/KBWnaPXxsE SQas9kt+NyoM/4GBo9qz5XsVtiGCLjs9GlnFgJRRDxr/cuSt/5UOl19ju BZA1LeITnf9Kr8u4/E9/Ysz5dhN5lX8l0SIhnuw+3aLxFajINI/fPwS+D VPmkW3D62gv4PuNkFaU6LBjTRLPrp/xsBXT4LVBGjxTsDbJlXuvqhhZoe aH8a9IHo3R49QDXfwzXjTrA2JjIa3l1K6hxvDz4dNHg/Xu8OZcSxY6laL A==; X-IronPort-AV: E=McAfee;i="6500,9779,10522"; a="374479445" X-IronPort-AV: E=Sophos;i="5.96,142,1665471600"; d="scan'208";a="374479445" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Nov 2022 00:35:29 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10522"; a="810513458" X-IronPort-AV: E=Sophos;i="5.96,142,1665471600"; d="scan'208";a="810513458" Received: from jvang-mobl.amr.corp.intel.com ([10.209.139.244]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Nov 2022 00:35:29 -0700 From: "Judah Vang" To: devel@edk2.groups.io Cc: Jian J Wang , Liming Gao , Nishant C Mistry Subject: [PATCH v5 09/19] MdeModulePkg: Reference Null ProtectedVariableLib Date: Sun, 6 Nov 2022 00:34:59 -0700 Message-Id: <20221106073509.3071-10-judah.vang@intel.com> X-Mailer: git-send-email 2.35.1.windows.2 In-Reply-To: <20221106073509.3071-1-judah.vang@intel.com> References: <20221106073509.3071-1-judah.vang@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2594 V5: Add reference to new Protected Variable libs. V1: Make reference to new Null ProtectVariableLib. The null ProtectedVariableLib is used by default. Cc: Jian J Wang Cc: Liming Gao Cc: Nishant C Mistry Signed-off-by: Jian J Wang Signed-off-by: Nishant C Mistry Signed-off-by: Judah Vang --- MdeModulePkg/MdeModulePkg.dsc | 20 +++++++++++++++++++- MdeModulePkg/Test/MdeModulePkgHostTest.dsc | 8 ++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/MdeModulePkg/MdeModulePkg.dsc b/MdeModulePkg/MdeModulePkg.dsc index 659482ab737f..65ec6d1e0918 100644 --- a/MdeModulePkg/MdeModulePkg.dsc +++ b/MdeModulePkg/MdeModulePkg.dsc @@ -2,7 +2,7 @@ # EFI/PI Reference Module Package for All Architectures # # (C) Copyright 2014 Hewlett-Packard Development Company, L.P.
-# Copyright (c) 2007 - 2021, Intel Corporation. All rights reserved.
+# Copyright (c) 2007 - 2022, Intel Corporation. All rights reserved.
# Copyright (c) Microsoft Corporation. # # SPDX-License-Identifier: BSD-2-Clause-Patent @@ -104,6 +104,7 @@ [LibraryClasses] VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf MmUnblockMemoryLib|MdePkg/Library/MmUnblockMemoryLib/MmUnblockMemoryLibNull.inf VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf + ProtectedVariableLib|MdeModulePkg/Library/ProtectedVariableLibNull/ProtectedVariableLibNull.inf [LibraryClasses.EBC.PEIM] IoLib|MdePkg/Library/PeiIoLibCpuIo/PeiIoLibCpuIo.inf @@ -318,6 +319,7 @@ [Components] MdeModulePkg/Library/PlatformBootManagerLibNull/PlatformBootManagerLibNull.inf MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf MdeModulePkg/Library/TpmMeasurementLibNull/TpmMeasurementLibNull.inf + MdeModulePkg/Library/ProtectedVariableLibNull/ProtectedVariableLibNull.inf MdeModulePkg/Library/AuthVariableLibNull/AuthVariableLibNull.inf MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLib.inf MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf @@ -397,6 +399,7 @@ [Components] MdeModulePkg/Application/VariableInfo/VariableInfo.inf MdeModulePkg/Universal/FaultTolerantWritePei/FaultTolerantWritePei.inf MdeModulePkg/Universal/Variable/Pei/VariablePei.inf + MdeModulePkg/Universal/Variable/Protected/Pei/VariablePei.inf MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf MdeModulePkg/Universal/TimestampDxe/TimestampDxe.inf MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf @@ -461,6 +464,7 @@ [Components.IA32, Components.X64, Components.ARM, Components.AARCH64] !if $(TOOL_CHAIN_TAG) != "XCODE5" MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteStandaloneMm.inf MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf + MdeModulePkg/Universal/Variable/Protected/RuntimeDxe/VariableStandaloneMm.inf !endif [Components.IA32, Components.X64] @@ -475,13 +479,27 @@ [Components.IA32, Components.X64] NULL|MdeModulePkg/Library/VarCheckHiiLib/VarCheckHiiLib.inf NULL|MdeModulePkg/Library/VarCheckPcdLib/VarCheckPcdLib.inf } + MdeModulePkg/Universal/Variable/Protected/RuntimeDxe/VariableSmm.inf { + + NULL|MdeModulePkg/Library/VarCheckPolicyLib/VarCheckPolicyLib.inf + NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf + NULL|MdeModulePkg/Library/VarCheckHiiLib/VarCheckHiiLib.inf + NULL|MdeModulePkg/Library/VarCheckPcdLib/VarCheckPcdLib.inf + } MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf { NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf NULL|MdeModulePkg/Library/VarCheckHiiLib/VarCheckHiiLib.inf NULL|MdeModulePkg/Library/VarCheckPcdLib/VarCheckPcdLib.inf } + MdeModulePkg/Universal/Variable/Protected/RuntimeDxe/VariableRuntimeDxe.inf { + + NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf + NULL|MdeModulePkg/Library/VarCheckHiiLib/VarCheckHiiLib.inf + NULL|MdeModulePkg/Library/VarCheckPcdLib/VarCheckPcdLib.inf + } MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.inf + MdeModulePkg/Universal/Variable/Protected/RuntimeDxe/VariableSmmRuntimeDxe.inf MdeModulePkg/Library/SmmReportStatusCodeLib/SmmReportStatusCodeLib.inf MdeModulePkg/Library/SmmReportStatusCodeLib/StandaloneMmReportStatusCodeLib.inf MdeModulePkg/Universal/StatusCodeHandler/Smm/StatusCodeHandlerSmm.inf diff --git a/MdeModulePkg/Test/MdeModulePkgHostTest.dsc b/MdeModulePkg/Test/MdeModulePkgHostTest.dsc index c9ec835df65d..c0ca9be71e8c 100644 --- a/MdeModulePkg/Test/MdeModulePkgHostTest.dsc +++ b/MdeModulePkg/Test/MdeModulePkgHostTest.dsc @@ -42,6 +42,14 @@ [Components] gEfiMdeModulePkgTokenSpaceGuid.PcdAllowVariablePolicyEnforcementDisable|TRUE } + MdeModulePkg/Universal/Variable/Protected/RuntimeDxe/RuntimeDxeUnitTest/VariableLockRequestToLockUnitTest.inf { + + VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLib.inf + VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf + + gEfiMdeModulePkgTokenSpaceGuid.PcdAllowVariablePolicyEnforcementDisable|TRUE + } + MdeModulePkg/Library/UefiSortLib/UnitTest/UefiSortLibUnitTest.inf { UefiSortLib|MdeModulePkg/Library/UefiSortLib/UefiSortLib.inf -- 2.35.1.windows.2