FeReNGi Posted September 15, 2006 Share Posted September 15, 2006 Does anybody know how to get the SerialNumber from the computer without the use of WMI. I have to check the serial for installation (boot from a winpe cd without wmi) ServicesPE|LoadVMDK Link to comment Share on other sites More sharing options...
FuryCell Posted September 16, 2006 Share Posted September 16, 2006 (edited) If you are talking about the windows serial , it is stored in the registry. However AFIAK RegRead would not read the installed OS's registry so you would need some other way to extract the key from the registry. This topic may prove useful, However it needs to be modified to read the other OS's registry.http://www.autoitscript.com/forum/index.php?showtopic=1506 Edited September 16, 2006 by SolidSnake HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code. Link to comment Share on other sites More sharing options...
Danny35d Posted September 16, 2006 Share Posted September 16, 2006 Does anybody know how to get the SerialNumber from the computer without the use of WMI.I have to check the serial for installation (boot from a winpe cd without wmi)if you're looking for the computer serial, on my Bartpe I use Ghost32.exe -lockinfo, it create a text file with the basic computer information like computer model and serial number... AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line Link to comment Share on other sites More sharing options...
FeReNGi Posted September 16, 2006 Author Share Posted September 16, 2006 (edited) @danny35d Your the man that is what am looking for it ! Is there any possibility to read this by auotit ? Edited September 16, 2006 by FeReNGi ServicesPE|LoadVMDK Link to comment Share on other sites More sharing options...
/dev/null Posted September 16, 2006 Share Posted September 16, 2006 @danny35dYour the man that is what am looking for it !Is there any possibility to read this by auotit ?you could use cpu-z in batch mode (-file=xxx.txt) and parse the output for any string you think could be a good "serial number" for you.http://www.cpuid.org/cpuz.phpCheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
Danny35d Posted September 16, 2006 Share Posted September 16, 2006 @danny35d Your the man that is what am looking for it ! Is there any possibility to read this by auotit ?Yes it is possible. The script below will give you an array with all the computer information. #include <Array.au3> #include <File.au3> Local $GhostInfo RunWait(@ComSpec & ' /c Ghost32.exe -lockinfo > ' & @TempDir & '\GhostInfo.txt', @WorkingDir, @SW_HIDE) $CountLines = _FileCountLines(@TempDir & '\GhostInfo.txt') For $x = 3 To $CountLines $Line = FileReadLine(@TempDir & '\GhostInfo.txt', $x) If $Line <> '' Then If StringInStr($Line, 'not supported') <> 0 Then $Line = '' $GhostInfo &= StringReplace(StringStripWS(StringMid($Line, StringInStr($Line, '"')), 3), '"', '') & '|' EndIf Next $GhostInfo = StringSplit(StringTrimRight($GhostInfo, 1), '|') _ArrayDisplay($GhostInfo, 'Ghost32 LockInfo') GhostInfo[0] = Array Size GhostInfo[1] = Manufacturer GhostInfo[2] = Product Name GhostInfo[3] = Version GhostInfo[4] = Serial Number GhostInfo[5] = UUID GhostInfo[6] = Manufacturer & Product Name Combined GhostInfo[7] = PIII Id JCEF 1 AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line Link to comment Share on other sites More sharing options...
webmedic Posted September 17, 2006 Share Posted September 17, 2006 there is a native autoit way. MHZ had posted a script over at msfn that does this without using any external code. I can try to hunt it up if you like. I know I have it laying around someplace or at least I used to and I dont think I have thrown it away. Link to comment Share on other sites More sharing options...
FeReNGi Posted September 17, 2006 Author Share Posted September 17, 2006 @webmedic all solutions are welcome @Danny35d also thx for your custom script I'm setting up a TFTP server to boot a bartpe cd. That boot cd should read the serial number from the computer and compare it with another list to catch his computername. If that is succesfull the ghost process can continue and install the pc. Therefore i need a way to read the computers serial number without WMI because WMI doesn't work on a bartpe cd. ServicesPE|LoadVMDK Link to comment Share on other sites More sharing options...
webmedic Posted September 17, 2006 Share Posted September 17, 2006 (edited) Are you shure I thought there was a plugin for wmi but then again I wouldn't use it since I use autoit on barts anyway. expandcollapse popupFunc _DecodeProductKey(); Returns Windows XP CD Key Local $bKey[15] Local $sKey[29] Local $Digits[24] Local $Value = 0 Local $hi = 0 Local $n = 0 Local $i = 0 Local $dlen = 29 Local $slen = 15 Local $Result Local $BinaryDPID = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion", "DigitalProductID") $Digits = StringSplit("BCDFGHJKMPQRTVWXY2346789", "") $BinaryDPID = StringMid($BinaryDPID, 105, 30) For $i = 1 To 29 Step 2 $bKey[Int($i / 2) ] = Dec(StringMid($BinaryDPID, $i, 2)) Next For $i = $dlen - 1 To 0 Step - 1 If Mod( ($i + 1), 6) = 0 Then $sKey[$i] = "-" Else $hi = 0 For $n = $slen - 1 To 0 Step - 1 $Value = BitOR(BitShift($hi, -8), $bKey[$n]) $bKey[$n] = Int($Value / 24) $hi = Mod($Value, 24) Next $sKey[$i] = $Digits[$hi + 1] EndIf Next For $i = 0 To 28 $Result = $Result & $sKey[$i] Next $change = StringSplit($Result, '-') Return $change EndFunc try that. It should do what you want. As far as how to load a remote hive from another computer you should know how to do that from services pe. Um one last thing when you get your tftp server thing up and running whould you mind sharing? I have though about doing one but never have. Edited September 17, 2006 by webmedic Link to comment Share on other sites More sharing options...
JerryD Posted September 17, 2006 Share Posted September 17, 2006 The serial#, model, etc. is all available from WMI and easily coded using SvenP's great adaptation of the Microsoft WMI Scripting tool:http://www.autoitscript.com/forum/index.ph...criptomatic.au3 Link to comment Share on other sites More sharing options...
webmedic Posted September 17, 2006 Share Posted September 17, 2006 he already stated he is using it from barts pe and wmi is not available. Link to comment Share on other sites More sharing options...
FeReNGi Posted September 18, 2006 Author Share Posted September 18, 2006 (edited) @webmedici use TFTP32 as TFTP server (a freeware)When i press F12 (boot from network) on a Dell PC a linux menu is presented with the option to choose wich image i want to load.Then my bartpe image is transmitted to the computers ram.In this image i want to read the serial from the computer and compare it to a predefined list to get the computername.Next stage is ghosting the computer and automatic put computer in domain and install all the standard software and optional software from a list.Why i need the serial from the computer is to be sure the asset is created and the computername is assigned to it.This has to be done completely automatic.All you need for a TFTP server can be found on nex link :http://xpe.collewijn.info/page/tftpd_ris.php or http://tftpd32.jounin.net/ Edited September 18, 2006 by FeReNGi ServicesPE|LoadVMDK Link to comment Share on other sites More sharing options...
Danny35d Posted September 18, 2006 Share Posted September 18, 2006 (edited) Next stage is ghosting the computer and automatic put computer in domain and install all the standard software and optional software from a list. Why i need the serial from the computer is to be sure the asset is created and the computername is assigned to it. This has to be done completely automatic. All you need for a TFTP server can be found on nex link : http://xpe.collewijn.info/page/tftpd_ris.php or http://tftpd32.jounin.net/Thanks for the information I will give it a try... I do something similar at my work. I use Ghost32.exe -lockinfo to get the computer model and depending the computer model it will chose a ghost image from my server. I don't know if your are doing this with brand new computers, but with used computers that I need to reimage I discover that some systems had viruses loaded at the master boot record. Now before even ghost start loading the image I use AEFDISK32.EXE 1 /mbr to clean the master boot record, aefdisk32 work fine with winpe or bartpe. After ghost finish loading the image the same script will change c:\sysprep\sysprep.inf so when the coputer reboot I will have the right computer name and join the domain. On autoit you can use INIWRITE to change sysprep.inf [userData] ComputerName= [identification] DomainAdminPassword= DomainAdmin= JoinDomain= Also the ghost images that I create: 1) I build the computer OS (Win2k or WinXP) on FAT32 partition. 2) After loading all the applications and setting up the OS, I open CMD and type convert c: /fs:NTFS /v /x 3) Then run sysprep and shutdown, after shutdown boot up with my bartpe and create the ghost image. The reason that I create the image on FAT32 is if later on I need to add or delete files to the image I can use GhostExplorer to open the image and add or delete files from the image without having to load the image into a computer and ghosted again. Edited September 18, 2006 by Danny35d AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line Link to comment Share on other sites More sharing options...
urie Posted September 18, 2006 Share Posted September 18, 2006 @webmedic i use TFTP32 as TFTP server (a freeware) When i press F12 (boot from network) on a Dell PC a linux menu is presented with the option to choose wich image i want to load. Then my bartpe image is transmitted to the computers ram. In this image i want to read the serial from the computer and compare it to a predefined list to get the computername. Next stage is ghosting the computer and automatic put computer in domain and install all the standard software and optional software from a list. Why i need the serial from the computer is to be sure the asset is created and the computername is assigned to it. This has to be done completely automatic. All you need for a TFTP server can be found on nex link : http://xpe.collewijn.info/page/tftpd_ris.php or http://tftpd32.jounin.net/ dont know if this may help but nirsoft have a utility called ProduKey which can work over networks. Examples: produkey.exe /remote \\Server01 produkey.exe /remotefile "c:\temp\computers.txt" produkey.exe /regfile "F:\WINNT\system32\config\software" produkey.exe /windir "c:\winnt" /shtml "c:\temp\pk.html" produkey.exe /remoteall produkey.exe /remotealldomain MyDomain Info and download here: http://www.nirsoft.net/utils/product_cd_key_viewer.html also there is a version of magic jellybean keyfinder that works with bart pe. link: http://www.geocities.com/acid_zebra/ Link to comment Share on other sites More sharing options...
Danny35d Posted September 18, 2006 Share Posted September 18, 2006 @urie Thanks for the information but FeReNGi actually need the computer serial number, no the Windows serial or key number. AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line Link to comment Share on other sites More sharing options...
webmedic Posted September 18, 2006 Share Posted September 18, 2006 nirsoft is not free for commercial use. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now