Registrations to Open-AudIT forums are now closed. To ask any new questions please visit Opmantek Community Questions.

Open-AudIT

What's on your network?
It is currently Thu Mar 28, 2024 9:31 pm

All times are UTC + 10 hours




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 35 posts ]  Go to page 1, 2, 3  Next
Author Message
 Post subject: Office 2007 keys [FIXED]
PostPosted: Tue Oct 16, 2007 7:05 pm 
Offline
Newbie

Joined: Fri Oct 12, 2007 7:36 pm
Posts: 1
I don't see the Office 2007 installations in the keys lists, is that supposed to be supported yet? (I'm on version 07.08.28)


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Oct 16, 2007 7:37 pm 
Offline
Site Admin
User avatar

Joined: Mon Jun 07, 2004 11:48 am
Posts: 1964
Location: Brisbane, Australia
I don't think we have Office 2007 in the vbscript (yet).
If you can find some code online (in vbscript) that we can use, please post.

Unfortunately, I can't test this - I use Ubuntu, and have absolutely no need for MS Office.

If can find then post the code, I am sure other can / will test it - then we can include it.

_________________
Support and Development hours available from [url=https://opmantek.com]Opmantek[/url].
Please consider a purchase to help make Open-AudIT better for everyone.


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Oct 16, 2007 11:51 pm 
Offline
Moderator
User avatar

Joined: Tue Jan 25, 2005 3:09 am
Posts: 2140
Location: Scotland
Mark, you might like to look at the tricks used here...

http://www.visualbasicscript.com/m_42793/tm.htm

Wont have much time to try this... :cry:

_________________
Andrew

[size=85]OA Server: Windows XP/ XAMPP, Mandriva/Apache, Ubuntu
Auditing: 300+ Wstns, 20+ Srvrs, Thin clients, Linux boxes, Routers, etc
OS's: Windows XP , W2K Srvr, W2K3 Srvr, W2K8, Vista, Windows 7, Linuxes (and a Mac at home)
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Wed Oct 17, 2007 9:21 am 
Offline
Site Admin
User avatar

Joined: Mon Jun 07, 2004 11:48 am
Posts: 1964
Location: Brisbane, Australia
OK, anyone want to test this ?
Go into your registry, and find the appropriate key/location for the Office 2007 stuff. Then alter the line in strKeyPath variable to match (line 4).
Let us know if it works, and what the registry location for the Office 2007 stuff is.


[code]' <--------------- Open Registry Key and populate binary data into an array -------------------------->
'
const HKEY_LOCAL_MACHINE = &H80000002
strKeyPath = "SOFTWARE\Microsoft\Office\11.0\Registration\{90110409-6000-11D3-8CFE-0150048383C9}"
strValueName = "DigitalProductId"
strComputer = "."
dim iValues()
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & _
strComputer & "\root\default:StdRegProv")
oReg.GetBinaryValue HKEY_LOCAL_MACHINE,strKeyPath,strValueName,iValues
Dim arrDPID
arrDPID = Array()
For i = 52 to 66
ReDim Preserve arrDPID( UBound(arrDPID) + 1 )
arrDPID( UBound(arrDPID) ) = iValues(i)
Next
' <--------------- Create an array to hold the valid characters for a microsoft Product Key -------------------------->
Dim arrChars
arrChars = Array("B","C","D","F","G","H","J","K","M","P","Q","R","T","V","W","X","Y","2","3","4","6","7","8","9")

' <--------------- The clever bit !!! (Decrypt the base24 encoded binary data) -------------------------->
For i = 24 To 0 Step -1
k = 0
For j = 14 To 0 Step -1
k = k * 256 Xor arrDPID(j)
arrDPID(j) = Int(k / 24)
k = k Mod 24
Next
strProductKey = arrChars(k) & strProductKey
If i Mod 5 = 0 And i <> 0 Then strProductKey = "-" & strProductKey
Next
strFinalKey = strProductKey
'
' <--------------- This part of the script displays a completed/summary message ----------------->
'
Set wshShell=CreateObject("wscript.shell")
strPopupMsg = "Your Microsoft Office Product Key is:" & vbNewLine & vbNewLine & strFinalKey
strPopupTitle = "Product Key"
wshShell.Popup strPopupMsg,,strPopupTitle,vbCancelOnly+vbinformation
WScript.Quit[/code]

