Function at 0x721f57
Capabilities:
Check os version
Query or enumerate registry value

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0xf8
push esi
push edi
mov esi, eax
mov byte [ebp + 0x77], 0
call fcn.00721f20
mov edi, 0x9c
push edi
lea eax, [ebp - 0x30]
push 0
push eax
call fcn.004d4a00
add esp, 0xc
lea eax, [ebp - 0x30]
mov dword [ebp - 0x30], edi
mov edi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
push eax
call edi
test eax, eax
jne 0x721fb2
lea eax, [ebp - 0x30]
push eax
mov dword [ebp - 0x30], 0x94
call edi
test eax, eax
jne 0x721fb6
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x7221f2
mov byte [ebp + 0x77], 1
mov eax, dword [ebp - 0x2c]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x28]
mov dword [esi + 8], eax
movzx eax, word [ebp + 0x68]
mov dword [esi + 0xc], eax
movzx eax, word [ebp + 0x64]
mov dword [esi + 0x20], eax
movzx eax, word [ebp - 0x24]
mov dword [esi + 0x14], eax
push ebx
lea eax, [ebp - 0x1c]
push eax
lea edi, [esi + 0x24]
xor ebx, ebx
mov eax, 0x80
call fcn.0040e8c7
mov eax, dword [ebp - 0x20]
sub eax, ebx
pop ecx
je 0x722178
dec eax
je 0x722136
dec eax
jne 0x72217e
mov eax, dword [ebp - 0x2c]
push 2
pop ebx
mov dword [esi], ebx
cmp eax, 3
jne 0x722025
cmp dword [ebp - 0x28], 0x33
jne 0x7220a1
mov dword [esi + 0x1c], 5
jmp 0x7220a1
cmp eax, 4
jne 0x722033
mov dword [esi + 0x1c], 6
jmp 0x7220a1
cmp eax, 5
jne 0x722064
cmp dword [ebp - 0x28], 0
jne 0x722047
mov dword [esi + 0x1c], 7
jmp 0x7220a1
cmp dword [ebp - 0x28], 1
jne 0x722056
mov dword [esi + 0x1c], 8
jmp 0x7220a1
cmp dword [ebp - 0x28], ebx
jne 0x7220a1
mov dword [esi + 0x1c], 9
jmp 0x7220a1
cmp eax, 6
jne 0x722095
cmp dword [ebp - 0x28], 0
jne 0x722078
mov dword [esi + 0x1c], 0xa
jmp 0x7220a1
cmp dword [ebp - 0x28], 1
jne 0x722087
mov dword [esi + 0x1c], 0xb
jmp 0x7220a1
cmp dword [ebp - 0x28], ebx
jb 0x7220a1
mov dword [esi + 0x1c], 0xc
jmp 0x7220a1
cmp eax, 0xa
jne 0x7220a1
mov dword [esi + 0x1c], 0xd
cmp byte [ebp + 0x77], 0
je 0x7220ba
cmp byte [ebp + 0x6a], 1
jne 0x7220b4
mov dword [esi + 0x10], 1
cmp byte [ebp + 0x6a], 3
jmp 0x72212f
call fcn.004cd46c
neg eax
sbb eax, eax
and eax, 0x100
lea ecx, [ebp + 0x70]
push ecx
inc eax
push eax
xor edi, edi
push edi
push str.SYSTEMCurrentControlSetControlProductOptions
push reloc.WSOCK32.dll_bind
mov byte [ebp - 0x80], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [ebp + 0x6c]
push eax
lea eax, [ebp - 0x80]
push eax
push edi
push edi
push str.ProductType
push dword [ebp + 0x70]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp + 0x70]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcmpiA]
lea eax, [ebp - 0x80]
push eax
push str.WINNT
call edi
test eax, eax
jne 0x722122
mov dword [esi + 0x10], 1
lea eax, [ebp - 0x80]
push eax
push str.SERVERNT
call edi
test eax, eax
jne 0x72217e
mov dword [esi + 0x10], ebx
jmp 0x72217e
push 2
pop ebx
xor eax, eax
push 4
inc eax
pop ecx
mov dword [esi], eax
cmp dword [ebp - 0x2c], ecx
jbe 0x722149
mov dword [esi + 0x1c], ebx
jne 0x722173
mov edx, dword [ebp - 0x28]
cmp edx, 0x5a
jb 0x722158
mov dword [esi + 0x1c], ecx
jmp 0x72217e
dec edx
cmp edx, 0x58
ja 0x722173
cmp dword [esi + 0x14], 0x8ae
mov dword [esi + 0x1c], ebx
jne 0x72217e
mov dword [esi + 0x1c], 3
jmp 0x72217e
mov dword [esi + 0x1c], eax
jmp 0x72217e
mov dword [esi], 3
call fcn.004cd46c
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
neg eax
sbb eax, eax
and eax, 0x20
add eax, 0x20
push 0x57
mov dword [esi + 0x18], eax
call edi
pop ebx
test eax, eax
je 0x7221a6
or dword [esi + 0xc], 0x80000000
push 0x56
call edi
test eax, eax
je 0x7221b5
or dword [esi + 0xc], 0x40000000
push str.GetProductInfo
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x7221f0
lea ecx, [ebp + 0x70]
push ecx
movzx ecx, word [ebp + 0x66]
push ecx
movzx ecx, word [ebp + 0x64]
push ecx
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
call eax
test eax, eax
je 0x7221f0
mov eax, dword [ebp + 0x70]
mov dword [esi + 0x10], eax
xor eax, eax
pop edi
pop esi
add ebp, 0x78
leave
ret