开发者

Office 2010 Product Key & Registration Lookup

开发者 https://www.devze.com 2023-03-15 14:08 出处:网络
I have a small python program I wrote for a friend, one of the tasks is to audit the Office Version & Product Key on the machine it\'s run on.

I have a small python program I wrote for a friend, one of the tasks is to audit the Office Version & Product Key on the machine it's run on.

I was able to locate the 32bit/64bit keys in the registry easily but it seems my algorithm breaks down on the new Office 2010 system.

My first problem is there's now 30+ entries under HKLM\Software\Microsoft\Office\14.0\Common\Registration Although only one seems to have a DigitalProductID However this entry has NO INFORMATION about the suite. (Just the individual products in it)

I开发者_如何转开发 need to pull the version of office installed, I.E. Office 2010 Home & Student, the only thing I can find in the key is Office 2010

Strangely enough the key entry that on previous versions of office that had the full name w/ edition now reports Professional when H&S is installed.

Also it seems the DigitalProductID's decoding algorithm has changed. The same code that decodes the ID properly for 2000-2007 seems to yield a completely wrong code now.

I cannot find any information about office 2010, all results keep pointing me back to the old editions & the same information I used to make the previous version of this tool.

What I need to accomplish:

  • Return the Office Version & Edition (i.e. Office 2010 Home & Student)
  • Decode the ProductKey using the new 2010 method, even just info about the (new?) algorithm.


You have to read another section out of DigitalProductID

In CSharp I used

for (int ilByte = 52; ilByte <= 66; ilByte++)

to read the necessary section to calculate the product key for O2K - O2K7.

With Office 2010 you need to use

for (int ilByte = 808; ilByte <= 822; ilByte++)

to read the bytes which make out the product key.

Regarding the Suite I also have no idea where to pull it from registry. Maybe it's worth contacting WMI for that information.


The position may be correct for Office 2010 , but the algorithm to decode the key must be different than 2007.

Today we entered 3 new CD-Keys in 3 new Laptops and the old 2007 working algorithm returned a wrong CD-Key.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号