Windows Management Framework 5.0 breaks Sysprep

When Windows Management Framework 5.0 is installed on Windows Server 2008 R2 sysprep will fail with the error:

"A fatal error occurred while trying to Sysprep the machine"

Additionally the error log in the location:

C:\Windows\System32\sysprep\panther\setuperr.log  

Will contain the following line:

SYSPRP LaunchDll:Failure occurred while executing 'C:WindowsSystem32silsysprep.dll,Sysprep_Generalize_MiStreamProv', returned error code 2[gle=0x00000002]  

The solution until Microsoft releases a patch is to add the following registry key:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\StreamProvider  
LastFullPayloadTime =  dword:00000000  

Using PowerShell:

New-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\StreamProvider" -Name LastFullPayloadTime -Value 0 -PropertyType DWord -Force  

https://windowsserver.uservoice.com/forums/301869-powershell/suggestions/11591262-bug-wmf-5-production-preview-on-windows-server-2