Function at 0x46aa50
Capabilities:
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d08e0
mov eax, dword fs:[0]
push eax
sub esp, 0x88
push ebx
push esi
push edi
mov eax, dword [0x507074]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
lea ebx, [esi + 0x18]
lea edi, [esi + 0x14]
push edi
lea ecx, [ebx + 0x18]
call fcn.00409440
mov ecx, ebx
call fcn.004568d0
push edi
lea ecx, [esi + 0x64]
call fcn.00409440
mov edi, esi
lea ecx, [esi + 0x4c]
mov dword [edi + 0x50], ebx
call fcn.00456c20
test al, al
jne 0x46aae8
movzx eax, byte [edi + 0x11d]
mov ecx, dword [edi + 0x60]
push eax
push 1
push dword [ecx]
push dword [ecx + 4]
call dword [sym.imp.USER32.dll_PostThreadMessageW]
test eax, eax
jne 0x46aacf
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, 0xe0000027
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 0
mov dword [ebp - 4], 0
mov esi, dword [ebp + 8]
mov dword [ebp - 0x38], esi
mov byte [ebp - 0x34], 0
mov dword [ebp - 4], 1
lea eax, [ebp - 0x44]
push eax
push esi
lea eax, [edi + 8]
push eax
lea ecx, [ebp - 0x94]
call fcn.0047cf90
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x94]
push 0
push 0
call fcn.0047d0a0
cmp dword [edi + 4], 7
jne 0x46abf0
mov eax, dword [esi + 0xe0]
mov dword [ebp - 0x10], 0
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x30], eax
call fcn.004043d0
mov ecx, eax
test ecx, ecx
je 0x46af2c
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp + 8], eax
mov byte [ebp - 4], 3
lea ecx, [ebp + 8]
push 0x4e55b0
call fcn.00403470
test al, al
jne 0x46ab97
push 0x10
push 0x4e55b0
lea ecx, [ebp + 8]
call fcn.004035e0
mov byte [ebp - 4], 4
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp + 8]
push eax
push 0
lea ecx, [esi + 0xe0]
call dword [ebp - 0x30]
mov bl, al
mov byte [ebp - 4], 2
or ecx, 0xffffffff
mov edx, dword [ebp + 8]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x46abcf
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
test bl, bl
je 0x46abf0
mov eax, dword [ebp - 0x10]
cmp eax, 2
jne 0x46abe4
mov dword [edi + 4], 8
jmp 0x46abf0
cmp eax, 3
jne 0x46abf0
mov dword [edi + 4], 9
mov eax, dword [edi + 4]
cmp eax, 8
je 0x46abfd
cmp eax, 9
jne 0x46ac42
cmp eax, 9
mov dword [ebp - 0x10], 0
lea eax, [ebp + 8]
mov dword [ebp + 8], 0
push eax
lea eax, [ebp - 0x10]
sete byte [ebp - 0x30]
push eax
push dword [ebp - 0x30]
lea ecx, [ebp - 0x44]
call fcn.0047e1f0
cmp dword [ebp + 8], 0
je 0x46aeb6
cmp byte [esi + 0x84], 0
je 0x46ac42
cmp dword [ebp - 0x10], 0
je 0x46aeb6
cmp byte [edi + 0x16a], 0
lea eax, [ebp - 0x44]
mov dword [ebp - 0x50], 0x4e56a0
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x48], esi
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
je 0x46ad55
lea eax, [ebp + 8]
mov dword [ebp - 0x2c], 0x4e1698
push eax
push 1
push 0
lea ecx, [ebp - 0x44]
mov word [ebp - 0x28], 0x101
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp + 8], 0
call fcn.0047e380
cmp byte [ebp - 0x28], 0
je 0x46aceb
cmp byte [ebp - 0x27], 0
je 0x46aceb
cmp dword [ebp - 0x14], 0
je 0x46aceb
mov eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x2c]
call dword [eax + 4]
mov ecx, dword [ebp - 0x14]
push 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov eax, dword [ecx]
push 0
push 0x67
call dword [eax + 0xc]
mov ecx, dword [ebp - 0x4c]
xor esi, esi
push esi
call fcn.0047e7d0
test eax, eax
je 0x46ad03
mov esi, eax
cmp eax, 0xe0000008
je 0x46ad1e
mov eax, dword [ebp - 0x48]
cmp byte [eax + 0x84], 0
jne 0x46ad1e
mov ecx, dword [ebp - 0x4c]
push 0
call fcn.0047e490
test eax, eax
cmovne esi, eax
cmp byte [ebp - 0x28], 0
je 0x46aeb8
cmp byte [ebp - 0x27], 0
je 0x46aeb8
cmp dword [ebp - 0x14], 0
je 0x46aeb8
mov eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x2c]
call dword [eax + 4]
mov ecx, dword [ebp - 0x14]
push esi
push 0x67
mov eax, dword [ecx]
call dword [eax + 0x14]
jmp 0x46aeb8
cmp byte [edi + 0x16b], 0
lea eax, [ebp - 0x50]
mov dword [ebp - 0x28], 0x4e2b64
mov dword [ebp - 0x20], 0xffffffff
mov dword [ebp - 0x28], 0x4e2b74
mov dword [ebp - 0x1c], eax
je 0x46ae1d
mov byte [ebp - 4], 8
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x44]
mov ecx, edi
push eax
push esi
call fcn.0046b720
mov eax, dword [ebp - 0x24]
mov edi, dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x46adbf
lea ecx, [ebp + 8]
mov dword [ebp + 8], 0
push ecx
push eax
call edi
test eax, eax
je 0x46adb5
mov esi, dword [ebp + 8]
jmp 0x46adc1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x46adc1
xor esi, esi
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x28], 0x4e2b74
test eax, eax
je 0x46aeb8
push dword [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp dword [ebp - 0x20], 0xffffffff
je 0x46ae0f
lea eax, [ebp + 8]
mov dword [ebp + 8], 0
push eax
push dword [ebp - 0x24]
call edi
test eax, eax
je 0x46ae0f
cmp dword [ebp + 8], 0x103
jne 0x46ae0f
push 0
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x46aeb8
mov byte [ebp - 4], 0xa
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x44]
mov ecx, edi
push eax
push esi
call fcn.0046b0c0
mov eax, dword [ebp - 0x24]
mov edi, dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x46ae5f
lea ecx, [ebp + 8]
mov dword [ebp + 8], 0
push ecx
push eax
call edi
test eax, eax
je 0x46ae55
mov esi, dword [ebp + 8]
jmp 0x46ae61
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x46ae61
xor esi, esi
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x28], 0x4e2b74
test eax, eax
je 0x46aeb8
push dword [ebp - 0x20]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp dword [ebp - 0x20], 0xffffffff
je 0x46aeab
lea eax, [ebp + 8]
mov dword [ebp + 8], 0
push eax
push dword [ebp - 0x24]
call edi
test eax, eax
je 0x46aeab
cmp dword [ebp + 8], 0x103
jne 0x46aeab
push 0
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x46aeb8
xor esi, esi
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x94]
call fcn.0046a9b0
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x44]
test eax, eax
je 0x46af08
xor edi, edi
cmp dword [ebp - 0x40], edi
jle 0x46aef8
xor ebx, ebx
nop
lea ecx, [ebx + eax]
mov eax, dword [ecx]
push 0
call dword [eax]
mov eax, dword [ebp - 0x44]
lea ebx, [ebx + 0x16c]
inc edi
cmp edi, dword [ebp - 0x40]
jl 0x46aee0
push eax
call fcn.004a03e1
add esp, 4
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x40], 0
mov eax, esi
mov dword [ebp - 0x3c], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push 0x80004005
call fcn.00402570
int3