Function at 0x5593b0
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57e05d
mov eax, dword fs:[0]
push eax
sub esp, 0x170
mov eax, dword [0x5f4e20]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
lea ecx, [ebp - 0x160]
mov dword [ebp - 0x17c], edi
mov dword [ebp - 0x174], 0
call fcn.005587a0
mov dword [ebp - 4], 1
push 0x11c
lea eax, [ebp - 0x12c]
push 0
push eax
mov dword [ebp - 0x160], 0
call fcn.0053af40
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExW]
add esp, 0xc
lea eax, [ebp - 0x12c]
push eax
mov dword [ebp - 0x12c], 0x11c
call esi
test eax, eax
setne bh
mov byte [ebp - 0x12d], bh
test bh, bh
jne 0x5594c2
lea eax, [ebp - 0x12c]
push eax
mov dword [ebp - 0x12c], 0x114
call esi
test eax, eax
jne 0x5594c2
push str._PSMisc::GetOSString_
lea eax, [ebp - 0x16c]
push eax
call fcn.00559120
mov byte [ebp - 4], 2
push dword [eax]
push 0x585068
push 0x10000
call fcn.0055b110
add esp, 0xc
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x16c]
add edx, 0xfffffff0
or ecx, 0xffffffff
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x5594af
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x160]
push eax
mov ecx, edi
call fcn.005586e0
jmp 0x559e9c
movzx eax, word [ebp - 0x120]
mov dword [ebp - 0x140], eax
mov eax, dword [ebp - 0x128]
mov dword [ebp - 0x148], eax
mov eax, dword [ebp - 0x124]
push 0
push 0x583ea8
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x144], eax
call fcn.004015a0
lea ecx, [ebp - 0x150]
push 0
push 0x583ea8
call fcn.004015a0
mov eax, dword [ebp - 0x11c]
mov byte [ebp - 0x154], 0
mov esi, 0xffffffff
dec eax
je 0x559b1e
dec eax
je 0x559536
mov dword [ebp - 0x160], 0
jmp 0x559cb5
mov edx, dword [ebp - 0x128]
cmp edx, 4
ja 0x55954b
mov eax, 4
jmp 0x5598b7
cmp edx, 5
jne 0x5595ee
cmp dword [ebp - 0x124], 0
jne 0x55956a
mov eax, edx
mov dword [ebp - 0x160], eax
jmp 0x5598c6
cmp dword [ebp - 0x124], 1
jne 0x559583
mov eax, 6
mov dword [ebp - 0x160], eax
jmp 0x5598c6
cmp dword [ebp - 0x124], 2
jne 0x5598b5
mov ecx, dword [ebp - 0x14]
mov bl, byte [ebp - 0x12]
test ecx, 0x200
jne 0x5595de
cmp bl, 1
je 0x5595de
push 0x59
mov dword [ebp - 0x160], 7
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
je 0x5598a7
push 0x5bb344
lea ecx, [ebp - 0x14c]
call fcn.00401110
mov eax, dword [ebp - 0x160]
mov edx, dword [ebp - 0x128]
jmp 0x5598bd
mov eax, 6
mov dword [ebp - 0x160], eax
jmp 0x5598cc
cmp edx, 6
jb 0x5598b5
xor eax, eax
cmp byte [ebp - 0x12], 1
mov dword [ebp - 0x134], 0
setne al
add eax, 9
mov dword [ebp - 0x160], eax
lea eax, [ebp - 0x134]
push eax
push 0x64
push 0
call sub.NETAPI32.dll_NetWkstaGetInfo
test eax, eax
jne 0x559641
mov eax, dword [ebp - 0x134]
mov ecx, dword [eax + 0xc]
mov dword [ebp - 0x128], ecx
mov eax, dword [eax + 0x10]
mov dword [ebp - 0x124], eax
jmp 0x55964d
mov eax, dword [ebp - 0x124]
mov ecx, dword [ebp - 0x128]
cmp ecx, 0xa
jb 0x559660
xor eax, eax
cmp byte [ebp - 0x12], 1
setne al
add eax, 0x11
jmp 0x5596a7
test eax, eax
jne 0x559670
cmp byte [ebp - 0x12], 1
setne al
add eax, 9
jmp 0x5596a7
cmp eax, 1
jne 0x559683
xor eax, eax
cmp byte [ebp - 0x12], 1
setne al
add eax, 0xb
jmp 0x5596a7
cmp eax, 2
jne 0x559696
xor eax, eax
cmp byte [ebp - 0x12], 1
setne al
add eax, 0xf
jmp 0x5596a7
cmp eax, 3
jne 0x5596ad
xor eax, eax
cmp byte [ebp - 0x12], 1
setne al
add eax, 0xd
mov dword [ebp - 0x160], eax
mov dword [ebp - 0x158], 0x11
mov dword [ebp - 0x16c], 0
mov dword [ebp - 0x168], 0
mov dword [ebp - 0x164], 0
mov byte [ebp - 4], 5
push 0
push 0x58a3ac
lea ecx, [ebp - 0x168]
call fcn.00562550
test al, al
je 0x559856
lea eax, [ebp - 0x170]
push eax
push str.GetProductInfo
lea ecx, [ebp - 0x168]
call fcn.00562510
test al, al
je 0x559856
lea eax, [ebp - 0x16c]
push eax
movzx eax, word [ebp - 0x16]
push eax
movzx eax, word [ebp - 0x18]
push eax
push dword [ebp - 0x124]
push dword [ebp - 0x128]
call dword [ebp - 0x170]
test eax, eax
je 0x559856
mov eax, dword [ebp - 0x16c]
cmp eax, 0x29
ja case.0x559753.0
movzx eax, byte [eax + 0x559f28]
jmp dword [eax*4 + 0x559ed8]
mov dword [ebp - 0x158], 0
jmp 0x559898
mov dword [ebp - 0x158], 1
jmp 0x559898
mov dword [ebp - 0x158], 2
jmp 0x559898
mov dword [ebp - 0x158], 3
jmp 0x559898
mov dword [ebp - 0x158], 4
jmp 0x559898
mov dword [ebp - 0x158], 5
jmp 0x559898
mov dword [ebp - 0x158], 6
jmp 0x559898
mov dword [ebp - 0x158], 7
jmp 0x559898
mov dword [ebp - 0x158], 8
jmp 0x559898
mov dword [ebp - 0x158], 9
jmp 0x559898
mov dword [ebp - 0x158], 0x12
jmp 0x559898
mov dword [ebp - 0x158], 0xa
jmp 0x559898
mov dword [ebp - 0x158], 0xb
jmp 0x559898
mov dword [ebp - 0x158], 0xc
jmp 0x559898
mov dword [ebp - 0x158], 0xd
jmp 0x559898
mov dword [ebp - 0x158], 0xe
jmp 0x559898
mov dword [ebp - 0x158], 0xf
jmp 0x559898
mov dword [ebp - 0x158], 0x10
jmp 0x559898
push str._PSMisc::GetPlatform_
lea eax, [ebp - 0x178]
push eax
call fcn.00559120
mov byte [ebp - 4], 6
push dword [eax]
push 0x585068
push 0x10000
call fcn.0055b110
add esp, 0xc
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x178]
call fcn.004010f0
mov dword [ebp - 0x158], 0x11
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x168]
call fcn.005624c0
mov eax, dword [ebp - 0x160]
mov edx, dword [ebp - 0x128]
jmp 0x5598bd
xor eax, eax
mov dword [ebp - 0x160], eax
cmp edx, 5
jb 0x559a41
mov bl, byte [ebp - 0x12]
mov ecx, dword [ebp - 0x14]
test bh, bh
je 0x559a41
mov bh, 1
cmp bl, bh
jne 0x559902
cmp eax, 9
jne 0x5598e9
push str.Client
jmp 0x5599d5
test ecx, 0x200
mov eax, str.Home
mov ecx, str.Professional
cmove eax, ecx
push eax
jmp 0x5599d5
cmp bl, 3
je 0x559910
cmp bl, 2
jne 0x5599e0
mov byte [ebp - 0x154], 1
cmp eax, 9
jne 0x559926
push str.Server
jmp 0x5599d5
cmp eax, 7
je 0x5599aa
cmp eax, 0xa
je 0x5599aa
cmp eax, 0xc
je 0x5599aa
test cl, 2
je 0x559962
cmp edx, 5
jne 0x55994d
cmp dword [ebp - 0x124], 0
mov eax, str.Advanced_Server
je 0x559952
mov eax, str.Enterprise_Server
push eax
lea ecx, [ebp - 0x150]
call fcn.00401110
xor bh, bh
jmp 0x5599e0
test cl, cl
jns 0x55997a
push str.DataCenter_Server
lea ecx, [ebp - 0x150]
call fcn.00401110
xor bh, bh
jmp 0x5599e0
test ecx, 0x400
je 0x559996
push str.Web_Server
lea ecx, [ebp - 0x150]
call fcn.00401110
xor bh, bh
jmp 0x5599e0
push str.Server
lea ecx, [ebp - 0x150]
call fcn.00401110
xor bh, bh
jmp 0x5599e0
test cl, 2
je 0x5599b6
push str.Enterprise
jmp 0x5599d5
test cl, cl
jns 0x5599c1
push str.Datacenter
jmp 0x5599d5
test ecx, 0x400
je 0x5599d0
push 0x5bb404
jmp 0x5599d5
push str.Standard
lea ecx, [ebp - 0x150]
call fcn.00401110
call fcn.0055a580
test al, al
je 0x5599f9
push str._x64
lea ecx, [ebp - 0x150]
call fcn.00414afe
test bh, bh
je 0x559a0d
push str._Edition
lea ecx, [ebp - 0x150]
call fcn.00414afe
mov bh, byte [ebp - 0x12d]
lea ecx, [ebp - 0x118]
lea edx, [ecx + 2]
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x559a20
sub ecx, edx
sar ecx, 1
je 0x559cb5
lea eax, [ebp - 0x118]
push eax
jmp 0x559caa
mov dword [ebp - 0x168], 0
mov dword [ebp - 0x164], 0
mov byte [ebp - 4], 8
lea ecx, [ebp - 0x134]
call fcn.00401b20
mov byte [ebp - 4], 9
push 0x20019
push reloc.OLEAUT32.dll_SysReAllocString
push str.SystemCurrentControlSetControlProductOptions
lea ecx, [ebp - 0x168]
call fcn.0055c090
test al, al
je 0x559ae7
lea eax, [ebp - 0x134]
push eax
push str.ProductType
lea ecx, [ebp - 0x168]
call fcn.0055bf20
test al, al
je 0x559ae7
push str.WinNT
lea ecx, [ebp - 0x134]
call fcn.0040d6b0
test eax, eax
jne 0x559abc
push str.Workstation
jmp 0x559adc
push str.ServerNT
lea ecx, [ebp - 0x134]
call fcn.0040d6b0
test eax, eax
jne 0x559ae7
mov byte [ebp - 0x154], 1
push str.Server
lea ecx, [ebp - 0x150]
call fcn.00401110
mov byte [ebp - 4], 8
mov edx, dword [ebp - 0x134]
add edx, 0xfffffff0
mov ecx, esi
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x559b0a
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x168]
call fcn.0055be30
jmp 0x559a13
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0
jne 0x559b67
cmp dword [ebp - 0x140], 0x3b6
jne 0x559b67
push 0x583ea8
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 1
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
mov eax, dword [ebp - 0x140]
add eax, 0xfffffc49
cmp eax, 0x81
ja 0x559ba0
push 0x5bb570
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 1
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0xa
jae 0x559be3
cmp dword [ebp - 0x140], 0x438
jbe 0x559bdc
push str.OSR2
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 1
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0xa
jne 0x559c92
cmp dword [ebp - 0x140], 0x7ce
jne 0x559c25
push 0x583ea8
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 2
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0xa
jne 0x559c92
mov eax, dword [ebp - 0x140]
add eax, 0xfffff831
cmp eax, 0xb7
ja 0x559c63
push 0x5bb570
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 2
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0xa
jne 0x559c92
cmp dword [ebp - 0x140], 0x887
jb 0x559cb5
push 0x5bb584
lea ecx, [ebp - 0x14c]
mov dword [ebp - 0x160], 2
call fcn.00401110
cmp dword [ebp - 0x148], 4
jne 0x559cb5
cmp dword [ebp - 0x144], 0x5a
jne 0x559cb5
mov dword [ebp - 0x160], 3
push 0x583ea8
lea ecx, [ebp - 0x14c]
call fcn.00401110
push dword [ebp - 0x160]
call fcn.00559350
mov dword [ebp - 0x15c], eax
test bh, bh
je 0x559db8
movzx eax, word [ebp - 0x18]
mov dword [ebp - 0x13c], eax
movzx eax, word [ebp - 0x16]
mov dword [ebp - 0x138], eax
mov dword [ebp - 0x168], 0
mov dword [ebp - 0x164], 0
mov byte [ebp - 4], 0xc
call fcn.004157d7
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x559d16
push 0x80004005
call fcn.00401220
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x134], eax
mov byte [ebp - 4], 0xe
push 0x20019
push reloc.OLEAUT32.dll_SysReAllocString
push str.SOFTWAREMicrosoftWindows_NTCurrentVersion
lea ecx, [ebp - 0x168]
call fcn.0055c090
test al, al
je 0x559d88
lea eax, [ebp - 0x134]
push eax
push str.SubVersionNumber
lea ecx, [ebp - 0x168]
call fcn.0055bf20
test al, al
je 0x559d88
mov eax, dword [ebp - 0x134]
mov ecx, dword [eax - 0xc]
test ecx, ecx
je 0x559d88
jns 0x559d7c
push 0x80070057
call fcn.00401220
movzx eax, word [eax]
sub eax, 0x60
mov dword [ebp - 0x138], eax
mov byte [ebp - 4], 0xc
mov edx, dword [ebp - 0x134]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], esi
dec esi
test esi, esi
jg 0x559da9
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x168]
call fcn.0055be30
cmp dword [ebp - 0x160], 4
jne 0x559e8e
lea ecx, [ebp - 0x118]
lea edx, [ecx + 2]
mov edi, edi
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x559dd0
sub ecx, edx
sar ecx, 1
je 0x559e2d
xor esi, esi
cmp word [ebp - 0x118], si
je 0x559e13
lea eax, [ebp - 0x118]
movzx eax, word [eax]
push eax
call fcn.0053b10a
add esp, 4
test eax, eax
jne 0x559e13
inc esi
lea eax, [ebp - 0x118]
cmp word [eax + esi*2], 0
lea eax, [eax + esi*2]
jne 0x559df2
lea eax, [ebp - 0x118]
lea eax, [eax + esi*2]
push eax
call fcn.0053b07e
add esp, 4
mov dword [ebp - 0x13c], eax
jmp 0x559e33
mov eax, dword [ebp - 0x13c]
cmp eax, 6
jne 0x559e8e
mov dword [ebp - 0x168], 0
mov dword [ebp - 0x164], 0
mov byte [ebp - 4], 0x11
push 0x20019
push reloc.OLEAUT32.dll_SysReAllocString
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionHotfixQ246009
lea ecx, [ebp - 0x168]
call fcn.0055c090
mov ecx, dword [ebp - 0x138]
mov edx, 1
test al, al
cmovne ecx, edx
mov dword [ebp - 0x138], ecx
mov byte [ebp - 4], dl
lea ecx, [ebp - 0x168]
call fcn.0055be30
lea eax, [ebp - 0x160]
push eax
mov ecx, edi
call fcn.005586e0
mov dword [ebp - 0x174], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x160]
call fcn.0040d4a0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00539682
mov esp, ebp
pop ebp
ret 4