_________________
Support and Development hours available from [url=https://opmantek.com]Opmantek[/url].
Please consider a purchase to help make Open-AudIT better for everyone.


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Wed Oct 17, 2007 6:33 pm 
Offline
Moderator
User avatar

Joined: Tue Jan 25, 2005 3:09 am
Posts: 2140
Location: Scotland
To save a lot of trawling...
So far as I know the key should be in HKEY_LOCAL_MACHINE\Software\Microsoft\Office\12.0\Registration

But this may be something like... HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\12.0\Registration\{91120000-0011-0000-0000-0000000FF1CE}
(where the last section resembles a SAM/UUID/GID of some sort, and may not be exactly as shown)

Further info may be found at http://support.microsoft.com/kb/895456 )

However I am not using Office 2007, so I can't be sure. Try there first.

_________________
Andrew

[size=85]OA Server: Windows XP/ XAMPP, Mandriva/Apache, Ubuntu
Auditing: 300+ Wstns, 20+ Srvrs, Thin clients, Linux boxes, Routers, etc
OS's: Windows XP , W2K Srvr, W2K3 Srvr, W2K8, Vista, Windows 7, Linuxes (and a Mac at home)
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Wed Oct 17, 2007 10:51 pm 
Offline
Helper

Joined: Tue Jul 25, 2006 2:33 am
Posts: 83
Location: Hampshire, UK
On the only machine I have using Office 2007 I see two keys in the area that Andrew usefully pointed to:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\12.0\Registration\{91120000-00BA-0000-0000-0000000FF1CE}
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\12.0\Registration\{91120000-0014-0000-0000-0000000FF1CE}

They both seem to have similar content so someone with more Registry Key knowledge than I have may be able to work out if you need to check for one or both.

John

_________________
OA environment:
OA Server: Ubuntu 10.04LTS
1 Windows 2008R2 Server
4 Windows 2003 Servers
20 Windows XP workstations
1 Windows 7 workstation
2 Ubuntu 11.10 servers
Misc other networked items


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Thu Oct 18, 2007 7:10 pm 
Offline
Site Admin
User avatar

Joined: Mon Jun 07, 2004 11:48 am
Posts: 1964
Location: Brisbane, Australia
[quote]On the only machine I have using Office 2007 I see two keys

So JayDee - did you try inserting this into the script above, and running it ?

_________________
Support and Development hours available from [url=https://opmantek.com]Opmantek[/url].
Please consider a purchase to help make Open-AudIT better for everyone.


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Fri Oct 19, 2007 1:18 am 
Offline
Helper

Joined: Tue Jul 25, 2006 2:33 am
Posts: 83
Location: Hampshire, UK
Probably Friday before I get a chance to try it out...

_________________
OA environment:
OA Server: Ubuntu 10.04LTS
1 Windows 2008R2 Server
4 Windows 2003 Servers
20 Windows XP workstations
1 Windows 7 workstation
2 Ubuntu 11.10 servers
Misc other networked items


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Sat Oct 20, 2007 1:11 am 
Offline
Helper

Joined: Tue Jul 25, 2006 2:33 am
Posts: 83
Location: Hampshire, UK
Tried out Mark's code above with the 2 Registry entries I found, also above, and the CD Keys popped up fine. So I guess we are on right track...

_________________
OA environment:
OA Server: Ubuntu 10.04LTS
1 Windows 2008R2 Server
4 Windows 2003 Servers
20 Windows XP workstations
1 Windows 7 workstation
2 Ubuntu 11.10 servers
Misc other networked items


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Oct 30, 2007 12:03 pm 
Offline
Newbie

Joined: Tue Mar 06, 2007 12:46 pm
Posts: 16
Location: Auckland, NZ
This is the code that needs to be added to audit.vbs

[code]''''''''''''''''''''''''''''''''
' MS CD Keys for Office 2007 '
''''''''''''''''''''''''''''''''
strKeyPath = "SOFTWARE\Microsoft\Office\12.0\Registration"
oReg.EnumKey HKEY_LOCAL_MACHINE, strKeyPath, arrSubKeys
For Each subkey In arrSubKeys
name_2007 = get_sku_2007(subkey)
release_type = get_release_type(subkey)
edition_type = get_edition_type(subkey)
path = strKeyPath & "\" & subkey
strOffXPRU = "HKLM\" & path & "\DigitalProductId"
subKey = "DigitalProductId"
oReg.GetBinaryValue HKEY_LOCAL_MACHINE,path,subKey,key
if IsNull(key) then
else
strOffXPRUKey=GetKey(key)
form_input = "ms_keys^^^" & name_2007 & "^^^" _
& strOffXPRUKey & "^^^" _
& release_type & "^^^" _
& edition_type & "^^^" _
& "office_2007" & "^^^"
entry form_input,comment,objTextFile,oAdd,oComment
strOffXPRUKey = ""
release_type = ""
edition_type = ""
form_input = ""
end if
Next
[/code]

and

[code]function get_sku_2007(subkey)
vers = mid(subkey,11,4)
if vers = "0011" then vers_name = "Microsoft Office Professional Plus 2007" end if
if vers = "0012" then vers_name = "Microsoft Office Standard 2007" end if
if vers = "0013" then vers_name = "Microsoft Office Basic 2007" end if
if vers = "0014" then vers_name = "Microsoft Office Professional 2007" end if
if vers = "0015" then vers_name = "Microsoft Office Access 2007" end if
if vers = "0016" then vers_name = "Microsoft Office Excel 2007" end if
if vers = "0017" then vers_name = "Microsoft Office SharePoint Designer 2007" end if
if vers = "0018" then vers_name = "Microsoft Office PowerPoint 2007" end if
if vers = "0019" then vers_name = "Microsoft Office Publisher 2007" end if
if vers = "001A" then vers_name = "Microsoft Office Outlook 2007" end if
if vers = "001B" then vers_name = "Microsoft Office Word 2007" end if
if vers = "001C" then vers_name = "Microsoft Office Access Runtime 2007" end if
if vers = "0020" then vers_name = "Microsoft Office Compatibility Pack for Word, Excel, and PowerPoint 2007 File Formats" end if
if vers = "0026" then vers_name = "Microsoft Expression Web" end if
if vers = "0029" then vers_name = "Microsoft Office Excel 2007" end if
if vers = "002B" then vers_name = "Microsoft Office Word 2007" end if
if vers = "002E" then vers_name = "Microsoft Office Ultimate 2007" end if
if vers = "002F" then vers_name = "Microsoft Office Home and Student 2007" end if
if vers = "0030" then vers_name = "Microsoft Office Enterprise 2007" end if
if vers = "0031" then vers_name = "Microsoft Office Professional Hybrid 2007" end if
if vers = "0033" then vers_name = "Microsoft Office Personal 2007" end if
if vers = "0035" then vers_name = "Microsoft Office Professional Hybrid 2007" end if
if vers = "0037" then vers_name = "Microsoft Office PowerPoint 2007" end if
if vers = "003A" then vers_name = "Microsoft Office Project Standard 2007" end if
if vers = "003B" then vers_name = "Microsoft Office Project Professional 2007" end if
if vers = "0044" then vers_name = "Microsoft Office InfoPath 2007" end if
if vers = "0051" then vers_name = "Microsoft Office Visio Professional 2007" end if
if vers = "0052" then vers_name = "Microsoft Office Visio Viewer 2007" end if
if vers = "0053" then vers_name = "Microsoft Office Visio Standard 2007" end if
if vers = "00A1" then vers_name = "Microsoft Office OneNote 2007" end if
if vers = "00A3" then vers_name = "Microsoft Office OneNote Home Student 2007" end if
if vers = "00A7" then vers_name = "Calendar Printing Assistant for Microsoft Office Outlook 2007" end if
if vers = "00A9" then vers_name = "Microsoft Office InterConnect 2007" end if
if vers = "00AF" then vers_name = "Microsoft Office PowerPoint Viewer 2007 (English)" end if
if vers = "00B0" then vers_name = "The Microsoft Save as PDF add-in" end if
if vers = "00B1" then vers_name = "The Microsoft Save as XPS add-in" end if
if vers = "00B2" then vers_name = "The Microsoft Save as PDF or XPS add-in" end if
if vers = "00BA" then vers_name = "Microsoft Office Groove 2007" end if
if vers = "00CA" then vers_name = "Microsoft Office Small Business 2007" end if
if vers = "00E0" then vers_name = "Microsoft Office Outlook 2007" end if
if vers = "10D7" then vers_name = "Microsoft Office InfoPath Forms Services" end if
if vers = "110D" then vers_name = "Microsoft Office SharePoint Server 2007" end if
get_sku_2007 = vers_name
end function
[/code]

Microsoft have changed the position and the hex numbers of the SKU for Office 2007. See

http://support.microsoft.com/kb/928516/

Cheers,

_________________
Jon Blakely

Computer Troubleshooters - Howick
Auckland
NZ

http://technologysolved.co.nz


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Oct 30, 2007 12:23 pm 
Added to svn... please check that it works!


Top
  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Nov 06, 2007 4:30 am 
Offline
Newbie

Joined: Sat Nov 12, 2005 4:48 am
Posts: 42
Location: USA
I have Version 07.08.28 running and I dont seem to be getting the Office 2007 keys.

_________________
good day all!


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Nov 06, 2007 6:54 am 
If you're running 07.08.28, I suspect you don't have the latest code. Latest db version is 07.10.25. See if there aren't updated files to grab!


Top
  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Nov 06, 2007 7:09 am 
Offline
Newbie

Joined: Sat Nov 12, 2005 4:48 am
Posts: 42
Location: USA
Thats odd cause I used the svn to update and it is showing all is updated.

_________________
good day all!


Top
 Profile  
Reply with quote  
 Post subject: Re: Office 2007 keys
PostPosted: Tue Nov 06, 2007 8:16 am 
Can you check if you have the scan_* tables in your database?


Top
  
Reply with quote  
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 35 posts ]  Go to page 1, 2, 3  Next

All times are UTC + 10 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group