I wanted to find a unique machine ID, which could be used for node-locked licenses, etc.
This code seems to do the job
- Code: Select all
local s = win32.getRegistry("HKLM SOFTWARE\\Microsoft\\Cryptography", "MachineGuid");
if s then
host:trace(s);
end
Maybe there are better keys? Or is that one ok? Does it work on all versions of Windows? Not sure.