Hi,
I've a VBScript that you run and it tells you the product key of windows.
I've run this on maybe 20 machines at work so far as part of the asset tracking system I am building, but, I've had 3 machines come up with the same key.
All in the same department, desktop running Win10 Pro 64, desktop running Win10 Home 64 and a laptop running Win10 Home 64.
I know that before I started they thought it was ok to run a home Office 365 account and install it over 5 different machines within the business. Is it possible it's picking up the Office product key and not the Windows one?
I'm not sure why or how it would be doing it with Windows.
I've a VBScript that you run and it tells you the product key of windows.
I've run this on maybe 20 machines at work so far as part of the asset tracking system I am building, but, I've had 3 machines come up with the same key.
All in the same department, desktop running Win10 Pro 64, desktop running Win10 Home 64 and a laptop running Win10 Home 64.
I know that before I started they thought it was ok to run a home Office 365 account and install it over 5 different machines within the business. Is it possible it's picking up the Office product key and not the Windows one?
Code:
Set WshShell = CreateObject("WScript.Shell")
MsgBox ConvertToKey(WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId"))
Function ConvertToKey(Key)
Const KeyOffset = 52
i = 28
Chars = "BCDFGHJKMPQRTVWXY2346789"
Do
Cur = 0
x = 14
Do
Cur = Cur * 256
Cur = Key(x + KeyOffset) + Cur
Key(x + KeyOffset) = (Cur \ 24) And 255
Cur = Cur Mod 24
x = x -1
Loop While x >= 0
i = i -1
KeyOutput = Mid(Chars, Cur + 1, 1) & KeyOutput
If (((29 - i) Mod 6) = 0) And (i <> -1) Then
i = i -1
KeyOutput = "-" & KeyOutput
End If
Loop While i >= 0
ConvertToKey = KeyOutput
End Function
I'm not sure why or how it would be doing it with Windows.