Function at 0x40b010
Capabilities:
Check os version
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4ce227
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x210
mov dword [ebp - 0x10], 0
mov eax, dword fs:[0x2c]
mov ecx, dword [0x501f90]
push esi
mov esi, dword [eax + ecx*4]
mov eax, dword [0x501d90]
cmp eax, dword [esi + 4]
jle 0x40b099
push 0x501d90
call fcn.004243f1
add esp, 4
cmp dword [0x501d90], 0xffffffff
jne 0x40b099
mov dword [ebp - 4], 1
mov ecx, 0x501d78
push 0x4d3608
call fcn.004037e0
push 0x4d1d90
call fcn.004242a8
mov byte [ebp - 4], 0
push 0x501d90
call fcn.004243b2
add esp, 8
cmp dword [0x501d88], 0
jbe 0x40b0e5
mov esi, dword [ebp + 8]
mov ecx, esi
push 0xffffffffffffffff
push 0
push 0x501d78
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], 0
mov byte [esi], 0
call fcn.00409200
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
mov eax, esi
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
mov eax, dword [0x501d98]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, dword [esi + 4]
jle 0x40b13f
push 0x501d98
call fcn.004243f1
add esp, 4
cmp dword [0x501d98], 0xffffffff
jne 0x40b13f
mov dword [ebp - 4], 2
push str.RtlGetVersion
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call edi
mov dword [0x501d94], eax
mov byte [ebp - 4], 0
push 0x501d98
call fcn.004243b2
add esp, 4
mov eax, dword [0x501da0]
cmp eax, dword [esi + 4]
jle 0x40b192
push 0x501da0
call fcn.004243f1
add esp, 4
cmp dword [0x501da0], 0xffffffff
jne 0x40b192
mov dword [ebp - 4], 3
push str.GetNativeSystemInfo
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call edi
mov dword [0x501d9c], eax
mov byte [ebp - 4], 0
push 0x501da0
call fcn.004243b2
add esp, 4
mov eax, dword [0x501da8]
cmp eax, dword [esi + 4]
jle 0x40b1e5
push 0x501da8
call fcn.004243f1
add esp, 4
cmp dword [0x501da8], 0xffffffff
jne 0x40b1e5
mov dword [ebp - 4], 4
push str.GetProductInfo
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call edi
mov dword [0x501da4], eax
mov byte [ebp - 4], 0
push 0x501da8
call fcn.004243b2
add esp, 4
push 0x11c
lea eax, [ebp - 0x204]
push 0
push eax
call fcn.0049edb0
mov eax, dword [0x501d94]
add esp, 0xc
mov dword [ebp - 0x204], 0x11c
pop edi
test eax, eax
je 0x40b270
lea ecx, [ebp - 0x204]
push ecx
call eax
mov esi, eax
test esi, esi
je 0x40b2ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push str.PERS
push str.__s__failed._RtlGetVersionStatus_:__d__d_
push 3
push 0xf6
call fcn.00423ab0
mov ecx, dword [ebp + 8]
add esp, 0x18
push 0x4d3608
call fcn.004037e0
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
mov eax, dword [ebp + 8]
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x204]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
jne 0x40b2ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.PERS
push str.__s__failed._OsVersionInfo_:__d
push 3
push 0x103
call fcn.00423ab0
mov ecx, dword [ebp + 8]
add esp, 0x14
push 0x4d3608
call fcn.004037e0
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 1
mov eax, dword [ebp + 8]
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
mov eax, dword [0x501d9c]
xorps xmm0, xmm0
mov dword [ebp - 0xc8], 0
movups xmmword [ebp - 0xe8], xmm0
movups xmmword [ebp - 0xd8], xmm0
test eax, eax
je 0x40b2fd
lea ecx, [ebp - 0xe8]
push ecx
call eax
jmp 0x40b30a
lea eax, [ebp - 0xe8]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
push 1
push 3
lea ecx, [ebp - 0xc4]
call fcn.00403930
mov dword [ebp - 4], 5
mov eax, dword [ebp - 0x1f8]
push eax
push str.PERS
push str.__s__SystemInformation_:__d
push 1
push 0x3d1
mov dword [0x501d48], eax
call fcn.00423ab0
mov esi, dword [ebp - 0x1f8]
add esp, 0x14
cmp dword [ebp - 0x200], 0
jne 0x40b3ae
test esi, esi
jne 0x40b3ae
cmp dword [ebp - 0x1fc], esi
jne 0x40b3ae
push str.PERS
push str.__s__failed._Get_System_Version_information
push 3
push 0x118
call fcn.00423ab0
mov ecx, dword [ebp + 8]
add esp, 0x10
push 0x4d3608
call fcn.004037e0
mov dword [ebp - 0x10], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xc4]
call fcn.00405010
mov eax, dword [ebp + 8]
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x1f4]
cmp ecx, 2
jne 0x40b8fb
mov eax, dword [ebp - 0x200]
cmp eax, 4
jbe 0x40b8fb
cmp eax, 6
jb 0x40b64e
cmp eax, 0xa
jne 0x40b4da
cmp dword [ebp - 0x1fc], 0
jne 0x40b586
cmp byte [ebp - 0xea], 1
jne 0x40b4d0
cmp esi, 0x2800
jb 0x40b468
cmp esi, 0x55f0
jae 0x40b470
lea eax, [ebp - 0xb4]
push str.Windows_10
push eax
call fcn.00402120
add esp, 8
cmp esi, 0x4a62
jne 0x40b42e
push str._20H2_
jmp 0x40b577
cmp esi, 0x4a63
jne 0x40b440
push str._21H1_
jmp 0x40b577
cmp esi, 0x4a64
jne 0x40b452
push str._21H2_
jmp 0x40b577
cmp esi, 0x4a65
jne 0x40b586
push str._22H2_
jmp 0x40b577
cmp esi, 0x55f0
jb 0x40b4c6
cmp esi, 0x5867
ja 0x40b4c6
lea eax, [ebp - 0xb4]
push str.Windows_11
push eax
call fcn.00402120
add esp, 8
cmp esi, 0x55f0
jne 0x40b49e
push str._21H2_
jmp 0x40b577
cmp esi, 0x585d
jne 0x40b4b0
push str._22H2_
jmp 0x40b577
cmp esi, 0x5867
jne 0x40b586
push str._22H3_
jmp 0x40b577
push str.Windows_11_or_Greater
jmp 0x40b577
push str.Windows_Server_2016
jmp 0x40b577
cmp dword [ebp - 0x200], 6
jne 0x40b586
cmp dword [ebp - 0x1fc], 3
jne 0x40b50d
cmp byte [ebp - 0xea], 1
lea eax, [ebp - 0xb4]
jne 0x40b506
push str.Windows_8.1
jmp 0x40b57d
push str.Windows_Server_2012_R2
jmp 0x40b57d
cmp dword [ebp - 0x1fc], 2
jne 0x40b533
cmp byte [ebp - 0xea], 1
lea eax, [ebp - 0xb4]
jne 0x40b52c
push str.Windows_8
jmp 0x40b57d
push str.Windows_Server_2012
jmp 0x40b57d
cmp dword [ebp - 0x1fc], 1
jne 0x40b559
cmp byte [ebp - 0xea], 1
lea eax, [ebp - 0xb4]
jne 0x40b552
push str.Windows_7
jmp 0x40b57d
push str.Windows_Server_2008_R2
jmp 0x40b57d
cmp dword [ebp - 0x1fc], 0
jne 0x40b586
cmp byte [ebp - 0xea], 1
jne 0x40b572
push str.Windows_Vista
jmp 0x40b577
push str.Windows_Server_2008
lea eax, [ebp - 0xb4]
push eax
call fcn.00402120
add esp, 8
mov eax, dword [0x501da4]
test eax, eax
je case.0x40b5c5.5
lea ecx, [ebp - 0x14]
push ecx
push 0
push 0
push dword [ebp - 0x1fc]
push dword [ebp - 0x200]
call eax
test eax, eax
je case.0x40b5c5.5
mov eax, dword [ebp - 0x14]
dec eax
cmp eax, 0x2f
ja case.0x40b5c5.5
movzx eax, byte [eax + 0x40b9bc]
jmp dword [eax*4 + 0x40b974]
push str._Ultimate_Edition
jmp 0x40b817
push str._Home_Premium_Edition
jmp 0x40b817
push str._Home_Basic_Edition
jmp 0x40b817
push str._Business_Edition
jmp 0x40b817
push str._Starter_Edition
jmp 0x40b817
push str._Cluster_Server_Edition
jmp 0x40b817
push str._Datacenter_Edition__core_installation_
jmp 0x40b817
push str._Enterprise_Edition__core_installation_
jmp 0x40b817
push str._Small_Business_Server
jmp 0x40b817
push str._Small_Business_Server_Premium_Edition
jmp 0x40b817
push str._Standard_Edition
jmp 0x40b817
push str._Standard_Edition__core_installation_
jmp 0x40b817
push str._Web_Server_Edition
jmp 0x40b817
cmp dword [ebp - 0x200], 5
jne case.0x40b5c5.5
cmp dword [ebp - 0x1fc], 2
jne 0x40b78c
push 0x59
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
je 0x40b67b
push str.Windows_Server_2003_R2_
jmp 0x40b6bc
mov eax, dword [ebp - 0xec]
test eax, 0x2000
je 0x40b68f
push str.Windows_Storage_Server_2003
jmp 0x40b6bc
test eax, 0x8000
je 0x40b69d
push str.Windows_Home_Server
jmp 0x40b6bc
cmp byte [ebp - 0xea], 1
jne 0x40b6b7
cmp word [ebp - 0xe8], 9
jne 0x40b6b7
push str.Windows_XP_Professional_x64_Edition
jmp 0x40b6bc
push str.Windows_Server_2003_
lea eax, [ebp - 0xb4]
push eax
call fcn.00402120
add esp, 8
cmp byte [ebp - 0xea], 1
je case.0x40b5c5.5
cmp word [ebp - 0xe8], 6
mov eax, dword [ebp - 0xec]
jne 0x40b708
test al, al
jns 0x40b6f6
push str._Datacenter_Edition_for_Itanium_based_Systems
jmp 0x40b817
test al, 2
je case.0x40b5c5.5
push str._Enterprise_Edition_for_Itanium_based_Systems
jmp 0x40b817
cmp word [ebp - 0xe8], 9
jne 0x40b73e
test al, al
jns 0x40b720
push str._Datacenter_x64_Edition
jmp 0x40b817
test al, 2
lea eax, [ebp - 0xb4]
je 0x40b734
push str._Enterprise_x64_Edition
jmp 0x40b81d
push str._Standard_x64_Edition
jmp 0x40b81d
test eax, 0x4000
je 0x40b74f
push str._Compute_Cluster_Edition
jmp 0x40b817
test al, al
jns 0x40b75d
push str._Datacenter_Edition
jmp 0x40b817
test al, 2
je 0x40b76b
push str._Enterprise_Edition
jmp 0x40b817
test eax, 0x400
lea eax, [ebp - 0xb4]
je 0x40b782
push str._Web_Edition
jmp 0x40b81d
push str._Standard_Edition
jmp 0x40b81d
cmp dword [ebp - 0x1fc], 1
jne 0x40b7c9
lea eax, [ebp - 0xb4]
push str.Windows_XP
push eax
call fcn.00402120
add esp, 8
lea eax, [ebp - 0xb4]
test dword [ebp - 0xec], 0x200
je 0x40b7c2
push str._Home_Edition
jmp 0x40b81d
push str._Professional
jmp 0x40b81d
cmp dword [ebp - 0x1fc], 0
jne case.0x40b5c5.5
lea eax, [ebp - 0xb4]
push str.Windows_2000
push eax
call fcn.00402120
add esp, 8
cmp byte [ebp - 0xea], 1
jne 0x40b7f6
push str._Professional
jmp 0x40b817
mov eax, dword [ebp - 0xec]
test al, al
jns 0x40b807
push str._Datacenter_Server
jmp 0x40b817
test al, 2
je 0x40b812
push str._Advanced_Server
jmp 0x40b817
push str._Server
lea eax, [ebp - 0xb4]
push eax
call fcn.00402120
add esp, 8
mov eax, dword [ebp - 0xf0]
test ax, ax
jne 0x40b83a
cmp word [ebp - 0xee], ax
je 0x40b856
push eax
lea eax, [ebp - 0xb4]
push 0x4d4080
push eax
call fcn.00402120
add esp, 8
mov ecx, eax
call fcn.00404df0
cmp dword [ebp - 0x200], 6
jb 0x40b895
cmp word [ebp - 0xe8], 9
jne 0x40b870
push str._64_bit
jmp 0x40b886
cmp word [ebp - 0xe8], 0
jne 0x40b881
push str._32_bit
jmp 0x40b886
push str._Architecture_Unknown_
lea eax, [ebp - 0xb4]
push eax
call fcn.00402120
add esp, 8
lea eax, [ebp - 0x21c]
push eax
lea ecx, [ebp - 0xc4]
call fcn.0040cbe0
mov byte [ebp - 4], 7
mov ecx, 0x501d78
push eax
call fcn.00404d10
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x21c]
call fcn.00404470
mov esi, dword [ebp + 8]
lea ecx, [ebp - 0xc4]
push esi
call fcn.0040cbe0
mov dword [ebp - 0x10], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xc4]
call fcn.00405010
mov eax, esi
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x200]
push ecx
push str.PERS
push str.__s__failed._PlatformId_:__d___MajorVersion_:__d
push 3
push 0x11d
call fcn.00423ab0
mov ecx, dword [ebp + 8]
add esp, 0x18
push 0x4d3608
call fcn.004037e0
mov dword [ebp - 0x10], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x5c]
call fcn.004045d0
lea eax, [ebp - 0x5c]
mov dword [ebp - 0x5c], vtable.std::basic_ios_char__struct_std::char_traits_char__.0
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 0
push eax
mov dword [ebp - 0x5c], vtable.std::ios_base.0
call fcn.00425d33
mov eax, dword [ebp + 8]
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop esi
mov esp, ebp
pop ebp
ret