First, Microsoft licensing does not work this way.
They have a key that is generated on their side of things. When they sell you a copy of the software, they give you the key. After entering the key, the software sends some encrypted tcp packets back to MS to determine that the key is now in use and increase the amount of use. Then it creates a beautifully hidden file on your system that contains the authorization for this key.
None of this is related to obtaining a "computer ID".
Now MS (for at least one of its licensing models) takes a snapshot of the system, which includes the processor type, hard drive and make / model motherboard, to determine if the components have been changed so as to cause a potential check if check computer license.
This brings us back to the idea that there is not a single βidentifierβ in a computer system. The last time this was done, Intel was using (in my opinion?) Its PII processors. However, public recall was enough that they stopped putting serial numbers on the chip.
The next closest thing you can do is try and read the MAC address; but network cards often change so much that it is littered with traps.
I would highly recommend that you explore other mechanisms for executing license keys, if that is really what you want.
source share