I retrieved my Windows 8 product key from the firmware but have no idea which version it's supposed to match. My Windows 8 cannot be booted into (hence the need to re-install in the first place)
How do I find out the correct version of Windows that my product key matches with?
Answer
Windows includes a DLL called pidgenx.dll
which includes this function:
[DllImport("pidgenx.dll", EntryPoint = "PidGenX", CharSet = CharSet.Auto)]
static extern int PidGenX(string productKey, string pkeyPath, string mspid, int unknownUsage, IntPtr productID, IntPtr digitalProductID, IntPtr digitalProductID4);
For pkeyPath Windows setup passes a path to pkeyconfig.xrm-ms. In this file, the product key are defined and in the digitalProductID4 (last parameter), the Edition and Product key type (MSDN, Retail, Trial) is encoded.
The Ultimate PID Checker is one of several tools that call the function to decode the key.
Here you can see which edition the key belongs to.
No comments:
Post a Comment