Function at 0x58c040
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffee4
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x11c], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00405f18
mov eax, dword [ebp - 8]
call fcn.00405f18
mov eax, dword [ebp - 0xc]
call fcn.00405f18
xor eax, eax
push ebp
push 0x58c419
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0xc4], 0x94
lea eax, [ebp - 0xc4]
push eax
call sub.kernel32.dll_GetVersionExA
cmp dword [ebp - 0xc0], 6
jae 0x58c0cf
mov eax, dword [ebp - 4]
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 0xc]
push eax
movzx eax, byte [ebp + 0xc]
push eax
mov eax, dword [ebp + 8]
push eax
xor ecx, ecx
xor edx, edx
xor eax, eax
call fcn.0058c78c
mov ebx, eax
jmp 0x58c3f3
push 0
push 0x58c42c
call sub.user32.dll_FindWindowA
test eax, eax
je 0x58c0f4
lea edx, [ebp - 0x1c]
push edx
push eax
call sub.user32.dll_GetWindowThreadProcessId
lea edx, [ebp - 0x20]
mov eax, dword [ebp - 0x1c]
call fcn.0058bf48
call sub.kernel32.dll_GetCurrentProcessId
lea edx, [ebp - 0x18]
call fcn.0058bf48
cmp dword [ebp - 0x18], 0x3000
jne 0x58c3d1
cmp dword [ebp - 0x20], 0x2000
jne 0x58c3d1
call fcn.0058bacc
test al, al
je 0x58c3d1
mov eax, dword [ebp - 0x1c]
push eax
push 0
push 0x1f0fff
call sub.kernel32.dll_OpenProcess
mov esi, eax
test esi, esi
je 0x58c3ca
lea eax, [ebp - 0x24]
push eax
push 0x2001e
push esi
call sub.advapi32.dll_OpenProcessToken
test eax, eax
je 0x58c3bd
push 2
push 1
lea eax, [ebp - 0x28]
push eax
xor ecx, ecx
mov edx, 0x2000000
mov eax, dword [ebp - 0x24]
call fcn.0058ba4c
test eax, eax
je 0x58c3ad
mov eax, dword [ebp - 0x28]
call fcn.0058bbbc
test al, al
je 0x58c39d
push 0x58c434
call sub.kernel32.dll_LoadLibraryA
mov edi, eax
push 0x58c444
push edi
call sub.kernel32.dll_GetProcAddress_1
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
je 0x58c395
lea eax, [ebp - 0x10]
call fcn.00405a98
jmp 0x58c233
mov edx, dword [ebp - 0xc]
mov eax, 0x58c464
call fcn.0041038c
mov ebx, eax
test ebx, ebx
jne 0x58c1d6
lea eax, [ebp - 0x14]
mov edx, dword [ebp - 0xc]
call fcn.00405b30
jmp 0x58c1ea
lea eax, [ebp - 0x14]
push eax
mov ecx, ebx
dec ecx
mov edx, 1
mov eax, dword [ebp - 0xc]
call fcn.00405f90
test ebx, ebx
je 0x58c200
lea ecx, [ebx + 1]
lea eax, [ebp - 0xc]
mov edx, 1
call fcn.00405fd0
jmp 0x58c208
lea eax, [ebp - 0xc]
call fcn.00405a98
cmp dword [ebp - 0x10], 0
jne 0x58c21b
lea eax, [ebp - 0x10]
mov edx, dword [ebp - 0x14]
call fcn.00405b30
jmp 0x58c233
push dword [ebp - 0x10]
push 0x58c470
push dword [ebp - 0x14]
lea eax, [ebp - 0x10]
mov edx, 3
call fcn.00405e2c
mov eax, dword [ebp - 0xc]
call fcn.00405d58
test eax, eax
jne 0x58c1b6
cmp dword [ebp - 0x10], 0
je 0x58c262
lea eax, [ebp - 0x10]
mov edx, 0x58c47c
call fcn.00405d64
mov eax, dword [ebp - 0x10]
call fcn.00405f28
mov ebx, eax
jmp 0x58c264
xor ebx, ebx
lea eax, [ebp - 0x108]
xor ecx, ecx
mov edx, 0x44
call fcn.00403d74
mov dword [ebp - 0x108], 0x44
mov dword [ebp - 0xdc], 1
mov word [ebp - 0xd8], 1
mov eax, dword [ebp + 8]
cmp eax, 4
ja case.default.0x58c29b
jmp dword [eax*4 + 0x58c2a2]
mov word [ebp - 0xd8], 5
jmp case.default.0x58c29b
mov word [ebp - 0xd8], 0
jmp case.default.0x58c29b
mov word [ebp - 0xd8], 3
jmp case.default.0x58c29b
mov word [ebp - 0xd8], 2
jmp case.default.0x58c29b
mov word [ebp - 0xd8], 7
lea eax, [ebp - 0x118]
xor ecx, ecx
mov edx, 0x10
call fcn.00403d74
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x108]
push eax
push 0
push ebx
push 0x10
lea eax, [ebp - 0x11c]
mov edx, dword [ebp - 4]
call fcn.00406438
mov eax, dword [ebp - 0x11c]
call fcn.00406448
push eax
push 0
push 0
mov eax, dword [ebp - 0x28]
push eax
call dword [ebp - 0x2c]
test eax, eax
jne 0x58c340
mov ebx, 0xfffffff5
jmp 0x58c37d
cmp byte [ebp + 0xc], 0
je 0x58c36a
mov eax, dword [0x5d5d78]
mov eax, dword [eax]
call fcn.00485f60
push 0x3e8
mov eax, dword [ebp - 0x118]
push eax
call sub.kernel32.dll_WaitForSingleObject
cmp eax, 0x102
je 0x58c346
lea eax, [ebp - 0x30]
push eax
mov eax, dword [ebp - 0x118]
push eax
call sub.kernel32.dll_GetExitCodeProcess
mov ebx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x114]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [ebp - 0x118]
push eax
call sub.kernel32.dll_CloseHandle_1
push edi
call sub.kernel32.dll_FreeLibrary_1
jmp 0x58c3a2
mov ebx, 0xfffffff6
mov eax, dword [ebp - 0x28]
push eax
call sub.kernel32.dll_CloseHandle_1
jmp 0x58c3b2
mov ebx, 0xfffffff7
mov eax, dword [ebp - 0x24]
push eax
call sub.kernel32.dll_CloseHandle_1
jmp 0x58c3c2
mov ebx, 0xfffffff8
push esi
call sub.kernel32.dll_CloseHandle_1
jmp 0x58c3f3
mov ebx, 0xfffffff9
jmp 0x58c3f3
mov eax, dword [ebp - 4]
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 0xc]
push eax
movzx eax, byte [ebp + 0xc]
push eax
mov eax, dword [ebp + 8]
push eax
xor ecx, ecx
xor edx, edx
xor eax, eax
call fcn.0058c78c
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x58c420
lea eax, [ebp - 0x11c]
call fcn.004062a0
lea eax, [ebp - 0x14]
mov edx, 5
call fcn.00405abc
ret