Function at 0x51c890
Capabilities:
Create thread
Get system information on windows
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x54
mov ecx, dword [0x55cdf8]
push ebx
mov ebx, dword [esp + 0x64]
lea eax, [ebx + ebx]
push ebp
mov dword [esp + 0x1c], eax
or eax, 0xffffffff
cmp ecx, eax
push esi
push edi
jne 0x51c8bc
movzx ecx, byte [0x560b9c]
mov dword [0x55cdf8], ecx
cmp dword [0x55cdfc], eax
jne 0x51c8d8
lea edx, [esp + 0x40]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [esp + 0x54]
mov dword [0x55cdfc], eax
mov eax, dword [esp + 0x68]
mov ebp, dword [esp + 0x6c]
mov esi, dword [eax]
mov edi, dword [ebp]
cmp esi, edi
je 0x51c900
mov ecx, ebx
imul ecx, dword [esp + 0x7c]
shl ecx, 1
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [eax + 4]
mov edi, dword [ebp + 4]
cmp esi, edi
je 0x51c92e
mov eax, dword [esp + 0x7c]
cdq
sub eax, edx
mov ecx, eax
sar ecx, 1
imul ecx, dword [esp + 0x74]
shl ecx, 1
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [esp + 0x68]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [eax + 8]
mov edi, dword [ebp + 8]
cmp esi, edi
je 0x51c958
mov eax, dword [esp + 0x7c]
cdq
sub eax, edx
mov ecx, eax
sar ecx, 1
imul ecx, dword [esp + 0x74]
shl ecx, 1
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x78]
mov eax, ecx
cdq
and edx, 0xf
add eax, edx
mov esi, eax
mov eax, dword [esp + 0x7c]
cdq
and edx, 0xf
add eax, edx
mov edi, eax
mov eax, dword [0x55cdfc]
sar edi, 4
sar esi, 4
cmp eax, 1
mov dword [esp + 0x1c], edi
jle 0x51cb0a
mov eax, dword [esp + 0x68]
mov edx, dword [esp + 0x7c]
mov dword [0x623d1c], eax
mov eax, dword [esp + 0x74]
mov dword [0x623d28], eax
mov dword [0x623d30], edx
mov edx, dword [esp + 0x80]
lea eax, [edi - 1]
mov dword [esp + 0x6c], eax
mov dword [0x623d34], edx
cdq
sub eax, edx
mov dword [0x623d2c], ecx
mov ecx, dword [esp + 0x84]
sar eax, 1
mov dword [0x623d20], ebp
mov dword [0x623d24], ebx
mov dword [0x623d38], ecx
mov dword [0x623d3c], esi
mov dword [0x623d40], edi
mov dword [0x623d44], 0
mov dword [esp + 0x20], eax
mov dword [0x623d48], eax
mov dword [0x623d4c], 0x51c740
call fcn.0051c6e0
mov eax, dword [esp + 0x20]
cmp eax, dword [esp + 0x6c]
jge 0x51caed
mov edx, ebx
shl edx, 5
mov dword [esp + 0x2c], edx
mov edx, dword [esp + 0x74]
shl edx, 4
mov dword [esp + 0x28], edx
mov edx, eax
shl edx, 5
lea edi, [edx + 0xe]
imul edi, ebx
mov ecx, eax
mov dword [esp + 0x18], edi
imul ecx, esi
add edx, 0x1e
imul edx, ebx
mov edi, eax
mov eax, dword [esp + 0x6c]
shl edi, 4
add edi, 0xe
imul edi, dword [esp + 0x74]
sub eax, dword [esp + 0x20]
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], edx
mov dword [esp + 0x20], eax
jmp 0x51ca73
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov eax, dword [ebp]
push esi
push ecx
mov ecx, dword [esp + 0x88]
push ecx
mov ecx, dword [esp + 0x88]
push ecx
mov ecx, dword [esp + 0x88]
push ecx
push dword [esp + 0x88]
mov ecx, dword [ebp + 8]
push ebx
add ecx, edi
push ecx
mov ecx, dword [ebp + 4]
add ecx, edi
add edx, eax
push ecx
push edx
mov edx, dword [esp + 0x40]
add edx, eax
push edx
call fcn.0051bc90
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x54]
mov edx, dword [esp + 0x40]
add ecx, esi
add edi, eax
mov eax, dword [esp + 0x58]
mov dword [esp + 0x3c], ecx
mov ecx, dword [esp + 0x44]
add edx, eax
add ecx, eax
mov eax, dword [esp + 0x4c]
add esp, 0x2c
dec eax
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x20], eax
jne 0x51ca6b
mov edi, dword [esp + 0x1c]
mov eax, dword [0x623d14]
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov dword [0x623d4c], 0
jmp 0x51cbd5
lea eax, [edi - 1]
test eax, eax
mov dword [esp + 0x6c], eax
jle 0x51cbd9
mov edi, dword [esp + 0x74]
mov ecx, ebx
shl ecx, 5
mov dword [esp + 0x28], ecx
mov ecx, edi
shl ecx, 4
mov dword [esp + 0x2c], ecx
mov ecx, ebx
imul ecx, ecx, 0xe
mov dword [esp + 0x10], ecx
mov ecx, ebx
imul ecx, ecx, 0x1e
imul edi, edi, 0xe
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], ecx
mov dword [esp + 0x20], eax
jmp 0x51cb56
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov eax, dword [ebp]
push esi
push edx
mov edx, dword [esp + 0x88]
push edx
mov edx, dword [esp + 0x88]
push edx
mov edx, dword [esp + 0x88]
push edx
mov edx, dword [esp + 0x88]
push edx
mov edx, dword [ebp + 8]
push ebx
add edx, edi
push edx
mov edx, dword [ebp + 4]
add edx, edi
add ecx, eax
push edx
push ecx
mov ecx, dword [esp + 0x38]
add ecx, eax
push ecx
call fcn.0051bc90
mov ecx, dword [esp + 0x44]
mov eax, dword [esp + 0x58]
mov edx, dword [esp + 0x40]
add ecx, esi
add edi, eax
mov eax, dword [esp + 0x54]
mov dword [esp + 0x44], ecx
mov ecx, dword [esp + 0x3c]
add edx, eax
add ecx, eax
mov eax, dword [esp + 0x4c]
add esp, 0x2c
dec eax
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x20], eax
jne 0x51cb52
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x6c]
mov edx, dword [ebp]
mov ecx, eax
imul eax, esi
shl ecx, 4
add ecx, 7
imul ecx, ebx
test esi, esi
lea ecx, [edx + ecx*2]
mov dword [esp + 0x2c], ecx
jle 0x51ccb7
mov ebx, dword [esp + 0x24]
mov edx, ecx
sub edx, ebx
lea edi, [ebx + ecx]
lea ebx, [ecx + ebx*2]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x80]
lea eax, [ebx + eax*4]
mov dword [esp + 0x28], edx
mov dword [esp + 0x14], edi
mov dword [esp + 0x6c], eax
mov dword [esp + 0x18], esi
jmp 0x51cc33
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x28]
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x6c]
mov eax, dword [eax]
mov eax, dword [eax*4 + 0x548210]
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x10]
sub eax, edi
sub ecx, edi
sub edx, edi
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], ecx
mov dword [esp + 0x38], edx
mov dword [esp + 0x20], 0x10
jmp 0x51cc70
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x38]
add eax, edi
push eax
push edi
add edx, edi
lea ebx, [ecx + edi]
mov ecx, dword [esp + 0x44]
push edx
push ecx
call fcn.0051b890
mov eax, dword [esp + 0x30]
add esp, 0x10
add edi, 2
dec eax
mov dword [esp + 0x20], eax
jne 0x51cc64
mov ecx, dword [esp + 0x6c]
mov eax, dword [esp + 0x18]
add ecx, 4
dec eax
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x18], eax
jne 0x51cc27
mov ebx, dword [esp + 0x70]
mov edi, dword [esp + 0x1c]
cmp dword [0x55cdfc], 1
jle 0x51ce6d
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0x68]
mov ecx, dword [esp + 0x78]
mov dword [0x623d30], eax
mov eax, dword [esp + 0x84]
mov dword [0x623d38], eax
mov dword [0x623d1c], edx
mov edx, dword [esp + 0x74]
lea eax, [esi - 1]
mov dword [0x623d28], edx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x68], eax
mov dword [0x623d48], eax
mov eax, dword [0x55ce00]
test eax, eax
mov dword [0x623d2c], ecx
mov ecx, dword [esp + 0x80]
mov dword [0x623d20], ebp
mov dword [0x623d24], ebx
mov dword [0x623d34], ecx
mov dword [0x623d3c], esi
mov dword [0x623d40], edi
mov dword [0x623d44], 0
mov dword [0x623d4c], 0x51c810
je 0x51cd8f
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push 0
push 0
push 0
push 0
mov dword [0x623d18], eax
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push 0
push 0
push 0
push 0x51c6a0
push 0
push 0
mov dword [0x623d14], eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [0x55ce00], 0
mov edx, dword [0x623d18]
push edx
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov ecx, dword [esp + 0x68]
lea eax, [esi - 1]
cmp ecx, eax
mov dword [esp + 0x68], ecx
jge 0x51ce50
mov eax, ecx
shl eax, 5
shl ecx, 4
mov dword [esp + 0x6c], eax
mov dword [esp + 0x70], ecx
jmp 0x51cdd0
mov ecx, dword [esp + 0x70]
mov eax, dword [esp + 0x6c]
lea esp, [esp]
mov edx, dword [ebp]
push edi
add eax, edx
mov edx, dword [esp + 0x6c]
push esi
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [ebp + 8]
lea edx, [edx + ecx + 0xe]
push ebx
push edx
mov edx, dword [ebp + 4]
lea ecx, [ecx + edx + 0xe]
push ecx
lea edx, [eax + 0x1e]
push edx
add eax, 0xe
push eax
call fcn.0051be40
mov ecx, dword [esp + 0x9c]
mov eax, dword [esp + 0x98]
mov edx, dword [esp + 0xa0]
add ecx, 0x20
add esp, 0x30
inc eax
mov dword [esp + 0x6c], ecx
add edx, 0x10
lea ecx, [esi - 1]
cmp eax, ecx
mov dword [esp + 0x68], eax
mov dword [esp + 0x70], edx
jl 0x51cdc1
mov eax, dword [0x623d14]
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov dword [0x623d4c], 0
jmp 0x51cf14
xor ecx, ecx
lea eax, [esi - 1]
cmp eax, ecx
mov dword [esp + 0x68], ecx
jle 0x51cf14
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x70], ecx
jmp 0x51ce90
mov ecx, dword [esp + 0x70]
lea esp, [esp]
mov edx, dword [ebp]
mov eax, dword [esp + 0x6c]
push edi
add eax, edx
mov edx, dword [esp + 0x6c]
push esi
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [esp + 0x8c]
push edx
mov edx, dword [ebp + 8]
lea edx, [edx + ecx + 0xe]
push ebx
push edx
mov edx, dword [ebp + 4]
lea ecx, [ecx + edx + 0xe]
push ecx
lea edx, [eax + 0x1e]
push edx
add eax, 0xe
push eax
call fcn.0051be40
mov ecx, dword [esp + 0x9c]
mov eax, dword [esp + 0x98]
mov edx, dword [esp + 0xa0]
add ecx, 0x20
add esp, 0x30
inc eax
mov dword [esp + 0x6c], ecx
add edx, 0x10
lea ecx, [esi - 1]
cmp eax, ecx
mov dword [esp + 0x68], eax
mov dword [esp + 0x70], edx
jl 0x51ce88
mov edx, dword [ebp]
lea eax, [esi - 1]
mov ecx, eax
shl ecx, 5
test edi, edi
lea ebx, [ecx + edx + 0xe]
jle 0x51cf7f
mov edx, dword [esp + 0x80]
lea ecx, [esi*4]
mov dword [esp + 0x7c], ecx
lea esi, [edx + eax*4]
mov dword [esp + 0x74], edi
mov eax, dword [esi]
mov edi, dword [eax*4 + 0x548210]
mov ebp, 0x10
mov edi, edi
lea ecx, [ebx + 4]
push ecx
lea edx, [ebx + 2]
push edx
lea eax, [ebx - 2]
push eax
push edi
call fcn.0051b890
mov ecx, dword [esp + 0x34]
add esp, 0x10
add ebx, ecx
dec ebp
jne 0x51cf50
mov ecx, dword [esp + 0x7c]
mov eax, dword [esp + 0x74]
add esi, ecx
dec eax
mov dword [esp + 0x74], eax
jne 0x51cf40
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54
ret