<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="https://www.w3.org/2005/Atom" xmlns:sy="https://purl.org/rss/1.0/modules/syndication/" xmlns:dc="https://purl.org/dc/elements/1.1/" xmlns:content="https://purl.org/rss/1.0/modules/content/" xmlns:wfw="https://wellformedweb.org/CommentAPI/" xmlns:slash="https://purl.org/rss/1.0/modules/slash/"
  version="2.0">
  <channel>
    <title>Datacenter and Private Cloud Security Blog</title>
    <atom:link
      href="https://docs.microsoft.com/archive/blogs/datacentersecurity/feed.xml"
      rel="self"
      type="application/rss+xml" />
    <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/feed.xml</link>
    <description>News and technical content around Windows Server Security and other Datacenter and Private Cloud Security technologies</description>
    <lastBuildDate>Fri, 14 Dec 2018 19:30:27 GMT</lastBuildDate>
    <language>en-US</language>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <item>
      <title>What is new in Windows 10 1803 for PAW?</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/what-is-new-in-windows-10-1803-for-paw</link>
      <pubDate>Fri, 08 Jun 2018 02:20:50 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1755</guid>
      <description><![CDATA[In this blog post, I’ll walk you through the new features which are relevant to the PAW solution in...]]></description>
      <content:encoded><![CDATA[In this blog post, I’ll walk you through the new features which are relevant to the <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/10/13/privileged-access-workstationpaw/">PAW solution</a> in the latest Windows 10 1803 release.
<h1>Offline HGS</h1>
Prior to 1803 release, to start a shielded VM, the host must connect to the HGS server in order to perform health attestation. One of the top customer feedback is that, PAW devices are sometimes in an offline mode, which means it does not have access to any network, or unable to connect to the HGS server, yet it is important to support the user to access the shielded VM at any time. We introduced the Offline HGS feature in the 1803 release to support this scenario. At high level, if the host health has not changed, shielded VM can start without connecting to the HGS server. That is, when the PAW device is unable to connect to the HGS server, as long as the device health matches previously attested state, it can used a copy of the cached key protector to unlock the shielded VM. The device must connect to the HGS server first to attest its health state before it can function at offline state. You can find the details on how to configure it <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-manage-branch-office#offline-mode">here</a>.
<h1>Lock PAW VM to the device</h1>
A shielded VM can start on a host device after the device can attest its health to the correct HGS server. To further secure the VM, ensure only the owner of the VM can start it, we added a policy to lock the shielded VM on the device where it is created. This is a policy controlled by the administrator, the setting is stored in the shielding data file, and it will be enforced at the shielded VM creation time.
<pre>New-ShieldingDataFile [-ShieldingDataFilePath] &lt;string&gt; [-Owner] &lt;Guardian&gt; [-VolumeIDQualifier]<span> </span>&lt;VolumeIDQualifier[]&gt; [-AnswerFile] &lt;NamedFileContent&gt; [[-OtherFile] &lt;NamedFileContent[]&gt;] [[-Guardian] &lt;Guardian[]&gt;] [-Policy {Shielded | EncryptionSupported}]  <strong>[-</strong><strong>BindToHostTpm</strong><strong> &lt;bool&gt;</strong>] [-WhatIf] [-Confirm]  [&lt;CommonParameters&gt;]<span> </span></pre>
By setting the BindToHostTpm to true, the shielded VM will only start on the device where it is created. This is to prevent a case where an insider tries to steal a shielded VM and attempts to get it started on a different PAW device. This feature will also prevent shielded VM to migrate to another device. For the PAW scenario, you would want to ensure the data is not only stored locally, but also backed up or synced to the backend servers. In case of a hardware device failure, a new shielded VM can be provisioned and data can be restored.
<h1>VMConnect to shielded VM</h1>
VMConnect was previously blocked to connect to the shielded VM. In the PAW scenario, the user owns both device and the shielded VM, using VMConnect is another top request. After extensive security review, we enabled the support of VMConnect to shielded VM without lower the security assurance.
<h1>Get VM EKpub from the device host</h1>
Shielded VM has vTPM, which has the same characteristics of a physical TPM including the presence of EKpub. EKpub is used by in various attestation methods such as <a href="https://docs.microsoft.com/en-us/windows-server/identity/ad-ds/manage/component-updates/tpm-key-attestation">TPM key attestation</a>. In the physical TPM scenario, the TPM EKpub is retrieved through a different channel and compared with the value from the device, this is to ensure the device TPM has not been tampered with and used as an immutable ID. For the shielded VM case, we added a channel to retrieve its EKPub from the host, the value can be compared with the EKPub retrieved from inside the VM to ensure its integrity and identity. The VM EKpub information is stored in the eventlog channel “Microsoft-Windows-Hyper-V-Worker-Analytic”, with Event ID 1500.  The event gets generated every time the shielded VM powered on.
<h1>Conclusion</h1>
As we continue to make the solution better, we welcome your feedback. In my next blog post, I’ll share the new networking capabilities in the insider release.]]></content:encoded>
    </item>
    <item>
      <title>PAW deployment guide</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/paw-deployment-guide</link>
      <pubDate>Mon, 30 Apr 2018 15:32:05 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1635</guid>
      <description><![CDATA[After running the PAW TAP program on the solution explained in this blogpost, I received tons of...]]></description>
      <content:encoded><![CDATA[After running the PAW TAP program on the solution explained in this <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/10/13/privileged-access-workstationpaw/">blogpost</a>, I received tons of interests and great feedback. While the team is investigating on a plan, a lot of customers are asking how they can deploy PAW in their datacenter. This blogpost is dedicated on this topic.

To put the solution into perspective, PAW is just one piece to the privileged account protection puzzle, important but there are a lot more to consider. Microsoft has published a <a href="https://docs.microsoft.com/en-us/windows-server/identity/securing-privileged-access/securing-privileged-access">whitepaper</a> which provides a much more comprehensive view. Even on the PAW topic, the <a href="https://docs.microsoft.com/en-us/windows-server/identity/securing-privileged-access/privileged-access-workstations">whitepaper</a> covers more aspects than this blogpost, such as creating different management tiers for your assets to reduce risk. This blogpost only focusses on one aspect, which is the PAW deployment, including the backend servers. I highly recommend you get familiar with the strategy explained in the whitepaper first before planning for PAW deployment.
<h1>Solution overview</h1>
There a few different options to deploy PAW, in this blogpost, I’ll focus on the solution which was evaluated in the PAW TAP program. The general feedback was positive, and customer liked the singled device configuration.

The solution leverages the shielded VM built in Windows 10 1709 to run secure workload, it includes the client configuration (end user device) and server backend. Here is a simplified topology overview:

<a href="https://msdnshared.blob.core.windows.net/media/2018/04/PAWDeployment-overview.jpg"><img width="740" height="150" class="alignnone wp-image-1645" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/PAWDeployment-overview.jpg" /></a>

A common misconception about PAW is “the device which the admin connects to, to get to the backend server  (PAW?)”; in fact, PAW is the device which admin uses with physical keyboard and mouse.  Consider the following diagram, PAW is commonly considered to be the device in the middle:

<a href="https://msdnshared.blob.core.windows.net/media/2018/04/PAW-misconception1.jpg"><img width="495" height="76" class="alignnone wp-image-1735" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/PAW-misconception1.jpg" /></a>

In this example, PAW refers to the User device , because you are using the keyboard/mouse on this device. If this device is compromised, attacker can get easily get the information to breach the datacenter.
<h1>Infrastructure deployment</h1>
When we designed the solution, one criteria is to fit it into the existing deployment. If you are familiar with the <a href="https://docs.microsoft.com/en-us/windows-server/identity/securing-privileged-access/securing-privileged-access-reference-material#ESAE_BM">EASE</a>, this is the model we tested to with the solution.

At a high-level, you will deploy a Host Guardian Server (HGS) in the environment. HGS is designed to run in its own forest, you can find details of the HGS deployment <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-install-hgs-default">here</a>.

<a href="https://msdnshared.blob.core.windows.net/media/2018/04/PAW-topology.jpg"><img width="615" height="137" class="alignnone wp-image-1665" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/PAW-topology.jpg" /></a>

In addition to HGS, PAW devices need to be managed. There are two common choices: leverage Azure (AAD and Intune) ; or using domain management. Furthermore, with on-prem deployment, a common question is about which domain should the PAW device joining to? Let’s start with identify the computer entities: physical PAW device, a desktop VM and one or more PAW VMs. The example here again using ESAE model as the example:
<ul>
 	<li>PAW physical device should be joined to the bastion forest. The risk for placing PAW in the production domain is the exposure to attack. I’ve seen breach to the SCCM server in production environment which leads to compromise of all the PAW devices when PAWs are managed by it. To reduce this risk, consider creating a separate PAW domain or if your company is open to cloud, PAW physical devices can also be AAD managed. We might create ESAE/PAW offering leverage AAD in the future;</li>
 	<li>PAW VM is dedicated to manage a certain datacenter assets, it should be placed in the same secure bastion forest as the host;</li>
 	<li>The desktop VM should be managed like all other user desktop machines, which joins to the production domain.</li>
</ul>
A few other infrastructure services are necessary for PAW but not dedicated for PAW:
<ul>
 	<li>WDS: service to image the PAW devices</li>
 	<li>SCCM: manage/configure PAW devices</li>
 	<li>Monitoring service</li>
 	<li>VPN server</li>
 	<li>WSUS for patch management</li>
</ul>
Some services Azure offers alternative to, such as <a href="https://www.microsoft.com/en-us/WindowsForBusiness/windows-atp">ATP</a> which can do better security monitoring using a large database tracking many attack signatures.

Another important aspect to consider is the “Break glass” scenario. This is not particular to the PAW deployment. As with any process, if you require all the admins to use PAW, if the PAW device breaks, how would the admin work? Can they physically access the backend servers? Or are there backup devices? This should be considered as part of PAW deployment plan.
<h1>PAW device configuration</h1>
From end user perspective, the solution looks like:

<a href="https://msdnshared.blob.core.windows.net/media/2018/04/PA-client.jpg"><img width="381" height="179" class="alignnone wp-image-1695" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/PA-client.jpg" /></a>

A single device with multiple VMs running on it, with the following software/hardware requirements:
<ul>
 	<li>License: To create shielded VMs, you need to enable “Guarded host” feature in Windows optional components. It is available on Windows client Enterprise edition and an E5 license.</li>
 	<li>The device must have TPM2.0, running UEFI with secure boot enabled.</li>
 	<li>Recommending memory 16GB or above; hard disk is 500GB and above to support multiple VMs.</li>
</ul>
<h2>Storage</h2>
For the PAW device, I separated the partitions for the host OS and the VM VHDs. This way, if the host needs to be rebuilt, the VM information stays. In the past, you need to remember suspend BitLocker of the data drive if it’s host OS is being re-installed, and re-enable it afterwards; the latest release has better Bitlocker support where you don’t need to suspend. But of course, you should ensure there is a Bitlocker recovery plan in place. See <a href="https://docs.microsoft.com/en-us/windows/security/information-protection/bitlocker/bitlocker-management-for-enterprises">here</a> for more options on Bitlocker management.

The storage is partitioned as the following:

<a href="https://msdnshared.blob.core.windows.net/media/2018/04/PAWstorage.jpg"><img width="474" height="94" class="alignnone wp-image-1705" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/PAWstorage.jpg" /></a>

In my testing, I assigned 60GB to the host OS volume, and use the rest of the disk for the data volume. You can adjust the size depending on if you need to store certain data on the host OS. Given the workloads are moved to the VMs, ideally there is little workload and data to be stored on the host OS, so the volume size should be configured for just running the OS. In general, you will need to reserve some space for Windows update on the host OS.

&nbsp;
<h2>Network</h2>
In the Windows 10 1709 release, there is a new type of VM switch “default switch” when Hyper-V is enabled. It allows virtual machines to share the host’s network connection.  Without getting too deep into networking, this switch enables the VMs access to the host’s network whether you’re connected to WIFI, or Ethernet. It’s not manageable through the Hyper-V manager app. You  can download the cmdlet module <a href="https://github.com/Microsoft/SDN/blob/master/Kubernetes/windows/hns.psm1">here</a> to create additional VM INS switches.

To lockdown the network access through Edge, 1709 release also introduced Application Guard, you can take advantage of it to control the access. There is another option to do network-whitelisting through a proxy server, that’s how we do it in Microsoft. I think each has its own advantages. Proxy server network whitelisting is more mature, and there are several software vendors offering the solution, so I’m not going to go into the details here. I’ll focus on the configuration leveraging the Windows Defender Application Guard (<a href="https://docs.microsoft.com/en-us/windows/security/threat-protection/windows-defender-application-guard/wd-app-guard-overview">WDAG</a>).

You can use group policy settings to configure WDAG, in my testing, I’ve configured the following settings on the host:
<ul>
 	<li>Enable WDAG (Computer configuration\Administrative Templates\Windows Components\Windows Defender Application guard)</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2018/04/WDAG.png"><img width="786" height="172" class="alignnone wp-image-1715" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/WDAG.png" /></a>

The configuration for these settings are straightforward, you can simply enable the policies. This will configure the policy on the default switch, to allow/block traffic appropriately.
<ul>
 	<li>Configure network isolation policy (Computer configuration\Administrative Templates\Network\Network Isolation)</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2018/04/NetworkIso.jpg"><img width="765" height="207" class="alignnone wp-image-1725" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/04/NetworkIso.jpg" /></a>

The highlighted policy is the setting you can whitelist Urls. You can find more reference on how to configure the policy <a href="https://docs.microsoft.com/en-us/windows/client-management/mdm/policy-csp-networkisolation">here</a>. On my PAW device, I configured the following value for this policy: <em>pawhgs.xxx.microsoft.com</em> (this is the Url for the HGS server which the PAW devices attest to). If user tries to connect to any other Urls, it will be launched through WDAG.

Another common question is on VPN. When the host is required to connect through VPN, how can the desktop VM be configured to not use the host VPN? You can configure the host with a registry key to prevent the VM using the host VPN.
<ul>
 	<li>Path: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\hns\Parameters</li>
 	<li>Name: ICSFlags</li>
 	<li>Type: DWORD</li>
 	<li>Value: 1</li>
</ul>
Note: Reboot the machine after the change.

Also, this VPN behavior will be improved in the future release.
<h2>VM management</h2>
In general, there should be little VM management which the end user needs to do. Majority of the work is for the IT admins who provisions the PAW devices, which includes creating the VMs. Currently, the VM management is supported through PowerShell. Inbox Hyper-V module can do almost all the VM management, shielded VM provisioning scenario is supported by the <a href="https://www.powershellgallery.com/packages/GuardedFabricTools/1.0.0">GuardedFabricTools</a> our team released in the Gallery.
<h2>Host user start menu customization</h2>
You can use group policy to change the start menu layout on the PAW device. Here is an example I created to show only Edge in the start menu:
<pre><em>&lt;LayoutModificationTemplate xmlns:defaultlayout="https://schemas.microsoft.com/Start/2014/FullDefaultLayout" xmlns:start="https://schemas.microsoft.com/Start/2014/StartLayout" Version="1" xmlns="https://schemas.microsoft.com/Start/2014/LayoutModification"&gt;</em>
<em>  &lt;LayoutOptions StartTileGroupCellWidth="6" /&gt;</em>
<em>  &lt;DefaultLayoutOverride&gt;</em>
<em>    &lt;StartLayoutCollection&gt;</em>
<em>      &lt;defaultlayout:StartLayout GroupCellWidth="6"&gt;</em>
<em>        &lt;start:Group Name="PAW"&gt;</em>
<em>          &lt;start:Tile </em><em>AppUserModelID="Microsoft.MicrosoftEdge_8wekyb3d8bbwe!MicrosoftEdge" </em>
         <em>  Size="2x2" </em>
         <em>  Column="0" </em>
         <em>  Row="0"/&gt;</em>
       <em>   &lt;start:DesktopApplicationTile </em><em>DesktopApplicationLinkPath="D:\PawFiles\bin\StartProgram\VMManager.lnk"</em>
         <em>  Size="2x2" </em>
         <em>  Column="2" </em>
         <em>  Row="0"/&gt;</em>
<i>          &lt;start:DesktopApplicationTile </i><em>DesktopApplicationID="{1AC14E77-02E7-4E5D-B744-2EB1AE5198B7}\WindowsPowerShell\v1.0\powershell.exe"</em>
         <em>  Size="2x2" </em>
         <em>  Column="4" </em>
         <em>  Row="0"/&gt;</em>
<i> </i><i>        &lt;/start:Group&gt;</i>
<em>      &lt;/defaultlayout:StartLayout&gt;</em>
<em>    &lt;/StartLayoutCollection&gt;</em>
<em>  &lt;/DefaultLayoutOverride&gt;</em>
<em>&lt;/LayoutModificationTemplate&gt;</em></pre>
You can save the content above to an xml file (startmenu.xml), and use group policy to apply it:

<strong>Computer Configuration</strong> &gt; <strong>Administrative Templates</strong> &gt;<strong>Start Menu and Taskbar</strong>

Enable the Start Layout policy and specify the startmenu.xml file full path. Check the <a href="https://docs.microsoft.com/en-us/windows/configuration/customize-windows-10-start-screens-by-using-group-policy">docs</a> for more details.

After VMs provisioned, you can also add additional RDP connection to the start menu, so user can easily launch them. For details on how to create more short cuts in the start menu, see <a href="https://docs.microsoft.com/en-us/windows/configuration/start-layout-xml-desktop">here</a>.
<h2>Image rollout</h2>
Windows 10 has a number of security features which can better protect the operating system. I wrote a separate blog <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/10/17/paw-host-buildout/">post</a> on how to enable them. The question I often get is “how should I deploy the device?” Again, there are a couple of options, both approach should follow the <a href="https://docs.microsoft.com/en-us/windows-server/identity/securing-privileged-access/securing-privileged-access-reference-material#CSP_BM">clean source principle</a>:
<ul>
 	<li>Windows Deployment Server (WDS): you can first build the host OS iso image using <a href="https://www.microsoft.com/en-us/download/details.aspx?id=54259">MDT</a> (Microsoft deployment toolkit), then using the WDS to enable device to install the image;</li>
 	<li>USB boot: if the deployment is small, in my test environment, I created USB boot key with the ISO image created by MDT, and manually installed the PAW devices.</li>
</ul>
Note that, to comply with the clean source principle, you should ensure using the separate deployment infrastructure from the existing one used for production. This is to ensure a higher trust level for PAW.

I think it’s also possible to do all the configuration through Intune, but I’m not the expert on Intune, I’m still looking for help to get all the CSPs created to customize the host. It will be a more scalable approach for future.
<h2>VM provisioning</h2>
You will need shielded VM templates to provision the PAW VMs. Template creation is a separate topic covered <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/01/how-to-create-a-vm-template-for-paw/">here</a>, and I also shared an <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/30/building-vm-template-using-assigned-access/">example</a> of creating PAW VMs with Kiosk experience.

Once you have created the templates, you can store it centrally, and download it to the PAW device for PAW VM provisioning.

Desktop VM images are regular VHDs, you can simply download it locally to the device and create the VM from it. A common question is whether the desktop VM should be shielded; in my view, it should be managed in a similar secure level as other desktops in the environment. Host device has Bitlocker enabled, which also protects the desktop VM as a regular desktop. Shielding desktop VM will provide another layer of protection to prevent physical access to the device, and copying the desktop VM to another machine. If you do want to shield the desktop VM, one key scenario is to allow user to start the desktop VM while the device is offline. This is a new feature added in the 0418 release.
<h2>Logon and Connect</h2>
In the previous Infrastructure deployment section, we looked at how each machine entity is managed by the backend, let’s take a look how user will connect to them here:
<table width="844" border="1">
<tbody>
<tr>
<td width="132"></td>
<td width="150">Physical host</td>
<td width="168">Desktop VM</td>
<td width="174">PAW VM</td>
</tr>
<tr>
<td width="132">Logon user identity</td>
<td width="150">ESAE domain user</td>
<td width="168">Production domain user</td>
<td width="174">Privileged account for backend management</td>
</tr>
<tr>
<td width="132">Logon method</td>
<td width="150">
<ul>
 	<li>Windows Hello for business</li>
 	<li>Smartcard</li>
</ul>
</td>
<td width="168">Smartcard</td>
<td width="174">Smartcard

(Note: Hello for business is not supported for VMs today)</td>
</tr>
<tr>
<td width="132">Connect</td>
<td width="150">
<ul>
 	<li>Interactive logon</li>
 	<li>RDP is disabled</li>
</ul>
</td>
<td width="168">VMConnect or Mstsc</td>
<td width="174"><a href="https://blogs.technet.microsoft.com/datacentersecurity/2018/04/12/connect-to-virtual-machines-vms-on-paw/">RDP over VMBus</a></td>
</tr>
</tbody>
</table>
Old fashion user name/password still works for all the connections, but they are less secure comparing to smartcard or Windows Hello for business.
<h1>Conclusion</h1>
Usually with deployment guide, I’d provide detailed step-by-step instructions. I’m trying a different approach to cover more on planning considerations and referencing to other docs for the detailed instructions. It is such a large topic, I’m sure there are aspects which didn’t get covered, as always, feel free to post your questions/comments below or to us]]></content:encoded>
    </item>
    <item>
      <title>Apply Code Integrity Policy without reboot</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/apply-code-integrity-policy-without-reboot</link>
      <pubDate>Fri, 27 Apr 2018 13:29:47 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1625</guid>
      <description><![CDATA[There is a new Code Integrity policy option introduced in Windows 10, and it is available in Windows...]]></description>
      <content:encoded><![CDATA[<span style="font-family: Calibri"><span style="color: #000000">There is a new Code Integrity policy option introduced in Windows 10, and it is available in Windows Server 2019 insider build “</span><a href="https://docs.microsoft.com/en-us/windows/security/threat-protection/windows-defender-application-control/select-types-of-rules-to-create">Update Policy No Reboot</a></span><span style="color: #000000;font-family: Calibri">”. I got numerous questions around how to use this option, and here is the blogpost to answer it. </span>
<h1><span style="color: #2f5496;font-family: Calibri Light;font-size: x-large">What is this option?</span></h1>
<span style="color: #000000;font-family: Calibri">After the Windows Server 2016 release, we talked to many customers about using Code Integrity (CI) policy to secure the servers. One main feedback from server customers is, it requires a reboot when I need to make a change in the policy. This option allows you apply a new CI policy without reboot. </span>

<span style="color: #000000;font-family: Calibri">This option can used for both signed and unsigned CI policy. For unsigned CI policy, any running executables; already loaded dlls or running PowerShell session will not be stopped, new policy will be applied to new PowerShell sessions, reloading dlls or executables. For signed CI policy, one additional check is in the pre-boot environment with UEFI validation, and this check won’t take effect till the machine reboot. </span>

<span style="font-family: Calibri"><span style="color: #000000">This option is not recommended on the </span><a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-and-shielded-vms">Guarded Fabric</a></span><span style="color: #000000;font-family: Calibri"> deployment. As part of the host attestation, measured boot log and CI policy are checked against the HGS server, it ensures the guarded host is running the same copy of the CI policy as admin defined on the HGS server. If the guarded host is running the CI policy allow “no reboot”, it breaks the guarded host security promise. </span>
<h1><span style="color: #2f5496;font-family: Calibri Light;font-size: x-large">How to apply it?</span></h1>
<span style="color: #000000;font-family: Calibri">Let’s use an example to illustrate the process.</span>

<span style="color: #000000;font-family: Calibri">I have s server which is governed by a CI policy (CI.old), in this policy, it has the option enabled:</span>
<pre><span style="font-family: Calibri"><span style="color: #000000"><span> </span>&lt;Rule&gt;</span></span>
<span style="font-family: Calibri"><span style="color: #000000"><span>      </span>&lt;Option&gt;Enabled:Update Policy No Reboot&lt;/Option&gt;</span></span>
<span style="color: #000000;font-family: Calibri">&lt;/Rule&gt;</span></pre>
<span style="color: #000000;font-family: Calibri">Now I have a new policy I’d like to apply, I convert it to the binary format using Convertfrom-CIpolicy, and run the following cmd to apply the new policy:</span>
<pre><span style="margin: 0px;color: black;line-height: 107%;font-family: 'Segoe UI',sans-serif;font-size: 10pt">Invoke-CimMethod -Namespace root/microsoft/Windows/CI -ClassName PS_UpdateAndCompareCIPolicy -MethodName Update -Arguments @{ FilePath = 'C:\sipolicy.p7b' }</span></pre>
<span style="color: #000000;font-family: Calibri">In short, to apply CI policy without reboot, you need to ensure the existing policy has the option enabled, and run the cmdlet to apply the new policy.</span>

<span style="color: #000000;font-family: Calibri">Note: this cmdlet for applying new CI policy may change in the new release of Windows (post 1804 release)</span><span style="color: #000000;font-family: Calibri"> </span>

<span style="color: #000000;font-family: Calibri"> </span>]]></content:encoded>
    </item>
    <item>
      <title>Connect to Virtual Machines (VMs) on PAW</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/connect-to-virtual-machines-vms-on-paw</link>
      <pubDate>Thu, 12 Apr 2018 16:26:47 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1585</guid>
      <description><![CDATA[Continuing the PAW series, this blog post discusses the options to connect to the VMs running on the...]]></description>
      <content:encoded><![CDATA[Continuing the PAW <a href="https://blogs.technet.microsoft.com/datacentersecurity/category/secure-privileged-access/">series</a>, this blog post discusses the options to connect to the VMs running on the PAW device.

In Windows, you can connect to a locally running VM using:
<ul>
 	<li>VMConnect (basic mode or enhanced mode)</li>
 	<li>RDP using mstsc.exe (classic RDP client)</li>
 	<li>RDP using the Remote Desktop app from Store (modern RDP client)</li>
 	<li>RDP over VMBus (this is done by creating a special RDP file, shown later in the doc)</li>
</ul>
In addition, it’s quite straightforward to develop a customized RDP app using the inbox<a href="https://msdn.microsoft.com/en-us/library/aa383541(v=vs.85).aspx"> RDP ActiveX control</a>. Elena (our intern) wrote a RDP app for VM connection last summer, which is part of the PAW management app she developed. Hence, if none of the inbox apps meets your requirement, this might be a good approach.

Modern RDP client has a very nice clean UI, but it is still being actively developed. As of the latest release, it does not support pass through devices yet, so I don’t recommend it for VM connection on PAW. It is however a good choice for RDP to servers (i.e. server management) from the PAW VM.

VMConnect (basic mode) allows you to see OS boot phase, i.e. you can see the screen outputs even before the VM starts, whereas RDP (and VMConnect enhanced mode) can only display after the Remote Desktop service starts in the VM. If you need to enter BitLocker key for example, you can only do so using VMConnect basic mode.

VMConnect (enhanced mode) and RDP are built on top of the same RDP protocol, so they share similar features. For example, you can pass through smart card to the VM using either VMConnect (enhanced mode) or RDP (note, ensure the right card reader driver is installed in the VM). However, there are two main differences between VMConnect (enhanced mode) and RDP:
<table width="831" border="1">
<tbody>
<tr>
<td width="144"></td>
<td width="228">VMConnect (enhanced mode)</td>
<td width="252">RDP</td>
</tr>
<tr>
<td width="144">Transport</td>
<td width="228">VMBus, which doesn’t require any network ports to be opened</td>
<td width="252">Requires open RDP firewall port to allow it</td>
</tr>
<tr>
<td width="144">User permission</td>
<td width="228">Hyper-V admin on the host</td>
<td width="252">Standard user on the host; user must be in the Remote desktop user group in the VM</td>
</tr>
</tbody>
</table>
In addition, there are advantages of using RDP as it has more functionalities over VMConnect, to name a couple:
<ol>
 	<li>Select a subset monitors for VM connection (for example, use 2 out of the 3 monitors connected to the device)</li>
 	<li>Video device pass through</li>
</ol>
Using RDP client or VMConnect are pretty straightforward, I won’t go into details on those. There is another approach which allows to get the benefit of RDP, as well as using the VMBus, so you don’t need to open RDP ports on the VM, we call it "RDP over VMBus".
<h1>RDP over VMBus</h1>
This is done by creating an RDP file with the following configuration:

<em>pcb:s:11111111-1111-1111-1111-111111111111;EnhancedMode=1</em>

<em>full address:s:localhost</em>

<em>server port:i:2179</em>

where 11111111-1111-1111-1111-111111111111 is the VM ID on the host.

The downside of using this connection is that user will need to log on the VM twice; the first time is for the user to logon the local host, and second logon is the VM itself. I’m trying to figure out if there is a way to skip the first logon, welcome your ideas.
<h1>RDP file sample</h1>
You can create RDP files by running mstsc, and click on "Show Options", after specify the configuration, click on "Save As" on the General page. To use RDP over VMBus, simply replace the setting for "Full address" and "Server port". <span style="margin: 0px;line-height: 107%;font-family: 'Calibri',sans-serif;font-size: 11pt"><span style="color: #000000">Below is the RDP file I used for my desktop VM as an example, you can find the setting references </span><a href="https://technet.microsoft.com/en-us/library/ff393699(v=ws.10).aspx">here</a><span style="color: #000000">.</span></span>

[snippet slug=rdp-file-sample line_numbers=false lang=bsh]

<span style="color: #000000;font-family: Calibri">If you would like to share desired user experience or report issues using PAW, feel free to reach us <a>here</a>.</span>]]></content:encoded>
    </item>
    <item>
      <title>Default Code Integrity policy for Windows Server</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/default-code-integrity-policy-for-windows-server</link>
      <pubDate>Sat, 10 Mar 2018 14:33:21 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1565</guid>
      <description><![CDATA[After Windows Defender Application Control (WDAC, formerly known as Code Integrity) was released in...]]></description>
      <content:encoded><![CDATA[After Windows Defender Application Control (WDAC, formerly known as Code Integrity) was released in Windows Server 2016, I wrote a <a href="https://blogs.technet.microsoft.com/datacentersecurity/2016/09/20/overview-of-device-guard-in-windows-server-2016/">blog post</a> on it, it was a very effective way to do application whitelisting, and get secure!

When engaging with customers to get their feedback and help deploy WDAC, the consistent feedback has been “it’s great, but it’s too hard to deploy it.” We listened, and created a few default policies, which balance the security and operational management effort.

Those policies are stored under “C:\Windows\schemas\CodeIntegrity\ExamplePolicies” on any Windows OS post 1709 release. I recommend two policies for Windows Server:

<strong>AllowMicrosoft</strong>: this CI policy allows all the files signed by Microsoft. If you are running Server applications such as SQL, Exchange, or the server is monitored by agents published by Microsoft, you should start with this policy.

<strong>DefaultWindows</strong>: this policy only allows the files which are shipped in Windows and doesn’t permit other applications released by Microsoft (such as Office). This is a good policy to use if the Server is dedicated for inbox server roles/features, such as Hyper-V.

There are known applications in Windows that might be used to bypass WDAC, the full list is published on this <a href="https://docs.microsoft.com/en-us/windows/security/threat-protection/device-guard/steps-to-deploy-windows-defender-application-control">page</a>. I recommend adding them to the deny list in the Code Integrity policy. Please note, the list is updated periodically with newly identified applications, you should review the list and add them to your CI policy if determined fit.

To make it easy for you, I created two copies of the default CI policies that you can download (the follow CI policy is designed for the next release of Windows Server, you can also modify it to remove the new policy rule options for Windows Server 2016:

<a href="https://download.microsoft.com/download/9/8/3/983C8CF3-1649-4574-A677-90C93B25F414/AllowMicrosoft_DenyByPassApps_Audit.xml">AllowMicrosoft_DenyBypassApps_Audit.xml</a>

<a href="https://download.microsoft.com/download/9/8/3/983C8CF3-1649-4574-A677-90C93B25F414/DefaultWindows_DenyByPassApps_Audit.xml">DefaultWindows_DenyBypassApps_Audit.xml</a>

One of the new rule options in the above policy file is “<a href="https://docs.microsoft.com/en-us/windows/security/threat-protection/device-guard/deploy-windows-defender-application-control-policy-rules-and-file-rules">Update policy no reboot</a>”. On generic servers, it’s often user needs to be add software, when do so, the CI policy might require a change to cover the application, this rule option allows the CI policy to be updated without machine reboot. This option is added post Windows Server 2016. If you want to use the policies on Windows server 2016, you will need to remove them.
<h1>Adding additional publishers</h1>
Most of the customers have their own applications developed internally or acquired externally to manage the servers, i.e. the above default policies are not enough. To allow these apps (or even drivers) to load, you will need to modify the CI policy to cover them. There are a couple of approaches:
<ol>
 	<li><strong>Adding publisher</strong>: If you want to trust all the applications created by the vendor, you can add their publisher to the CI policy. Run the following cmdlet to extract the publishers to an xml file:</li>
</ol>
<pre>New-CIPolicy -FilePath &lt;appCI.xml&gt; -Level Publisher -ScanPath &lt;the path which the app is installed&gt;  -UserPEs</pre>
<ol start="2">
 	<li><strong>Adding FilePublisher</strong>: If you want to only trust the installed application (not all the applications from this vendor), you can add FilePublisher to the CI policy to the CI policy. Run the following cmdlet to extract the file list and its publisher to an xml file:</li>
</ol>
<pre>New-CIPolicy -FilePath &lt;appCI.xml&gt; -Level FilePublisher -ScanPath &lt;the path which the app is installed&gt;  -UserPEs</pre>
You can mix and match different applications (from different vendors) with the two approaches described above.

For example, you have an active development team internally, you want to add your enterprise signer/publisher in the CI, so that all the enterprise signed applications can run in the environment; you can also enable a device driver by adding the FilePublisher rule for that driver.

For the same publisher, you need to choose between to trust the publisher or trust the FilePublisher. For example, if you contracted a vendor company to develop an application, and you decide to trust the vendor company by adding their publisher to the CI, later if you want to change to trust only that application, you should remove the vendor publisher from the CI first, then add the application FilePublisher rule.
<h2>Merge CI policies</h2>
With all the CI files generated to cover the additional file/publisher information, you will then merge them with the default CI policies by running:
<pre>Merge-CIPolicy -OutputFilePath ‘Serverdefault-audit.xml’ -PolicyPaths ‘.\AllowMicrosoft_DenyByPassApps_Audit’,’additionalCI1.xml’, ‘CI2.xml’</pre>
<h1>Deploy CI policy</h1>
CI deployment and ongoing monitoring is covered in this blog <a href="https://blogs.technet.microsoft.com/datacentersecurity/2016/09/20/overview-of-device-guard-in-windows-server-2016/">post</a>. You can also reference this <a href="https://docs.microsoft.com/en-us/windows/security/threat-protection/device-guard/steps-to-deploy-windows-defender-application-control">page</a> for group policy deployment. Below is a quick reference for your convenience:

The created CI policy is in audit mode, you can change it to enforced mode by running:
<pre>Set-RuleOptions -FilePath C:\CI\FilePublisher.xml -Option 3 -Delete</pre>
The XML file created by New-CIPolicy can’t be consumed by the system yet. To deploy the policy, it needs to be converted to binary format and copied to the CodeIntegrity folder under System32.

Run the following cmdlet to convert the xml file:
<pre>ConvertFrom-CIPolicy C:\CI\FilePublisher.xml C:\CI\FilePublisher.bin</pre>
Deploy CI policy:
<pre>Copy-Item C:\CI\FilePublisher.bin C:\Windows\System32\CodeIntegrity\SiPolicy.p7b</pre>
Reboot the server to allow code integrity service to load the policy.

&nbsp;

I hope the default server CI policies can help you to speed up the deployment, and as always, you can share your feedback by email with <a href="mailto:ShieldedVMFeedback@microsoft.com?subject=Default%20CI">us </a>or submit and vote on requests through the <a href="https://windowsserver.uservoice.com/forums/295065-security-and-assurance">User Voice</a>.
<h1></h1>]]></content:encoded>
    </item>
    <item>
      <title>Shielded VM local mode and HGS mode</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/shielded-vm-local-mode-and-hgs-mode</link>
      <pubDate>Fri, 05 Jan 2018 15:24:30 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1535</guid>
      <description><![CDATA[With the new capability in Windows 10, version 1709, Windows Client can host shielded VMs while...]]></description>
      <content:encoded><![CDATA[With the new capability in Windows 10, version 1709, Windows Client can host shielded VMs while using remote Host Guardian Service (HGS) attestation. This caused some confusion as people stated they have already been running shielded VMs on client. This blog post is intended to clarify things and explain how to run them side by side.

In Windows 10, when you create a VM, you can optionally attach a virtual TPM (vTPM) to it. It offers similar protection to the VM as a physical TPM does for the physical device. vTPM state is encrypted and the encryption key can be either stored locally (a.k.a. local mode) or stored remotely on a HGS server (a.k.a HGS mode).  There are several strong security measures in HGS mode such as validating boot measurements and code integrity policies. For more information on what HGS mode measures, check out my previous blog post on Privileged Access Workstations <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/29/why-use-shielded-vms-for-your-privileged-access-workstation-paw-solution/">here</a>.

The mode--local mode vs. HGS mode--is a configuration setting on the physical host so it knows where to get the key to unlock the vTPM. When the host is running in HGS mode, it will get the key from HGS server (assuming it qualifies as healthy); when the host is running in local mode, it will look for the key locally. Previously, Windows Client only supported local mode; HGS mode support was added in the Windows 10, version 1709 release.

When you start the shielded VM in HGS mode, the host must get the key from HGS. If the host is not connected to the network, the shielded VM won’t start. In local mode, the key is held locally so the VM can start anytime.

Using the example of a PAW’s configuration, it typically hosts one desktop VM and one PAW VM. The Desktop VM needs to run anytime, while the PAW VM should be protected by HGS. This can be done by setting the host to local mode when create and start the desktop VM and setting the host to HGS mode when create and start the PAW VM.

It’s quite simple to change the setting. To set the host to local mode:
<pre>Set-HGSClientConfiguration -EnableLocalMode</pre>
To change it to HGS mode:
<pre>Set-HGSClientConfiguration -AttestationServerUrl &lt;url&gt; -KeyProtectionServerUrl &lt;Url&gt;</pre>
If you are writing scripts, be sure to configure the host to the correct mode before creating or starting the shielded VM. Below is a sample script to create a shielded VM local mode:

<em>[snippet slug=new-shielded-vm-local-mode line_numbers=false lang=bsh]</em>

You can find the script to create remote mode shielded VM <a href="https://blogs.technet.microsoft.com/datacentersecurity/2016/06/06/step-by-step-creating-shielded-vms-without-vmm/">here</a>.

If you have VMs in both modes running side by side, be sure to set the host in the correct mode before create or start them. If the host is running in the wrong mode for the VM, the VM will not be able to start. You can easily correct it by setting the security policy again on the VM after you change the host mode.]]></content:encoded>
    </item>
    <item>
      <title>Building VM template using Assigned Access</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/building-vm-template-using-assigned-access</link>
      <pubDate>Thu, 30 Nov 2017 10:03:47 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1495</guid>
      <description><![CDATA[Since it took me a couple of attempts to create VM templates for Azure portal management and Remote...]]></description>
      <content:encoded><![CDATA[Since it took me a couple of attempts to create VM templates for Azure portal management and Remote Desktop (in order to make them available for the TAP evaluation), I thought it best to share the process, so you can build your own customized image.<span> </span>

My goal is to create a PAW VM that offers user a kiosk experience which is dedicated to one application. When user connects to the VM, it only shows the Azure portal page or the RDP application, nothing else. To create a kiosk experience, I used <a href="https://docs.microsoft.com/en-us/windows-hardware/customize/enterprise/configure-assigned-access-by-using-the-ui">Assigned Acces</a>s. There are a few ways to configure it. I chose the Windows Configuration Designer downloaded from the Windows Store. You can follow the instructions <a href="https://docs.microsoft.com/en-us/windows/configuration/set-up-a-kiosk-for-windows-10-for-desktop-editions">here</a> to create the package.
<h1>Creating provisioning package for Azure portal management</h1>
To build the Azure portal package, on the wizard page that defines the Kiosk account and app, select the App type: Classic Windows App, and the full path as <em>%</em><em>P</em><em>rogramfiles</em><em>%\</em><em>Internet explorer\iexplorer.exe -k portal.azure.com</em> (note: don’t use quotes around the string, it doesn’t work). To apply the package, simply copied the package inside the VM, which is the online approach below.
<h1>Creating provisioning package for RDP</h1>
There are two RDP apps for Windows: classic app (mstsc.exe) and Remote Desktop from store. I like the store version for its simple user experience, and choose it for the template. It turns out that I learnt quite a bit from building the package for it:
<ol>
 	<li>Store RDP app is not built-in, so I need to find the appx package to install it in the image. To save time, I used an internal copy. You can do this for any applications if it supports <a href="https://docs.microsoft.com/en-us/microsoft-store/distribute-offline-apps">offline distribution</a>. To install the Appx package:</li>
</ol>
<em>Dism </em><em>/add-provisionedAppxPackage /image:e:\ /PackagePath:&lt;path to .appxbundle&gt; /LicensePath:&lt;path to license xml&gt; /DependecyPackagePath:&lt;adding dependency appx if needed&gt;</em>

<em>Where e:\ is the mounted VHDX drive</em>
<ol start="2">
 	<li>However, when testing the image above by logon, the app is not there. Apparently, if the app is not pinned to the Start menu, it gets removed during the first user logon, so I added the app to the start menu in the unattend xml file. (For details, see the unattend file section)</li>
 	<li>Trying the same approach by applying the package online led me nowhere, that's how I learnt the offline approach, and it turns out to be a much simpler process. Because I simply modify the syspreped image without user logon, and I can skip sysprep later to make it a template.</li>
</ol>
<h1>Deploy package</h1>
As I have mentioned earlier, there are two ways to apply the (.ppkg) package:<span> </span>
<ol>
 	<li><strong>Online</strong>: copies the package file to the VM while it’s running and applied it by simply double-clicking the .ppkg file which applied automatically. After the VM reboots, you will see the kiosk mode experience which shows IE and only connects to the Azure portal page. <span></span></li>
</ol>
To turn this into a template, you can just sysprep the image. I did this by switching to a different user (local admin) where I ran sysprep. <span> </span>
<ol start="2">
 	<li><strong>Offline</strong>: If you already have a syspreped image to start with, you can apply the package to the image by running <span></span></li>
</ol>
<em>Dism</em><em> /add-</em><em>provisioningpackage</em><em> /</em><em>packagepath</em><em>:</em><em>&lt;full path to </em><em>ppkg</em><em> file&gt;</em><em> /image=e:\</em><span> </span>

<em>(where e:\ is the mounted VHDX</em><em> file)</em><span> </span>

Now the VM image can be used as the template and you can follow the previous <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/01/how-to-create-a-vm-template-for-paw/">blog post</a> to deploy it. If you are part of the TAP program, I have also made the image available for download. <span> </span>
<h1>Windows unattend file</h1>
To create PAW VM, you will need a Windows unattend file. I have shared a sample copy in a previous <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/01/how-to-create-a-vm-template-for-paw/">blog post</a>. For the RDP VM template, I added the following to pin the app in the start menu:

[snippet slug=unattend-pin-rdp-in-start-menu line_numbers=false lang=bsh]

If you have ideas/requests for different images, you are welcome to share it with <a href="mailto:pawfeedback@microsoft.com">us</a>.<span> </span>]]></content:encoded>
    </item>
    <item>
      <title>Why use shielded VMs for your privileged access workstation (PAW) solution?</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/why-use-shielded-vms-for-your-privileged-access-workstation-paw-solution</link>
      <pubDate>Wed, 29 Nov 2017 09:39:54 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1475</guid>
      <description><![CDATA[It’s great to see customers trying out PAWs and it’s generating a lot of great questions. Many...]]></description>
      <content:encoded><![CDATA[<span>It’s great to </span><span>see </span><span>customers trying out PAW</span><span>s</span><span> and </span><span>it’s generating a lot of great </span><span>questions</span><span>. </span><span>Many</span><span> questions are related to shielded VMs</span><span> so </span><span>I’d like to </span><span>focus</span><span> this blog post </span><span>on </span><span>shar</span><span>ing </span><span>our </span><span>reasoning for building the </span><span>PAW</span><span> solution on shielded VMs.</span>

<span>Running virtual machine</span><span>s </span><span>(VM</span><span>s</span><span>)</span><span> on Windows client is not new,</span> <span>but running </span><span>a </span><span>shielded VM on Windows client is</span><span>. The </span><span>ability to run shielded VMs on client wa</span><span>s</span> <span>introduced in </span><span>the </span><span>Windows 10 1709 release</span><span>. T</span><span>here are </span><span>many</span> <span>security considerations </span><span>built in to </span><span>shielded VM</span><span>s</span><span>, from </span><span>secure </span><span>provisioning to </span><span>protecting </span><span>data at rest. </span><span>As part of the PAW </span><span>solution</span><span>, </span><span>the privileged access workload </span><span>gains additional </span><span>security protections by running inside </span><span>a</span> <span>shielded VM</span><span>. </span><span> </span><span> </span>

<span>There are tons of documents/videos on </span><span>technet</span><span> about shielded VMs, </span><a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-and-shielded-vms-top-node"><span>this</span></a><span> is a good starting point. </span><span>Note that t</span><span>his blog post</span><span> is not intended to repeat the content, </span><span>but</span> <span>rather </span><span>focus on </span><span>it</span><span>s usage</span> <span>from the PAW perspective. </span><span> </span>

So why shielded VMs?

<span>There are two </span><span>aspects</span><span> to this question:</span><span> </span>
<ol>
 	<li><span>Why do we want to use VM</span><span>s?</span><span> (a</span><span>s oppose</span><span>d</span><span> to dedicated physical </span><span>PAW </span><span>devices </span><span>)?</span><span> </span></li>
</ol>
<ol>
 	<li><span>What </span><span>are the </span><span>security benefits </span><span>when </span><span>running a shielded VM</span><span> over a regular VM</span><span>?</span><span> </span></li>
</ol>
<span>The use of VMs </span><span>reduces the number of devices</span><span> per user. In most environment</span><span>s where PAW is deployed, </span><span>its </span><span>user </span><span>must </span><span>carr</span><span>y </span><span>at least 2 devices</span><span>; in some cases, </span><span>5</span><span> or more (</span><span>based on </span><span>customer feedback)</span><span>. </span><span>By u</span><span>sing </span><span>VMs</span><span>, </span><span>a </span><span>user can carry just one device </span><span>with </span><span>all the</span><span>ir</span><span> workloads </span><span>and the PAW itself </span><span>running in different </span><span>isolated VMs</span><span>.</span><span> </span><span> </span>

<span>Admin</span><span>s</span><span> also have an easier time manag</span><span>ing</span><span> the VM images as the images can be </span><span>more </span><span>tailored </span><span>to </span><span>a specific role. For example, the PAW VM used </span><span>by </span><span>Domain </span><span>A</span><span>dmin</span><span>s</span><span> to</span><span> manage </span><span>Active Directory </span><span>will </span><span>differ from the VM </span><span>image </span><span>that </span><span>SQL admin</span><span>s</span><span> use</span><span> allow</span><span>ing each</span><span> to be locked down</span> <span>in ways specific </span><span>to </span><span>its role</span><span>. If there is a need for new applications, admin</span><span>s</span><span> can easily create new VM images. </span><span> </span>

<span>Furthermore, </span><span>you can </span><span>harden the OS on</span><span> the physical machine </span><span>when </span><span>all </span><span>the workloads are moved to </span><span>VMs</span><span>. Using </span><span>application</span> <span>whitelisting (such as </span><span>a </span><span>code integrity policy), </span><span>the physical machine can be </span><span>further </span><span>locked down </span><span>allowing it </span><span>to run only </span><span>authorized </span><span>VMs</span><span>.</span><span> </span><span> </span>

<span>Let’s dive </span><span>into</span><span> the second question about the security benefit</span><span>s</span> <span>of </span><span>using shielded VM</span><span>s</span><span>.</span> <span>I</span><span>t starts with </span><span>enforc</span><span>ing </span><span>higher security </span><span>requirements </span><span>o</span><span>n</span><span> the physical </span><span>PAW itself </span><span>through remote health attestation</span><span>:</span><span> </span>
<ol>
 	<li><span>The physi</span><span>c</span><span>al</span><span> device must have TPM</span><span> version 2.0. </span><span>The </span><span>endorsement key </span><span>from the TPM </span><span>is </span><span>used as </span><span>a strong form of device iden</span><span>tity</span><span>;</span><span> </span><span> </span></li>
</ol>
<ol>
 	<li><span>The </span><span>TPM is also used in measure</span><span>d</span><span> boot to ensure </span><span>that </span><span>the security configuration and </span><span>the binaries loaded in the boot process match the </span><span>approved </span><span>(healthy) </span><span>baseline configuration;</span><span> </span></li>
</ol>
<ol>
 	<li><span>Finally, the code integrity policy is </span><span>also measured and </span><span>validated </span><span>against the policy </span><span>managed by the Host guardian serv</span><span>ice. </span><span> </span></li>
</ol>
<span>If the device itself </span><span>is</span><span> compromised, </span><span>any </span><span>changes to operating system binaries</span><span> or</span> <span>the </span><span>code integrity policy will </span><span>cause it to </span><span>fail attestation</span><span> and prevent VMs from running</span><span>.</span> <span>In short,</span><span> shielded VM </span><span>security starts </span><span>with </span><span>a clean</span><span>, trustworthy </span><span>host as illustrated below:</span><span> </span>

<span> <a href="https://msdnshared.blob.core.windows.net/media/2017/11/TPM-Trust.gif"><img width="642" height="286" class="alignnone wp-image-1485" alt="" src="https://msdnshared.blob.core.windows.net/media/2017/11/TPM-Trust.gif" /></a></span>

<span>In addition to the host remote health attestation, shielded VM</span><span>s</span> <span>use </span><span>a </span><span>virtual TPM</span><span> to </span><span>encrypt </span><span>data through </span><span>Bitlocker</span><span>. </span><span>If </span><span>the</span><span> physical device </span><span>is compromised, the </span><span>virtual disks </span><span>are encrypted and </span><span>the </span><span>attacker will </span><span>either </span><span>have to </span><span>find a way to </span><span>break BitLocker </span><span>encryption </span><span>or compromise the Host guardian serv</span><span>ice</span> <span>in the datacenter</span><span>;</span><span> neither is trivial.</span><span> </span>

<span>A typical process to </span><span>create a VM is to </span><span>simply </span><span>attach </span><span>a copy of </span><span>a </span><span>VHDX which contains the </span><span>appropriate </span><span>operati</span><span>ng</span><span> system</span><span>. I</span><span>n </span><span>a </span><span>production deployment, admin</span><span>s</span> <span>usually </span><span>create </span><span>syspreped</span><span> image</span><span>s</span><span> and distribute the image</span><span>s</span><span> through file share</span><span>s</span><span>. At deployment</span><span> time</span><span>, </span><span>however, </span><span>there is no </span><span>guarantee </span><span>that </span><span>the VHDX file the admin created</span><span> hasn’t been tampered with</span><span>. </span><span>Shielded VM</span><span>s</span><span> add security measure</span><span>s</span> <span>t</span><span>o </span><span>detect images that have been tampered with and </span><span>prevent </span><span>deployment. A</span><span>dmin</span><span>s</span><span> create a signature</span><span> (.</span><span>vsc</span><span> file</span><span>s</span><span>)</span> <span>for each </span><span>trustworthy </span><span>VHDX</span><span>. The signature </span><span>is</span><span> included in </span><span>the </span><span>encrypted </span><span>shield</span><span>ing </span><span>data file</span><span>s</span> <span>(.</span><span>pdk</span><span> file</span><span>s</span><span>) </span><span>and </span><span>used to check the VHDX </span><span>during provisioning</span><span>. If the </span><span>VHDX’s current signature </span><span>doesn’t </span><span>match, </span><span>VM </span><span>provisioning </span><span>will fail</span><span>. Shielding data file</span><span>s</span> <span>are</span><span> unique to shielded VM provisioning</span><span> and</span><span> you can find more information </span><a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-tenant-creates-shielding-data"><span>here</span></a><span>.</span> <span>Therefore, to create a PAW VM, you will need to </span><span>have a</span><span> shielding data file</span><span> and a </span><span>VM template</span><span> disk with a matching</span><span> or trusted signature</span><span>. </span><span>You can find the steps to create shield</span><span>ing</span><span> data file</span><span>s</span> <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/11/01/how-to-create-a-vm-template-for-paw/"><span>here</span></a><span>.</span><span> </span>

In my next blog post, I will share how I built a couple of PAW VM template. If you have ideas/requests, you are welcome to share it with <a href="mailto:pawfeedback@microsoft.com">us</a>.

<span></span>]]></content:encoded>
    </item>
    <item>
      <title>Improved branch office support for shielded VMs in Windows Server, version 1709</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/improved-branch-office-support-for-shielded-vms-in-windows-server-version-1709</link>
      <pubDate>Wed, 15 Nov 2017 09:00:02 GMT</pubDate>
      <dc:creator><![CDATA[Ryan Puffer]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1446</guid>
      <description><![CDATA[Companies with large branch offices often must make a tradeoff between user experience and security....]]></description>
      <content:encoded><![CDATA[Companies with large branch offices often must make a tradeoff between user experience and security. To increase employee productivity, it may make sense to deploy replicas of certain applications like Active Directory Domain Controllers or file servers in a branch office. But with limited — if any — IT resources at the remote location, how can you ensure your data is secure?
This is where shielded virtual machines come to the rescue! Shielded VMs allow you to encrypt the data of virtual machines to prevent someone with access to the Hyper-V server from accessing your sensitive data. To ensure the Hyper-V host is trusted to run your VM, it needs to prove to the Host Guardian Service (HGS) that it is configured as-expected and retrieve the keys needed to start up your shielded VM. Typically, HGS would reside in your primary datacenter where it can be better protected and managed by your security team.

With Windows Server, version 1709, we’ve made it easier to support branch offices with poor WAN links back to the main datacenter. This is done by installing a virtualized HGS server in the branch office. To run a local copy of HGS in a branch office, you would want to shield it to protect the key material from being stolen. But how do you bootstrap the first shielded HGS server? It needs another HGS to release its keys. That’s why we’ve introduced fallback URLs in Hyper-V to allow your Hyper-V server to prefer a local HGS server and fall back to your main datacenter’s HGS in case the local server is offline.

This blog post explains the recommended architecture for setting up HGS in a branch office scenario.
<h2>Recommended Architecture</h2>
<a href="https://msdnshared.blob.core.windows.net/media/2017/11/BranchOfficeDiagram.png"><img src="https://msdnshared.blob.core.windows.net/media/2017/11/BranchOfficeDiagram.png" alt="Branch office HGS configuration diagram" class="aligncenter size-full wp-image-1455" width="827" height="313" /></a>

To set up a branch office HGS, follow these high-level steps:
<ol>
 	<li>Ensure your main datacenter's HGS cluster is installed and operational. For more information, read our <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-setting-up-the-host-guardian-service-hgs">HGS deployment instructions</a>.</li>
 	<li>Ensure your branch office has at least one Hyper-V host running Windows Server, version 1709 or higher and network connectivity to your main datacenter. Register your branch office Hyper-V host with your main datacenter's HGS cluster by following our <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-configure-hgs-with-authorized-hyper-v-hosts">guarded host deployment instructions</a>. At this point, since you only have one HGS cluster, the Hyper-V host should use the datacenter's HGS server as the primary HGS server.</li>
 	<li><a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-configuration-scenarios-for-shielded-vms-overview">Deploy a new shielded VM</a> running Windows Server 2016 on your branch office Hyper-V server. This will become your branch office HGS server. Note that while the Hyper-V host must run Windows Server, version 1709, we recommend using Windows Server 2016 for the HGS servers.</li>
 	<li>Configure the new shielded VM as an HGS server following our <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-setting-up-the-host-guardian-service-hgs">HGS deployment instructions</a>. This HGS server should not join the existing HGS cluster, nor should it use the same certificates as the main datacenter's HGS servers. You can, however, join the new HGS server to the same Active Directory domain, if desired. You can optionally add more HGS servers in the branch office for resiliency, but since you have the main datacenter as a fallback option, you may only need one HGS server running in the remote office.</li>
 	<li>Register the Hyper-V host (and any others in your branch office) with your new HGS server. Be sure to keep both the branch office HGS and main datacenter HGS servers updated with your latest Hyper-V host attestation information. Your operations team should ensure both servers get updated whenever a Hyper-V host configuration changes in the branch office.</li>
 	<li>Reconfigure the Hyper-V host to use the new branch office HGS server as its primary HGS server and the main datacenter's HGS server as a fallback with <a href="https://docs.microsoft.com/en-us/powershell/module/hgsclient/set-hgsclientconfiguration">Set-HgsClientConfiguration</a>. Details on how to do this are included at the end of the blog post.</li>
 	<li>Finally, deploy the rest of your shielded VMs in the branch office. It is recommended that you configure those VMs with the guardians of both the branch office and main datacenter HGS servers so that either HGS can start them up.</li>
</ol>
You can repeat these steps for each branch office you want to configure. In general, we have three core recommendations for branch office deployments:
<ol>
 	<li>Every branch should use a different HGS cluster with unique certificates. Don't join the branch office HGS nodes to the primary datacenter's HGS cluster.</li>
 	<li>Keep the attestation policies in sync between the primary datacenter and branch office HGS nodes. If the branch office HGS goes down, your Hyper-V host will need to pass attestation with your main datacenter's HGS.</li>
 	<li>For the best resiliency, configure every shielded VM at the branch office to authorize both the branch office and main datacenter HGS guardians to decrypt the VM. The branch office HGS servers must always allow the main datacenter HGS to start them up. For example, the VMs in your branch office may be configured such that:
<ul>
 	<li>The shielded HGS server is configured with an owner guardian (central IT) and one additional guardian for the main datacenter HGS</li>
 	<li>An application server shielded VM is configured with an owner guardian (business group IT) and two additional guardians, one for the shielded HGS server running in the branch office and one for the main datacenter in case the branch office HGS is offline.</li>
</ul>
</li>
</ol>
<h2>Configuring fallback URLs in Hyper-V</h2>
To use the new fallback functionality, you will need to use Hyper-V on Windows Server, version 1709. <a href="https://docs.microsoft.com/en-us/windows-server/get-started/semi-annual-channel-overview">Read more about the semi-annual channel</a> to decide if upgrading to version 1709 is right for you.

You will need the URLs for both your primary (typically, the branch office HGS) and fallback (main datacenter) servers to continue. Once you have them, run the following command in PowerShell on the Hyper-V host to configure the URLs:

(Don't forget to swap "primaryhgs" and "fallbackhgs" for your own DNS names!)
<pre>Set-HgsClientConfiguration -KeyProtectionServerUrl https://primaryhgs/KeyProtection -AttestationServerUrl https://primaryhgs/Attestation -FallbackKeyProtectionServerUrl https://fallbackhgs/KeyProtection -FallbackAttestationServerUrl https://fallbackhgs/Attestation</pre>
You can check if your Hyper-V host is passing attestation by using Test-HgsClientConfiguration:
<pre>Test-HgsClientConfiguration -UsePrimary
Test-HgsClientConfiguration -UseFallback</pre>
If you are no longer using a fallback HGS server, you can remove it by using Set-HgsClientConfiguration without fallback URLs:
<pre>Set-HgsClientConfiguration -KeyProtectionServerUrl https://primaryhgs/KeyProtection -AttestationServerUrl https://primaryhgs/Attestation</pre>
<h2>When is a fallback server used?</h2>
Hyper-V will only use a fallback HGS server if it is configured with fallback URLs and the primary HGS server is unreachable or returns another non-transient error. A common example of this would be if the primary HGS servers were offline, resulting in the host being unable to establish a connection. The Hyper-V host will try to contact the primary HGS server a second time before moving to the fallback URL after a maximum of 120 seconds without a response. It will <em>always</em> try to use the primary URL first, even if it just used the fallback URL for its last attestation attempt or key unwrapping. If Hyper-V <em>can</em> reach the primary HGS server, but fails attestation or receives another terminating response, it will not attempt the fallback URL.

You can monitor the<strong> Microsoft-Windows-HostGuardianService-Client/Operational </strong>event log for event ID <strong>2021</strong> on a Hyper-V host to see when a fallback server is in use.

&nbsp;

We hope you'll find this fallback feature helpful when you're trying to secure your branch office IT. As always, if you have any questions, reach out to us at <a href="mailto:shieldedvmfeedback@microsoft.com">shieldedvmfeedback@microsoft.com</a>.]]></content:encoded>
    </item>
    <item>
      <title>How to deploy a VM template for PAW</title>
      <link>https://docs.microsoft.com/archive/blogs/datacentersecurity/how-to-create-a-vm-template-for-paw</link>
      <pubDate>Wed, 01 Nov 2017 12:54:59 GMT</pubDate>
      <dc:creator><![CDATA[Jian (Jane) Yan[MSFT]]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.technet.microsoft.com/datacentersecurity/?p=1415</guid>
      <description><![CDATA[Continuing with the PAW series, after you followed the previous blog to build the PAW device, you...]]></description>
      <content:encoded><![CDATA[Continuing with the PAW series, after you followed the previous <a href="https://blogs.technet.microsoft.com/datacentersecurity/2017/10/17/paw-host-buildout/">blog</a> to build the PAW device, you can now deploy PAW VMs on it. There are two types of VMs you can create:
<ul>
 	<li>Desktop VM: this is a standard VM, dedicated for user productivity workload. It is typically joined to your org production domain. You can use the same image for deploying the user desktop for this VM.</li>
 	<li>PAW VM: this is a shielded VM, used for secure workload, such as server administration. This image needs to be prepared, such that, any tampering to the image will render the image invalid, and fail to deploy new VMs. The image should contain all the applications, and the OS can be locked down to run only those applications.</li>
</ul>
<em>If you are part of the PAW TAP program, you can download a couple of templates I created for evaluation.</em>

This blog post walks you through step-by-step on how to deploy a shielded VM template on a PAW device.

<strong>Important</strong>: you will need a different machine (physical or virtual) to create the template disk and other necessary files. The machine should run Windows 10 1709 client. You can download and installed the RSAT package from <a href="https://www.microsoft.com/en-us/download/details.aspx?id=45520&amp;751be11f-ede8-5a0c-058c-2ee190a24fa6=True">here</a>, make sure you select this file: <strong>WindowsTH-RSAT_WS2016-x64.msu. </strong>(Note that WindowsTH-RSAT_WS_1709-*.msu package will not work).

Once RSAT is installed, these features are added in the start menu: <strong>Template Disk Wizard</strong> and <strong>Shielding Data File Wizard</strong>. You can use the Template Disk Wizard to create the VM template disk, and the Shielded Data File Wizard to create the PDK file.
<h1>Pre-requisites</h1>
You need a template disk created by following this <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-tenant-creates-template-disk">article<span>, </span></a>which provides the details of how the template disk works to prevent any tampering. The section "Sign and protect the VHDX with the template disk wizard" in the article has the instructions of how to build a template disk.

For convenience, below is a short description on how to create a template disk from a syspreped OS image. You can either use the <b>Template Disk Wizard</b>, or run the following PowerShell commands :
<pre><span>$cert = New-SelfSignedCertificate -DnsName 'signing.contoso.com'</span></pre>
<pre><span>Protect-TemplateDisk -Path ‘C:\PAWVM.vhdx’ -TemplateName "PAWTemplate" -Version 1.0.0.1 -Certificate $cert</span></pre>
<h1>Creating shielding data file (PDK)</h1>
The shielding data file is an encrypted file that the admin creates to protect sensitive information used during deployment, such as user passwords. When provisioning a shielded VM, it requires this file. If you are not familiar with the concept of shielding data file, you can find more details <a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-tenant-creates-shielding-data">here</a>.

This section illustrates the process specific for a PAW solution.
<h2>Prepare necessary files</h2>
The PAW PDK files requires the following files:
<ul>
 	<li>HGS Guardian</li>
 	<li>Windows Unattend file</li>
 	<li>Template disk volume signature</li>
</ul>
<h3>HGS guardian</h3>
HGS guardian contains the public key used to encrypt the data on the PAW device. You will need to retrieve the information from the HGS server which the PAW device is attested to. You can run the following PowerShell command on any machine that can connect to the HGS server:
<pre>Invoke-WebRequest https://&lt;HGSServer"&gt;FQDN&gt;/KeyProtection/service/metadata/2014-07/metadata.xml -OutFile C:\HGSGuardian.xml</pre>
<em>If you are using the TAP evaluation image, you can get the PartnerPAWPoCGuardian,xml file from the Yammer group.</em>
<h3>Windows Unattend file</h3>
Unattend file is critical for provisioning a Shielded VMs, where the VM can only be connected through RDP. In testing, I recommend using Encryption supported policy. You can find the differences between Encryption supported and shielded on "<a href="https://docs.microsoft.com/en-us/windows-server/virtualization/guarded-fabric-shielded-vm/guarded-fabric-shielded-vm-planning-for-tenants">Security level for VMs</a>".

Unattend file varies slightly from different Windows released versions, to make it easy, we created a base unattend file and a cmdlet which can modify it based on the Windows version you want to run. You can get the module from the Powershell Gallery. I attached a copy of sample unattend for Windows client 1709 Enterprise at the end of the blog post, make sure you modify it before use it.
<h3>Template disk volume signature</h3>
At deployment time, the template disk will be checked against the signature to validate its integrity. If the template has been tampered with, PAW VM creation will fail. The template disk volume signature file captures the disk signature and package it into the PDK file.

You can run the following cmdlet to create the template disk volume signature file:

Save-VolumeSignatureCatalog -TemplateDiskPath &lt;templatefilename.vhdx&gt; -VolumeSignatureCatalogPath &lt;templatefilename.vsc&gt;

<em>As part of TAP, you can download the vsc files through the Yammer group. Be sure the include the right VSC file for the matching template VHDX file, otherwise, VM creation will fail.</em>
<h2>Create PDK</h2>
You can use the Shielding Data File Wizard to create the PDK file, or using the following cmdlet:

[snippet slug=new-paw-pdk line_numbers=false lang=bsh]
<h1>Create PAW VM</h1>
Copy the template disk VHDX and the PDK file on the PAW device in the same folder, and run the PAWClientApp to create the VM. You can see the video on how its done here:

[video width="1620" height="1080" mp4="https://msdnshared.blob.core.windows.net/media/2017/11/CreateVM.mp4"][/video]

<em>If you are using the TAP images, you should place the template disk on the D drive, and make sure you open the Storage setting page of the PAWClientApp, and change the default a location on D.</em>

If you don't have the PAWClientApp, we are releasing a cmdlet module in a couple of weeks to make the shielded VM creation easy.

&nbsp;
<h1>Conclusion</h1>
As always, you feedback and questions will help us to make this better. Feel free to share your comment below or email <a href="mailto:pawfeedback@microsoft.com?subject=PAW%20V1%20feedback">us</a>.
<h1>Appendix - Sample unattend.xml</h1>
[snippet slug=sample-windows-client-1709-unattended line_numbers=false lang=xml]

&nbsp;]]></content:encoded>
    </item>
  </channel>
</rss>