Merge pull request #5829 from MicrosoftDocs/repo_sync_working_branch

Confirm merge from repo_sync_working_branch to master to sync with https://github.com/MicrosoftDocs/windows-itpro-docs (branch public)
This commit is contained in:
Jeff Borsecnik 2021-10-13 12:05:22 -07:00 committed by GitHub
commit bda989e212
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,6 +22,7 @@ ms.reviewer:
- Windows 11 - Windows 11
- Windows Server 2016 - Windows Server 2016
- Windows Server 2019 - Windows Server 2019
- Windows Server 2022
```powershell ```powershell
# Script to find out if a machine is Device Guard compliant. # Script to find out if a machine is Device Guard compliant.
@ -780,7 +781,7 @@ function CheckOSSKU
function CheckOSArchitecture function CheckOSArchitecture
{ {
$OSArch = $(gwmi win32_operatingsystem).OSArchitecture.ToLower() $OSArch = $(Get-WmiObject win32_operatingsystem).OSArchitecture.ToLower()
Log $OSArch Log $OSArch
if($OSArch -match ("^64\-?\s?bit")) if($OSArch -match ("^64\-?\s?bit"))
{ {
@ -818,9 +819,9 @@ function CheckSecureBootState
function CheckVirtualization function CheckVirtualization
{ {
$_vmmExtension = $(gwmi -Class Win32_processor).VMMonitorModeExtensions $_vmmExtension = $(Get-WMIObject -Class Win32_processor).VMMonitorModeExtensions
$_vmFirmwareExtension = $(gwmi -Class Win32_processor).VirtualizationFirmwareEnabled $_vmFirmwareExtension = $(Get-WMIObject -Class Win32_processor).VirtualizationFirmwareEnabled
$_vmHyperVPresent = (gcim -Class Win32_ComputerSystem).HypervisorPresent $_vmHyperVPresent = (Get-CimInstance -Class Win32_ComputerSystem).HypervisorPresent
Log "VMMonitorModeExtensions $_vmmExtension" Log "VMMonitorModeExtensions $_vmmExtension"
Log "VirtualizationFirmwareEnabled $_vmFirmwareExtension" Log "VirtualizationFirmwareEnabled $_vmFirmwareExtension"
Log "HyperVisorPresent $_vmHyperVPresent" Log "HyperVisorPresent $_vmHyperVPresent"
@ -1046,7 +1047,7 @@ if(!$TestForAdmin)
exit exit
} }
$isRunningOnVM = (get-wmiobject win32_computersystem).model $isRunningOnVM = (Get-WmiObject win32_computersystem).model
if($isRunningOnVM.Contains("Virtual")) if($isRunningOnVM.Contains("Virtual"))
{ {
LogAndConsoleWarning "Running on a Virtual Machine. DG/CG is supported only if both guest VM and host machine are running with Windows 10, version 1703 or later with English localization." LogAndConsoleWarning "Running on a Virtual Machine. DG/CG is supported only if both guest VM and host machine are running with Windows 10, version 1703 or later with English localization."