Function at 0x645490
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x7c50a3
mov eax, dword fs:[0]
push eax
sub esp, 0x30
push ebx
push esi
push edi
mov eax, dword [0x89b044]
xor eax, esp
push eax
lea eax, [esp + 0x40]
mov dword fs:[0], eax
mov edi, ecx
mov ebx, dword [ebp + 8]
xor esi, esi
cmp ebx, esi
je 0x6456bf
mov eax, dword [edi + 0x28]
mov edx, dword [eax + 4]
lea ecx, [edi + 0x28]
mov dword [esp + 0x18], ecx
call edx
mov eax, dword [edi + 4]
mov dword [esp + 0x48], esi
test eax, eax
je 0x6456ac
mov edx, dword [ebp + 0xc]
lea ecx, [esp + 0x14]
push ecx
push esi
push edx
push ebx
push esi
push esi
mov dword [esp + 0x2c], esi
call fcn.007263d8
add esp, 0x18
mov dword [esp + 0x20], eax
cmp eax, esi
je 0x6456ac
mov eax, dword [ebp + 0x18]
cmp eax, esi
je 0x645522
push eax
mov eax, dword [esp + 0x18]
push eax
mov ecx, edi
call fcn.006439b0
mov eax, dword [edi + 0x20]
mov ebx, dword [edi + 8]
add edi, 8
mov dword [esp + 0x1c], esi
mov eax, dword [eax]
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], eax
lea esp, [esp]
mov esi, dword [edi + 0x18]
mov eax, dword [edi]
test ebx, ebx
je 0x64554d
cmp ebx, eax
je 0x645552
call fcn.0071ffb6
cmp dword [esp + 0x28], esi
je 0x64562b
test ebx, ebx
jne 0x64559f
call fcn.0071ffb6
xor eax, eax
mov ecx, dword [esp + 0x28]
cmp ecx, dword [eax + 0x18]
jne 0x645575
call fcn.0071ffb6
mov edx, dword [esp + 0x28]
mov esi, dword [edx + 0x10]
test esi, esi
jne 0x6455a3
lea ecx, [esp + 0x24]
mov esi, edx
call fcn.00643c30
push esi
push ebx
lea eax, [esp + 0x34]
push eax
mov ecx, edi
call fcn.00644560
mov ebx, dword [esp + 0x24]
jmp 0x645540
mov eax, dword [ebx]
jmp 0x645567
mov edx, dword [esi]
lea ecx, [esp + 0x1c]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x645619
cmp dword [esp + 0x1c], 0x103
je 0x645619
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esi + 0x1c], 0x10
jb 0x6455da
mov ecx, dword [esi + 8]
push ecx
call fcn.00704960
add esp, 4
mov dword [esi + 0x1c], 0xf
mov dword [esi + 0x18], 0
push esi
mov byte [esi + 8], 0
call fcn.00704960
mov esi, dword [esp + 0x2c]
add esp, 4
lea ecx, [esp + 0x24]
call fcn.00643c30
push esi
push ebx
lea edx, [esp + 0x3c]
push edx
mov ecx, edi
call fcn.00644560
mov ebx, dword [esp + 0x24]
jmp 0x645540
lea ecx, [esp + 0x24]
call fcn.00643c30
mov ebx, dword [esp + 0x24]
jmp 0x645540
push 0x28
call fcn.00704930
add esp, 4
mov dword [esp + 0x24], eax
mov byte [esp + 0x48], 1
test eax, eax
je 0x64565a
mov ecx, dword [ebp + 0x18]
mov edx, dword [ebp + 0x14]
push ecx
mov ecx, dword [esp + 0x24]
push edx
push ecx
mov ecx, eax
call fcn.00644ba0
mov esi, eax
jmp 0x64565c
xor esi, esi
mov byte [esp + 0x48], 0
test esi, esi
je 0x645673
lea edx, [esp + 0x14]
push edx
mov ecx, edi
call fcn.00645380
mov dword [eax], esi
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x645680
mov ecx, dword [esp + 0x14]
mov dword [eax], ecx
mov ecx, dword [esp + 0x18]
mov edx, dword [ecx]
mov eax, dword [edx + 8]
mov dword [esp + 0x48], 0xffffffff
call eax
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x40]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [esp + 0x18]
mov edx, dword [ecx]
mov eax, dword [edx + 8]
mov dword [esp + 0x48], 0xffffffff
call eax
xor eax, eax
mov ecx, dword [esp + 0x40]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14