The MASM Forum Archive 2004 to 2012
Welcome, Guest. Please login or register.
March 02, 2021, 08:30:10 AM

Login with username, password and session length
Search:     Advanced search
128553 Posts in 15254 Topics by 684 Members
Latest Member: mottt
* Home Help Search Login Register
+  The MASM Forum Archive 2004 to 2012
|-+  General Forums
| |-+  The Laboratory (Moderator: Mark_Larson)
| | |-+  OS Info Dump
« previous next »
Pages: [1] 2 3 ... 6 Print
Author Topic: OS Info Dump  (Read 53014 times)
dedndave
Member
*****
Posts: 12523


OS Info Dump
« on: July 28, 2009, 01:41:48 PM »

i am trying to collect information about the different OS's so i can ID them
your help would be greatly appreciated
see the attached program - source included
try to be specific, like "gold edition" or "64-bit"  (actually, i think the 64-bit info is elsewhere - i will work on that)

my OS: Windows XP (Pro) Media Center Edition 2005, sp2

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows XP"
"CurrentVersion"="5.1"
"CurrentBuildNumber"="2600"
"SubVersionNumber"=""
"CSDVersion"="Service Pack 2"
"BuildLab"="2600.xpsp_sp2_rtm.040803-2158"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"="4.0"


EDIT- update - added "ProductId" with the product key portion X'ed out
EDIT - version 2 - added GetVersionEx
EDIT - version 2.01 - added preliminary support for win95/98/98se/ME
EDIT - version 2.02 - modified win95/98/98se/ME so that the os version info structure size is set to 148 for older OS's
EDIT - version 2.03 - added version to banner - overwrite "Press any key to exit" for shorter screen


[attachment deleted by admin]
« Last Edit: August 01, 2009, 08:59:16 AM by dedndave » Logged
UtillMasm
Member
*****
Posts: 560

Please use a non offensive avatar


Re: OS Info Dump
« Reply #1 on: July 28, 2009, 02:10:09 PM »

Code:
C:\>OSinfo.exe

DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Windows Vista (TM) Ultimate"
"CurrentVersion"="6.0"
"CurrentBuildNumber"="6002"
"SubVersionNumber"=(Value not found)
"CSDVersion"="Service Pack 2"
"BuildLab"="6002.lh_sp2rtm.090410-1830"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"="5.0"

Press any key to exit
Logged
fearless
Member
*****
Gender: Male
Posts: 226



Re: OS Info Dump
« Reply #2 on: July 28, 2009, 03:04:19 PM »

Windows XP Home Edition with Service Pack3 (32bit)

Code:
DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows XP"
"CurrentVersion"="5.1"
"CurrentBuildNumber"="2600"
"SubVersionNumber"=""
"CSDVersion"="Service Pack 3"
"BuildLab"="2600.xpsp_sp3_gdr.090206-1234"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Key not found)
Logged

ƒearless
dedndave
Member
*****
Posts: 12523


Re: OS Info Dump
« Reply #3 on: July 28, 2009, 03:14:38 PM »

thank you UtillMasm and fearless
i don't see a way to differentiate Home editions from Pro editions
Logged
fearless
Member
*****
Gender: Male
Posts: 226



Re: OS Info Dump
« Reply #4 on: July 28, 2009, 03:19:26 PM »

Look for the Product ID as well, here is a link that explains what the start code of the product ID means:

http://wiki.lunarsoft.net/wiki/Product_IDs

Mine is 76477-OEM-0012345-67890

so 76477 seems to indicate the following: Windows XP Home OEM SP2     VRMHOEM_EN     4-08-04 12:00     76477     OEM

I remember installing XP which has SP2 already packaged with it, when i bought my new pc and put it together myself, and then i updated to SP3 once it was up and running.


HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId it has then to be converted to the 76477-OEM-0012345-67890 code. I think i have some code or some bookmarks somewhere on how that is done. Ill try and dig it out for you later on.


Edit: ok Dave, cheers for that, i edited out my key info, just in case ;-)
Logged

ƒearless
dedndave
Member
*****
Posts: 12523


Re: OS Info Dump
« Reply #5 on: July 28, 2009, 03:21:56 PM »

you should remove that info fearless (or at least, the part after OEM) - but thank you
maybe i will add it and only show the first part

EDIT - very helpful link - thanks  ThumbsUp
Logged
dedndave
Member
*****
Posts: 12523


Re: OS Info Dump
« Reply #6 on: July 28, 2009, 03:44:17 PM »

i know how to read the binaries
but, don't you have the same info under this value ?

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductId"="76477-OEM-1234567-12345"
Logged
dedndave
Member
*****
Posts: 12523


Re: OS Info Dump
« Reply #7 on: July 28, 2009, 04:36:57 PM »

ok - i updated the program so it displays the first 2 parts of "ProductId"
the last 2 parts are X'ed out to hide the product key information
as always, i included the program source

My OS: Windows XP (Pro) Media Center Edition 2005, sp2

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows XP"
"CurrentVersion"="5.1"
"CurrentBuildNumber"="2600"
"SubVersionNumber"=""
"CSDVersion"="Service Pack 2"
"BuildLab"="2600.xpsp_sp2_rtm.040803-2158"
"ProductId"="76487-OEM-XXXXXXX-XXXXX"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"="4.0"

http://www.masm32.com/board/index.php?action=dlattach;topic=11963.0;id=6522
Logged
fearless
Member
*****
Gender: Male
Posts: 226



Re: OS Info Dump
« Reply #8 on: July 28, 2009, 05:11:07 PM »

Yep, missed that in the reg, was looking at DigitalProductID by mistake. But you got the right one anyhows :D
Logged

ƒearless
bruce1948
Guest


Email
Re: OS Info Dump
« Reply #9 on: July 28, 2009, 06:51:38 PM »

Code:
DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows XP"
"CurrentVersion"="5.1"
"CurrentBuildNumber"="2600"
"SubVersionNumber"=""
"CSDVersion"="Service Pack 3"
"BuildLab"="2600.xpsp_sp3_gdr.090206-1234"
"ProductId"="76477-OEM-XXXXXXX-XXXXX"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Value not found)


Oriiginal install XP home SP2.
Logged
Slugsnack
Member
*****
Posts: 463


Re: OS Info Dump
« Reply #10 on: July 28, 2009, 07:58:32 PM »

MSDN server 2008 enterprise SP2 :

Code:
DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Windows Server (R) 2008 Enterprise"
"CurrentVersion"="6.0"
"CurrentBuildNumber"="6002"
"SubVersionNumber"=(Value not found)
"CSDVersion"="Service Pack 2"
"BuildLab"="6002.lh_sp2rtm.090410-1830"
"ProductId"="92516-082-XXXXXXX-XXXXX"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Value not found)

Press any key to exit
Logged
jj2007
Member
*****
Gender: Male
Posts: 6011



Re: OS Info Dump
« Reply #11 on: July 28, 2009, 09:47:21 PM »

XP Home SP2

Code:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows XP"
"CurrentVersion"="5.1"
"CurrentBuildNumber"="2600"
"SubVersionNumber"=""
"CSDVersion"="Service Pack 2"
"BuildLab"="2600.xpsp_sp2_gdr.070227-2254"
"ProductId"="76434-OEM-XXXXXXX-XXXXX"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Key not found)
Logged

FORTRANS
Member
*****
Gender: Male
Posts: 1147


Imagine


Re: OS Info Dump
« Reply #12 on: July 28, 2009, 10:25:21 PM »

Hi,

   Two older ones, Windows 2000 and 98 <g>.


DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Microsoft Windows 2000"
"CurrentVersion"="5.0"
"CurrentBuildNumber"="2195"
"SubVersionNumber"=(Value not found)
"CSDVersion"="Service Pack 4"
"BuildLab"=(Value not found)
"ProductId"="51873-OEM-XXXXXXX-XXXXX"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Key not found)

Press any key to exit

DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"=(Value not found)
"CurrentVersion"=(Value not found)
"CurrentBuildNumber"=(Value not found)
"SubVersionNumber"=(Value not found)
"CSDVersion"=(Value not found)
"BuildLab"=(Value not found)
"ProductId"=(Value not found)

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"=(Key not found)

Press any key to exit


Cheers,

Steve N.
Logged
dedndave
Member
*****
Posts: 12523


Re: OS Info Dump
« Reply #13 on: July 28, 2009, 11:02:16 PM »

uh oh - i am gonna hafta find something for win95/win98/win98se/winME
NT and OS2 are gonna be hard to ID also - lol
did anyone actually ever buy and use OS2 ?
Thank You, Everyone !   ThumbsUp
keep em coming, guys
Logged
GregL
Member
*****
Gender: Male
Posts: 1897



Re: OS Info Dump
« Reply #14 on: July 28, 2009, 11:08:32 PM »

Windows 7 Ultimate x64 (RC)

DednDave OS Info Dump

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion]
"ProductName"="Windows 7 Ultimate"
"CurrentVersion"="6.1"
"CurrentBuildNumber"="7100"
"SubVersionNumber"=(Value not found)
"CSDVersion"=(Value not found)
"BuildLab"="7100.winmain_win7rc.090421-1700"
"ProductId"=(Value not found)

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Media Center]
"Ident"="6.0"


ProductId actually does exist.


Logged
Pages: [1] 2 3 ... 6 Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP The MASM Forum Archive 2004 to 2012 | Powered by SMF 1.0.12.
© 2001-2005, Lewis Media. All Rights Reserved.
Valid XHTML 1.0! Valid CSS!