Home
»
Discussion Forums
»
Scripts & Agent Procedures
»
Script to extract windows and office key codes
Subscribe via RSS
Share this
Similar Posts
Extract ISO - Script
by
LegacyPoster
on
Nov 9, 2009
Perl Scripts and Exit Codes
by
mmackey
on
Apr 17, 2014
Need "extract" option for scripts
by
LegacyPoster
on
Sep 16, 2008
Extracting text from a log file in a script...
by
Stuart
on
Jan 31, 2012
Verified Answer
code 80072efd on Vista with Windows Update
by
LegacyPoster
on
Aug 3, 2009
View More
Details
5
Replies
0
Subscribers
Posted
over 13 years ago
Scripts & Agent Procedures
Script to extract windows and office key codes
Posted by
LegacyPoster
on
Jun 1, 2007 1:28 AM
This script will get the install codes for Windows and office and write them to the script log.
Handy for compliance and for those clients that lost their key codes.
You will need to download keyfinder.exe from
www.magicaljellybean.com/keyfinder.shtml
-------------------------------------------
Script Name: Get Windows and Office Key Codes
Script Description: Runs keyfinder to get codes, writes codes to text file, gets text file and copies to script log.
IF True
THEN
Get Variable
Parameter 1 : 0
Parameter 2 : HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\ComputerName\ComputerName\computername
Parameter 3 : computername
OS Type : 0
Get Variable
Parameter 1 : 10
Parameter 2 :
Parameter 3 : agenttmp
OS Type : 0
Write File
Parameter 1 : #agenttmp#\keyfinder.exe
Parameter 2 : VSASharedFiles\keyfinder.exe
OS Type : 0
Execute Shell Command
Parameter 1 : #agenttmp#\keyfinder.exe /save /close
Parameter 2 : 0
OS Type : 0
Get Variable
Parameter 1 : 1
Parameter 2 : #agenttmp#\#computername#.txt
Parameter 3 : keycodes
OS Type : 0
Write Script Log Entry
Parameter 1 : Keycodes - #keycodes#
OS Type : 0
Delete File
Parameter 1 : #agenttmp#\#computername#.txt
OS Type : 0
ELSE
Legacy Forum Name: Script to extract windows and office key codes,
Legacy Posted By Username: rvines
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
Posted by
LegacyPoster
on
May 30, 2007 1:57 PM
great script. I would like to mention that in my experience, the Office key is right most of the time, and the Windows Key is never right.
I believe that Windows scrambles the key code, so even though it gives you a key that looks legit, you cannot actually use it in any real way that I am aware of.
Again... the Office key is almost always the correct key, so you can use that one....
now a coprporate key might appear with the jelly bean... I have not tested it.
sometimes the key is listed here too.
HKEY_LOCAL_MACHINE/SOFTWARE/MICROSOFT/WINDOWS/CURRENTVERSION/Productkey
but all in all I am unaware of any software tool that will give you the proper CD install key for an OS.
Gamer-X
Legacy Forum Name: System Administration Scripts,
Legacy Posted By Username: Gamer-X
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
Posted by
LegacyPoster
on
May 30, 2007 2:10 PM
You may be right. I've never tested the code. Is there a way to find out if your code is legit (other than trying an install?)
Legacy Forum Name: System Administration Scripts,
Legacy Posted By Username: rvines
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
Posted by
LegacyPoster
on
May 31, 2007 4:58 AM
I would guess that if your keys dont work then you are pairing it with the wrong media version.
XP Keys for OEM, Select, Retail, MSDN etc....are not interchangeable.
Legacy Forum Name: System Administration Scripts,
Legacy Posted By Username: XeviouS
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
Posted by
LegacyPoster
on
Jun 1, 2007 12:57 AM
Kaseya does this inherently now in the Audit function - no need for Magic Jelly Bean anymore!
Legacy Forum Name: System Administration Scripts,
Legacy Posted By Username: tom@tbkconsulting.biz
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
Posted by
LegacyPoster
on
Jun 1, 2007 1:28 AM
I've been rendered uneccessary once again! Doh!
Legacy Forum Name: System Administration Scripts,
Legacy Posted By Username: rvines
You have posted to a forum that requires a moderator to approve posts before they are publicly available.