audk/MdeModulePkg/Universal/Variable/RuntimeDxe
Laszlo Ersek 7516532f9c MdeModulePkg/Variable/RuntimeDxe: delay MorLock creation until EndOfDxe
The "MemoryOverwriteRequestControl" (a.k.a. MOR) variable comes from the
"TCG Platform Reset Attack Mitigation Specification":

https://www.trustedcomputinggroup.org/wp-content/uploads/Platform-Reset-Attack-Mitigation-Specification.pdf

The "MemoryOverwriteRequestControlLock" variable (a.k.a. MORL) is a
Microsoft extension, called "Secure MOR implementation":

https://docs.microsoft.com/en-us/windows-hardware/drivers/bringup/device-guard-requirements

Currently the VariableSmm driver creates MORL without regard to MOR. This
can lead to a situation where a platform does not support MOR from the
prerequisite spec (because it does not include the
"SecurityPkg/Tcg/MemoryOverwriteControl/TcgMor.inf" driver), but appears
to support MORL from the dependent Microsoft spec.

"winload.efi" notices this inconsistency, and disables the Device Guard
Virtualization Based Security in Windows Server 2016 and Windows 10 64-bit
Enterprise.

If the platform includes
"SecurityPkg/Tcg/MemoryOverwriteControl/TcgMor.inf", then MOR will exist
by the time EndOfDxe is reached, and VariableSmm can safely create MORL.
Otherwise, do not create MORL (delete it if it exists), and also prevent
other modules from creating it.

Cc: Eric Dong <eric.dong@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Ladi Prosek <lprosek@redhat.com>
Cc: Star Zeng <star.zeng@intel.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=727
Ref: https://bugzilla.redhat.com/show_bug.cgi?id=1496170
Reported-by: Ladi Prosek <lprosek@redhat.com>
Suggested-by: Jiewen Yao <jiewen.yao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Tested-by: Ladi Prosek <lprosek@redhat.com>
2017-10-10 11:25:26 +02:00
..
Measurement.c MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
PrivilegePolymorphic.h MdeModulePkg/Variable/RuntimeDxe: introduce MorLockInitAtEndOfDxe() hook 2017-10-10 11:25:21 +02:00
Reclaim.c
TcgMorLockDxe.c MdeModulePkg/Variable/RuntimeDxe: introduce MorLockInitAtEndOfDxe() hook 2017-10-10 11:25:21 +02:00
TcgMorLockSmm.c MdeModulePkg/Variable/RuntimeDxe: delay MorLock creation until EndOfDxe 2017-10-10 11:25:26 +02:00
VarCheck.c
Variable.c MdeModulePkg/Variable/RuntimeDxe: move MOR func. declarations to header 2017-10-10 11:25:19 +02:00
Variable.h MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
VariableDxe.c MdeModulePkg/Variable/RuntimeDxe: introduce MorLockInitAtEndOfDxe() hook 2017-10-10 11:25:21 +02:00
VariableExLib.c
VariableRuntimeDxe.inf MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
VariableRuntimeDxe.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
VariableRuntimeDxeExtra.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
VariableSmm.c MdeModulePkg/Variable/RuntimeDxe: introduce MorLockInitAtEndOfDxe() hook 2017-10-10 11:25:21 +02:00
VariableSmm.inf MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
VariableSmm.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
VariableSmmExtra.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
VariableSmmRuntimeDxe.c MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
VariableSmmRuntimeDxe.inf MdeModulePkg/Variable/RuntimeDxe: move SecureBootHook() decl to new header 2017-10-10 11:25:04 +02:00
VariableSmmRuntimeDxe.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
VariableSmmRuntimeDxeExtra.uni MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00