Function at 0x40a370
Capabilities:
Terminate thread

Disassembly:
push 0xffffffffffffffff
push 0x458c3b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x50
mov eax, dword [esp + 0x60]
push ebx
xor ebx, ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x74]
mov dword [esp + 0x10], ebx
mov byte [eax], bl
mov byte [eax + 0x12c], bl
mov byte [eax + 0x258], bl
mov byte [eax + 0x384], bl
mov byte [eax + 0x4b0], bl
xor esi, esi
jmp 0x40a3c0
mov ecx, dword [esi + 0x4c0d08]
push edi
call fcn.004047e0
add esi, 4
add edi, 0x12c
cmp esi, 0x20
jb 0x40a3c0
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x50], ebx
mov dword [esp + 0x54], ebx
mov dword [esp + 0x58], ebx
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], ebx
lea ebx, [ebx]
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ebp, dword [esp + 0x10]
mov eax, dword [esp + 0x70]
imul ebp, ebp, 0x12c
xor edi, edi
mov dword [esp + 0x14], ebx
add ebp, eax
mov ecx, dword [edi*4 + 0x4c0d08]
call fcn.004048e0
cmp al, 2
jne 0x40a638
mov eax, dword [esp + edi*4 + 0x20]
mov edx, dword [esp + 0x14]
inc edx
cmp eax, 0x12c
lea ecx, [eax + 1]
mov dword [esp + 0x14], edx
mov dword [esp + edi*4 + 0x20], ecx
jle 0x40a686
mov esi, dword [edi*4 + 0x4c0d08]
cmp esi, ebx
je 0x40a493
lea ecx, [esi + 0x130]
call fcn.0041fb8f
push esi
call fcn.0043d3bb
add esp, 4
push 0x138
call fcn.0043d390
mov esi, eax
add esp, 4
mov dword [esp + 0x1c], esi
cmp esi, ebx
mov dword [esp + 0x68], ebx
je 0x40a4c4
push ebx
push ebx
push ebx
lea ecx, [esi + 0x130]
call fcn.0041fb40
mov byte [esi], 2
mov byte [esi + 1], bl
jmp 0x40a4c6
xor esi, esi
mov eax, dword [edi*4 + 0x4c0cc0]
cmp eax, ebx
mov dword [esp + 0x68], 0xffffffff
mov dword [edi*4 + 0x4c0d08], esi
jne 0x40a4e4
xor eax, eax
jmp 0x40a4e7
mov eax, dword [eax + 0x28]
lea edx, [esp + 0x18]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov eax, dword [edi*4 + 0x4c0cc0]
cmp eax, ebx
jne 0x40a502
xor eax, eax
jmp 0x40a505
mov eax, dword [eax + 0x28]
mov ecx, dword [esp + 0x18]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov eax, dword [edi*4 + 0x4c0cc0]
cmp eax, ebx
jne 0x40a520
xor eax, eax
jmp 0x40a523
mov eax, dword [eax + 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.00454014
mov eax, dword [eax + 4]
mov edx, dword [eax + 0x1c]
mov eax, dword [edx + 0xd4]
cmp eax, ebx
jne 0x40a543
xor eax, eax
jmp 0x40a546
mov eax, dword [eax + 0x1c]
cmp edi, 7
ja case.default.0x40a54f
jmp dword [edi*4 + 0x40a6b4]
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a2e0
call fcn.0043ebdc
mov dword [0x4c0cc0], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a2f0
call fcn.0043ebdc
mov dword [0x4c0cc4], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a300
call fcn.0043ebdc
mov dword [0x4c0cc8], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a310
call fcn.0043ebdc
mov dword [0x4c0ccc], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a320
call fcn.0043ebdc
mov dword [0x4c0cd0], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a330
call fcn.0043ebdc
mov dword [0x4c0cd4], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a340
call fcn.0043ebdc
mov dword [0x4c0cd8], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
push ebx
push ebx
push ebx
push ebx
push eax
push 0x40a350
call fcn.0043ebdc
mov dword [0x4c0cdc], eax
mov dword [esp + edi*4 + 0x20], ebx
jmp 0x40a686
mov ecx, dword [edi*4 + 0x4c0d08]
call fcn.004048e0
cmp al, 1
jne 0x40a686
cmp dword [esp + edi*4 + 0x40], ebx
jne 0x40a686
cmp dword [esp + 0x10], 5
jge 0x40a67e
mov ecx, dword [esp + 0x74]
mov esi, dword [esp + 0x10]
mov eax, edi
imul eax, eax, 0x12c
add eax, ecx
inc esi
mov edx, ebp
mov dword [esp + 0x10], esi
add ebp, 0x12c
mov cl, byte [eax]
inc eax
mov byte [edx], cl
inc edx
cmp cl, bl
jne 0x40a674
mov dword [esp + edi*4 + 0x40], 1
inc edi
cmp edi, 8
jl 0x40a441
cmp dword [esp + 0x14], ebx
jne 0x40a420
mov ecx, dword [esp + 0x60]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x5c
ret