Function at 0x413b53
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov ecx, dword [ebp + 0x10]
and dword [ebp - 0x28], 0
test ecx, ecx
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 0x18], esi
je 0x413b74
mov eax, dword [ecx]
mov dword [ebp - 0x1c], eax
jmp 0x413b78
and dword [ebp - 0x1c], 0
test ecx, ecx
je 0x413b81
mov eax, dword [ecx + 4]
jmp 0x413b83
xor eax, eax
mov ebx, eax
movzx eax, ax
shr ebx, 0x10
test ecx, ecx
mov dword [ebp - 8], eax
je 0x413b9a
add ecx, 8
mov dword [ebp + 0x10], ecx
jmp 0x413ba0
lea eax, [ebp - 0x28]
mov dword [ebp + 0x10], eax
call dword [sym.imp.KERNEL32.DLL_GetTickCount]
mov edi, eax
mov al, bl
add edi, esi
and al, 2
cmp esi, 0x4e20
mov dword [ebp - 0x20], edi
mov byte [ebp + 0xb], al
jl 0x413bc4
push 1
call fcn.00439b12
pop ecx
cmp byte [ebp + 0xb], 0
je 0x413cec
mov dword [ebp - 0x18], 0x989680
and ebx, 1
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0xc], 0
je 0x413c7d
push 0x18
lea ecx, [ebp - 0x10]
call fcn.0043dc74
push dword [ebp - 0x10]
call fcn.00437dec
mov esi, dword [ebp - 0x10]
mov eax, dword [ebp + 0x10]
mov ebx, dword [sym.imp.KERNEL32.DLL_CreateThread]
and dword [esi], 0
mov dword [esp], 0x4c0bcc
mov dword [esi + 4], eax
mov eax, dword [ebp - 8]
mov dword [esi + 0xc], edi
mov edi, 0x10000
push edi
push esi
mov dword [esi + 8], eax
movsx eax, byte [ebp + 0xb]
push 0x43cffb
push edi
or eax, 5
push 0
mov dword [esi + 0x10], eax
call ebx
test eax, eax
mov dword [ebp - 0xc], eax
jne 0x413c5d
push eax
call dword [sym.imp.KERNEL32.DLL_Sleep]
push 0x4c0bcc
push edi
push esi
push 0x43cffb
push edi
push 0
call ebx
test eax, eax
mov dword [ebp - 0xc], eax
je 0x413c72
and dword [ebp - 0x10], 0
and dword [ebp - 0x14], 0
lea eax, [ebp - 0xc]
mov dword [ebp + 0x10], eax
mov dword [ebp - 8], 1
lea ecx, [ebp - 0x10]
call fcn.00437e1a
mov edi, dword [ebp - 0x20]
and dword [ebp - 4], 0
cmp dword [ebp - 0x14], 0
je 0x413c8d
call dword [sym.imp.KERNEL32.DLL_GetCurrentThreadId]
push 0x64
pop ebx
mov esi, 0x3e8
cmp byte [ebp + 0xb], 0
jne 0x413cb6
cmp dword [ebp + 0xc], 0
jg 0x413cb6
call dword [sym.imp.KERNEL32.DLL_GetTickCount]
mov ecx, edi
sub ecx, eax
test ecx, ecx
mov dword [ebp - 0x18], ecx
jle 0x413df3
cmp byte [0x4bf2c0], 0
jle 0x413df3
mov eax, dword [ebp - 0x18]
test eax, eax
jle 0x413dbe
cmp dword [ebp - 0x14], 0
je 0x413d0d
cmp eax, ebx
jle 0x413cda
mov eax, ebx
push eax
push dword [ebp - 0x14]
push dword [ebp + 0x10]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.DLL_WaitForMultipleObjects]
jmp 0x413d2f
test esi, esi
jg 0x413bd5
cmp dword [ebp + 0xc], 0
jg 0x413bd5
push 0
call dword [sym.imp.KERNEL32.DLL_Sleep]
xor eax, eax
jmp 0x413e1d
cmp eax, esi
jle 0x413d15
mov eax, esi
jmp 0x413d1b
cmp eax, ebx
jle 0x413d1b
mov eax, ebx
push 0x4ff
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp - 8]
call dword [sym.imp.USER32.DLL_MsgWaitForMultipleObjects]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
jne 0x413d49
cmp dword [ebp - 8], 0
jne 0x413de3
push 1
call dword [sym.imp.KERNEL32.DLL_Sleep]
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 8]
jae 0x413dbe
cmp dword [ebp - 0xc], 0
je 0x413e1a
lea eax, [ebp - 4]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.DLL_GetExitCodeThread]
jmp 0x413e0b
cmp byte [ebp + 0xb], 0
jne 0x413d8a
cmp dword [ebp + 0xc], 0
jg 0x413d8a
call dword [sym.imp.KERNEL32.DLL_GetTickCount]
mov ecx, edi
sub ecx, eax
test ecx, ecx
mov dword [ebp - 0x18], ecx
jle 0x413dcd
push 3
push 0
push 0
push dword [ebp - 0x1c]
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.USER32.DLL_PeekMessageW]
test eax, eax
je 0x413dc9
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.USER32.DLL_TranslateMessage]
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.USER32.DLL_DispatchMessageW]
cmp dword [ebp + 0xc], 0
jle 0x413dbe
dec dword [ebp + 0xc]
cmp byte [0x4bf2c0], 0
jg 0x413d6d
jmp 0x413dcd
and dword [ebp + 0xc], 0
cmp dword [ebp - 4], 0x102
jne 0x413c95
and dword [ebp + 0xc], 0
jmp 0x413c95
call dword [sym.imp.KERNEL32.DLL_GetLastError]
test eax, eax
jne 0x413dee
inc eax
mov dword [ebp - 4], eax
jmp 0x413e0b
mov eax, dword [ebp - 8]
test eax, eax
jne 0x413dff
and dword [ebp - 4], eax
jmp 0x413e0b
cmp dword [ebp - 4], eax
jne 0x413e0b
mov dword [ebp - 4], 0x102
cmp dword [ebp - 0xc], 0
je 0x413e1a
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0xc