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

Disassembly:
push 0x154
mov eax, 0x5b52de
call fcn.0058eb04
xor ebx, ebx
cmp dword [0x624264], ebx
je 0x516582
xor eax, eax
inc eax
call fcn.0058eb4e
ret
mov esi, 0x11c
push esi
lea eax, [ebp - 0x130]
push ebx
push eax
call fcn.0058e300
add esp, 0xc
lea eax, [ebp - 0x134]
push 0x5caac4
push eax
mov dword [ebp - 0x130], esi
mov dword [ebp - 0x138], ebx
call fcn.00516143
pop ecx
pop ecx
mov dword [ebp - 4], ebx
mov esi, dword [ebp - 0x134]
cmp dword [0x618690], ebx
jne 0x5165fe
mov edi, 0x618678
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [0x618690], ebx
jne 0x5165f7
push 0x618268
mov ecx, esi
call fcn.004065f0
mov dword [0x618694], eax
mov dword [0x618690], 1
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [0x618694], ebx
je 0x51661b
lea ecx, [ebp - 0x138]
lea edx, [ebp - 0x130]
call fcn.00402e00
test eax, eax
jne 0x516668
push str.RtlGetVersion
push str.NtDll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x516668
lea ecx, [ebp - 0x130]
push ecx
call eax
test eax, eax
je 0x516668
lea eax, [ebp - 0x130]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
jne 0x516668
xor esi, esi
lea ecx, [ebp - 0x134]
call fcn.004066e0
mov eax, esi
jmp 0x51657c
mov esi, 0x5caac0
mov edx, esi
mov edi, 0x623ce0
mov dword [0x6230c0], ebx
call fcn.00406be0
mov eax, dword [ebp - 0x120]
sub eax, ebx
je 0x51681e
dec eax
je 0x5167d9
dec eax
je 0x51669e
mov edx, esi
jmp 0x51682d
mov eax, dword [ebp - 0x12c]
cmp eax, 4
ja 0x5166bd
mov dword [0x6230c0], 0x40
mov edx, str.Windows_NT
jmp 0x51682d
cmp eax, 5
jne 0x51671c
cmp dword [ebp - 0x128], ebx
jne 0x5166de
mov dword [0x6230c0], 0x80
mov edx, str.Windows_2000
jmp 0x51682d
cmp dword [ebp - 0x128], 1
jne 0x5166fb
mov dword [0x6230c0], 0x100
mov edx, str.Windows_XP
jmp 0x51682d
cmp dword [ebp - 0x128], 2
jne 0x516832
mov dword [0x6230c0], 0x200
mov edx, str.Windows_2003
jmp 0x51682d
cmp eax, 6
jne 0x5167cc
mov eax, dword [ebp - 0x128]
cmp eax, ebx
jne 0x516743
mov dword [0x6230c0], 0x400
mov edx, str.Windows_Vista
jmp 0x51682d
cmp eax, 1
jne 0x51675c
mov dword [0x6230c0], 0x800
mov edx, str.Windows_7
jmp 0x51682d
cmp eax, 2
jne 0x516775
mov dword [0x6230c0], 0x1000
mov edx, str.Windows_8
jmp 0x51682d
cmp eax, 3
jne 0x51678e
mov dword [0x6230c0], 0x2000
mov edx, str.Windows_8.1
jmp 0x51682d
cmp eax, 4
jne 0x516832
cmp dword [ebp - 0x124], 0x2671
je 0x5167bb
cmp dword [ebp - 0x124], 0x2684
je 0x5167bb
cmp dword [ebp - 0x124], 0x2697
jne 0x516832
mov dword [0x6230c0], 0x4000
mov edx, str.Windows_10
jmp 0x51682d
cmp eax, 0xa
jne 0x516832
cmp dword [ebp - 0x128], ebx
jmp 0x5167b9
cmp dword [ebp - 0x12c], 4
jne 0x516832
cmp dword [ebp - 0x128], ebx
jne 0x5167fb
mov dword [0x6230c0], 8
mov edx, str.Windows_9x
jmp 0x51682d
cmp dword [ebp - 0x128], 0xa
je 0x5167ea
cmp dword [ebp - 0x128], 0x5a
jne 0x516832
mov dword [0x6230c0], 0x20
mov edx, str.Windows_ME
jmp 0x51682d
mov dword [0x6230c0], 1
mov edx, str.Windows_3.2
call fcn.00406be0
push 9
pop ecx
push 0x5cb174
xor eax, eax
lea edi, [ebp - 0x15c]
push str.kernel32.dll
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x516865
lea ecx, [ebp - 0x15c]
push ecx
call eax
jmp 0x516872
lea eax, [ebp - 0x15c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
cmp word [ebp - 0x15c], 9
je 0x516897
cmp word [ebp - 0x15c], 6
je 0x516897
cmp word [ebp - 0x15c], bx
jne 0x5168a1
mov dword [0x6230c4], ebx
jmp 0x5168a1
mov dword [0x6230c4], 1
xor esi, esi
inc esi
mov dword [0x624264], esi
jmp 0x516656