Function at 0x1000be20
Capabilities:
Suspend thread
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10124fd8
mov eax, dword fs:[0]
push eax
sub esp, 0x70
mov eax, dword [0x10193008]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov esi, dword [ebp + 8]
cmp dword [esi + 0x10], 0
jne 0x1000be5d
xor al, al
jmp 0x1000c242
cmp byte [edi + 0x6e], 0
je 0x1000be6a
mov al, 1
jmp 0x1000c242
push 4
xor eax, eax
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
lea ecx, [ebp - 0x30]
push str.tool
mov byte [edi + 0x6e], 1
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 7
mov word [ebp - 0x30], ax
call fcn.10004c40
lea eax, [ebp - 0x30]
mov dword [ebp - 4], 0
push eax
mov edx, esi
lea ecx, [ebp - 0x78]
call fcn.1005f080
add esp, 4
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 3
call fcn.10004be0
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 2
call fcn.1005e540
test al, al
jne 0x1000bedb
lea ecx, [ebp - 0x78]
call fcn.1005ea90
push 0xf
xor eax, eax
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
lea ecx, [ebp - 0x30]
push 0x10156eac
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 7
mov word [ebp - 0x30], ax
call fcn.10004c40
lea eax, [ebp - 0x30]
mov byte [ebp - 4], 7
push eax
lea edx, [ebp - 0x78]
lea ecx, [ebp - 0x60]
call fcn.1005f080
add esp, 4
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 0xa
call fcn.10004be0
push 0
lea eax, [ebp - 0x60]
mov byte [ebp - 4], 9
push eax
call fcn.1000d940
lea esi, [edi + 0x68]
mov dword [ebp - 0x7c], esi
test al, al
je 0x1000bf71
test esi, esi
je 0x1000bf58
mov eax, dword [esi]
test eax, eax
je 0x1000bf58
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 5
lea ecx, [edi + 0x4c]
mov byte [ebp - 4], 0xe
push str._u104
call fcn.10005880
mov byte [ebp - 4], 0xf
jmp 0x1000bf99
test esi, esi
je 0x1000bf82
mov eax, dword [esi]
test eax, eax
je 0x1000bf82
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 5
lea ecx, [edi + 0x4c]
mov byte [ebp - 4], 0x10
push str._u105
call fcn.10005880
mov byte [ebp - 4], 0x11
test esi, esi
je 0x1000bfb1
mov eax, dword [esi]
test eax, eax
je 0x1000bfaa
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [ebp - 0x7c], 0
mov byte [ebp - 4], 9
mov ecx, dword [edi + 0x64]
test ecx, ecx
je 0x1000c046
push 0x1388
call fcn.1005f730
test al, al
jne 0x1000c046
mov ecx, dword [edi + 0x64]
call fcn.1005f810
push eax
push 0
push 0x43
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov ebx, eax
test ebx, ebx
je 0x1000c046
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x1000c03f
cmp dword [ebp - 0x18], 0x103
jne 0x1000c03f
push ebx
call dword [sym.imp.KERNEL32.dll_SuspendThread]
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push str.RtlFreeUserThreadStack
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x7c], eax
test eax, eax
je 0x1000c036
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [ebp - 0x7c]
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [edi + 0x64]
test ebx, ebx
je 0x1000c06c
push 0xffffffffffffffff
lea eax, [ebx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
sub eax, 1
jne 0x1000c065
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 4]
mov dword [edi + 0x64], 0
mov byte [ebp - 4], 0x12
xor eax, eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], ax
mov byte [ebp - 4], 0x13
mov dword [ebp - 0x7c], esi
test esi, esi
je 0x1000c0aa
mov eax, dword [esi]
test eax, eax
je 0x1000c0aa
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [ebp - 4], 0x14
lea ecx, [ebp - 0x48]
cmp byte [edi + 0x6c], 0
je 0x1000c0d1
lea eax, [edi + 4]
cmp ecx, eax
je 0x1000c0e5
cmp dword [eax + 0x14], 8
mov ecx, eax
jb 0x1000c0c8
mov ecx, dword [eax]
push dword [eax + 0x10]
push ecx
lea ecx, [ebp - 0x48]
jmp 0x1000c0e0
cmp dword [ebp - 0x4c], 8
lea eax, [ebp - 0x60]
push dword [ebp - 0x50]
cmovae eax, dword [ebp - 0x60]
push eax
call fcn.10004c40
mov byte [ebp - 4], 0x15
test esi, esi
je 0x1000c101
mov eax, dword [esi]
test eax, eax
je 0x1000c0fa
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [ebp - 0x7c], 0
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 0x13
call fcn.1005e430
test al, al
jne 0x1000c118
xor bl, bl
jmp 0x1000c212
cmp dword [edi + 0x48], 8
lea eax, [edi + 0x34]
mov dword [ebp - 0x18], eax
jb 0x1000c129
mov eax, dword [eax]
mov dword [ebp - 0x18], eax
cmp dword [edi + 0x30], 8
lea eax, [edi + 0x1c]
mov dword [ebp - 0x7c], eax
jb 0x1000c13a
mov eax, dword [eax]
mov dword [ebp - 0x7c], eax
cmp dword [ebp - 0x34], 8
lea eax, [ebp - 0x48]
cmovae eax, dword [ebp - 0x48]
or ebx, 0xffffffff
cmp dword [edi], 0
jne 0x1000c1af
test eax, eax
je 0x1000c1af
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [edi], eax
test eax, eax
je 0x1000c1aa
push 0x1015725c
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x1000c176
push dword [ebp - 0x18]
call eax
add esp, 4
push 0x10157270
push dword [edi]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x1000c19a
push dword [ebp - 0x7c]
push 0x10153770
call eax
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x1000c1af
push dword [edi]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [edi], 0
jmp 0x1000c1af
mov ebx, 0xfffffffe
mov dword [ebp - 0x7c], esi
test esi, esi
je 0x1000c1c3
mov eax, dword [esi]
test eax, eax
je 0x1000c1c3
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov byte [ebp - 4], 0x22
push 4
test ebx, ebx
jne 0x1000c1d4
push str._u70
jmp 0x1000c1e5
cmp ebx, 0xfffffffe
jne 0x1000c1e0
push str._u72
jmp 0x1000c1e5
push str._u71
lea ecx, [edi + 0x4c]
call fcn.10005880
test ebx, ebx
sete bl
mov byte [ebp - 4], 0x23
test esi, esi
je 0x1000c20e
mov eax, dword [esi]
test eax, eax
je 0x1000c207
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [ebp - 0x7c], 0
mov byte [ebp - 4], 0x13
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 0x24
call fcn.10004be0
lea ecx, [ebp - 0x60]
mov byte [ebp - 4], 0x28
call fcn.10004be0
lea ecx, [ebp - 0x78]
mov dword [ebp - 4], 0x2c
call fcn.10004be0
mov dword [ebp - 4], 0xffffffff
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.100fc1a9
mov esp, ebp
pop ebp
ret 4