Function at 0x664eb0
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0xc], edi
call fcn.0066df3f
mov esi, eax
mov eax, dword [edi + 0x28]
dec eax
mov ecx, esi
mov dword [ebp - 8], eax
call fcn.0064935e
cmp dword [ebp + 0x1c], 0
mov ebx, dword [ebp + 0x10]
mov dword [ebp - 4], eax
jge 0x664ef4
movzx ecx, byte [ebx + 0x18]
push eax
push ecx
push 0x2d
pop edx
mov ecx, esi
call fcn.00649192
pop ecx
pop ecx
xor eax, eax
mov dword [ebp - 0x14], eax
cmp dword [ebx + 0x14], eax
jle 0x664f2a
mov edi, dword [ebp - 4]
mov ecx, dword [ebp + 0x14]
push edi
mov eax, dword [ecx + eax*4]
mov ecx, dword [ebp + 0x18]
inc ecx
add eax, ecx
mov ecx, esi
push eax
push 0x4b
pop edx
call fcn.00649192
mov eax, dword [ebp - 0x14]
inc eax
pop ecx
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, dword [ebx + 0x14]
jl 0x664f01
mov edi, dword [ebp - 0xc]
cmp dword [ebp + 0x20], 0
jne 0x665150
cmp dword [ebp + 0xc], 0
mov ecx, edi
jne 0x665000
call fcn.0065b3fb
push eax
mov dword [ebp + 0x10], eax
mov eax, dword [ebp + 0x14]
mov ecx, dword [eax]
mov eax, dword [ebp + 0x18]
inc eax
add ecx, eax
push ecx
push 0x41
pop edx
mov ecx, esi
call fcn.00649192
push 0
push dword [ebp + 0x10]
mov ecx, esi
push 0x11
pop edx
call fcn.00649192
mov dword [ebp + 0x20], eax
add esp, 0x10
mov eax, dword [ebp + 8]
cmp eax, dword [ebx]
jne 0x664fa6
cmp dword [ebp + 0x1c], 1
jne 0x664fa6
push dword [ebp + 0x10]
mov ecx, esi
push dword [ebp - 4]
push dword [ebp + 0x18]
push 0x4e
pop edx
call fcn.0064910e
add esp, 0xc
mov edx, 0x90
mov ecx, esi
call fcn.0064962b
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 8]
mov ecx, edi
push 0x68
push eax
push dword [ebp - 0x18]
call fcn.006661b5
add esp, 0xc
mov ecx, esi
push dword [ebp + 0x10]
push 0
push dword [ebp - 8]
push 0x20
pop edx
call fcn.0064910e
mov edx, dword [ebp - 4]
add esp, 0xc
mov ecx, esi
call fcn.006491a7
mov ecx, esi
call fcn.0064950e
lea edx, [eax - 2]
call fcn.00649643
mov edx, dword [ebp + 0x20]
mov ecx, esi
call fcn.00649643
mov edx, dword [ebp + 0x10]
mov ecx, edi
call fcn.0065b41a
jmp 0x665150
mov eax, dword [ebx + 0x14]
mov edx, eax
mov dword [ebp + 0x20], eax
call fcn.0065b45d
mov ecx, edi
mov dword [ebp - 0x14], eax
call fcn.0065b3fb
push dword [ebp - 0x18]
mov dword [ebp - 0x10], eax
mov ecx, esi
mov eax, dword [ebp + 0xc]
push dword [eax + 0x2c]
push dword [ebp - 8]
push 0x68
pop edx
call fcn.0064910e
mov edx, dword [ebp + 0xc]
add esp, 0xc
mov ecx, edi
call fcn.006498f7
and dword [ebp - 0x18], 0
mov edx, dword [ebp + 0x20]
test edx, edx
jle 0x66507a
mov ebx, dword [ebp - 0x18]
mov edi, edx
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp + 0x18]
add eax, ebx
push eax
mov eax, dword [ebp + 0x14]
inc ecx
mov eax, dword [eax + ebx*4]
add eax, ecx
mov ecx, esi
push eax
push 0x40
pop edx
call fcn.00649192
inc ebx
pop ecx
pop ecx
cmp ebx, edi
jl 0x66504d
mov edi, dword [ebp - 0xc]
mov ebx, dword [ebp + 0x10]
mov edx, dword [ebp + 0x20]
mov eax, dword [ebp + 8]
cmp eax, dword [ebx]
jne 0x6650fd
cmp dword [ebp + 0x1c], 1
jne 0x6650fd
mov ecx, esi
call fcn.0064950e
inc eax
xor ecx, ecx
add eax, edx
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x1c], eax
test edx, edx
jle 0x6650f3
mov edi, dword [ebp + 0x18]
mov eax, dword [ebp + 0x14]
lea edx, [edi + 1]
mov ebx, dword [ebp + 8]
mov eax, dword [eax + ecx*4]
add edx, eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 4]
movzx ecx, word [eax + ecx*2]
movsx eax, cx
inc eax
add eax, edi
cmp cx, word [ebx + 0x28]
mov ecx, esi
cmove eax, edi
push eax
push dword [ebp - 0x1c]
push edx
push 0x4d
pop edx
call fcn.0064910e
add esp, 0xc
mov ecx, esi
push 0x10
pop edx
call fcn.0064962b
mov ecx, dword [ebp - 0x18]
inc ecx
mov dword [ebp - 0x18], ecx
cmp ecx, dword [ebp + 0x20]
jl 0x6650a0
mov edi, dword [ebp - 0xc]
mov ebx, dword [ebp + 0x10]
mov edx, dword [ebp - 4]
mov ecx, esi
call fcn.006491a7
push dword [ebp + 0x20]
mov edx, dword [ebp + 0xc]
push ecx
mov ecx, dword [edi]
call fcn.0066623b
pop ecx
push eax
push dword [ebp - 0x10]
mov ecx, esi
push dword [ebp + 0x20]
push dword [ebp - 0x14]
push 0x63
pop edx
call fcn.00649258
add esp, 0x14
mov ecx, esi
push 0
push dword [ebp - 0x10]
push dword [ebp - 4]
push dword [ebp - 8]
push 0x1e
pop edx
call fcn.0064930f
mov edx, dword [ebp - 0x10]
mov ecx, edi
call fcn.0065b41a
push dword [ebp + 0x20]
mov edx, dword [ebp - 0x14]
call fcn.0065b493
add esp, 0x14
mov cl, byte [ebx + 0x18]
test cl, cl
jne 0x665186
mov eax, dword [edi]
test dword [eax + 0x18], 0x40000
jne 0x665186
cmp dword [edi + 0x78], 0
jne 0x665186
cmp byte [edi + 0x14], cl
jne 0x665186
push 4
push 0xffffffffffffffff
push 0
push 2
mov edx, 0x313
mov ecx, edi
call fcn.006617b0
add esp, 0x10
jmp 0x6651ad
cmp dword [ebp + 0x1c], 0
jle 0x665197
test cl, cl
jne 0x665197
mov ecx, edi
call fcn.006617a3
push dword [ebp + 0x1c]
movzx eax, byte [ebx + 0x18]
mov edx, 0x91
push eax
mov ecx, esi
call fcn.00649192
pop ecx
pop ecx
mov edx, dword [ebp - 4]
mov ecx, esi
call fcn.006493a0
push dword [ebp - 8]
push 0x70
pop edx
call fcn.0064917e
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret