Function at 0x4ec240
Capabilities:
Read file on windows
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x70
mov eax, dword [0x6d7160]
xor eax, esp
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x78]
push ebx
push ebp
mov ebp, dword [esp + 0x7c]
push esi
push edi
mov edi, edx
test edi, edi
mov ebx, ecx
mov dword [esp + 0x30], ebp
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], eax
jne 0x4ec286
lea eax, [edx + 4]
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov esi, dword [eax + 4]
cmp esi, 4
jbe 0x4ec5b2
mov eax, dword [eax + 8]
lea ecx, [esp + 0x18]
mov dword [esp + 0x18], eax
call fcn.004dc410
mov eax, dword [ebx + 8]
mov ebx, dword [esp + 0x18]
cmp ebx, eax
jae 0x4ec5b2
cmp esi, eax
ja 0x4ec5b2
add esi, ebx
cmp esi, eax
ja 0x4ec5b2
mov eax, dword [ebp + 0x14]
lea esi, [esp + 0x14]
call fcn.004ee070
mov ecx, dword [esp + 0x20]
mov ecx, dword [ecx + 4]
add ecx, ebx
mov eax, ebp
call fcn.004e39f0
mov esi, eax
test esi, esi
jne 0x4ec8d9
mov edx, dword [esp + 0x1c]
mov ebx, dword [edx + 4]
cmp ebx, 0x20
jbe 0x4ec2fa
mov ebx, 0x20
mov esi, dword [ebp + 0x10]
mov edx, dword [esi + 0x14]
test edx, edx
mov dword [esp + 0x2c], ebx
je 0x4ec367
mov eax, dword [esi + 0x1c]
cmp ebx, eax
ja 0x4ec319
mov ecx, dword [esi + 0x18]
lea ebp, [ecx + ebx]
cmp ebp, eax
jbe 0x4ec320
mov ecx, dword [esi + 0x18]
sub eax, ecx
mov ebx, eax
test ebx, ebx
je 0x4ec33a
push ebx
add ecx, edx
push ecx
lea eax, [esp + 0x64]
push eax
call fcn.0060d1b0
add esp, 0xc
add dword [esi + 0x18], ebx
jmp 0x4ec33c
xor ebx, ebx
cmp ebx, dword [esp + 0x2c]
je 0x4ec3a3
lea edi, [esp + 0x14]
mov esi, 2
call fcn.00401700
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov eax, dword [esi + 4]
test eax, eax
je 0x4ec38b
mov ecx, dword [esp + 0x2c]
push eax
push 1
push ecx
lea edx, [esp + 0x68]
push edx
call fcn.0060860a
add esp, 0x10
test eax, eax
je 0x4ec38b
xor esi, esi
jmp 0x4ec39b
cmp dword [esi + 4], 0
je 0x4ec398
mov esi, 2
jmp 0x4ec39b
mov esi, dword [esi + 0xc]
test esi, esi
jne 0x4ec8d9
xor eax, eax
mov dword [esp + 0x2c], eax
mov ebx, 0x6a1540
mov dword [esp + 0x28], eax
cmp dword [ebx + 0x10], 0
jne 0x4ec418
mov eax, dword [ebx]
lea ecx, [esp + 0x14]
call fcn.0045a270
test al, al
je 0x4ec4ae
mov eax, dword [esp + 0x20]
mov ebp, dword [eax + 4]
mov ecx, dword [esp + 0x1c]
mov edx, dword [ecx + 4]
mov eax, dword [esp + 0x18]
mov esi, dword [ebx + 0x18]
add edx, eax
add eax, 2
mov dword [esp + 0x48], eax
mov al, 1
mov ecx, ebx
call fcn.004dd1a0
mov dword [edi], esi
mov dword [edi + 4], ebp
mov dword [edi + 8], edx
mov edx, dword [esp + 0x18]
mov byte [esp + 0x4c], al
mov eax, dword [esp + 0x48]
mov ecx, dword [esp + 0x4c]
mov dword [edi + 0xc], edx
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], ecx
jmp case.0x4ec4fe.4
mov eax, dword [ebx + 4]
mov ecx, dword [esp + 0x1c]
cmp eax, dword [ecx + 4]
ja 0x4ec4ae
cmp eax, 4
mov edx, dword [ebx]
lea ecx, [esp + 0x5c]
jb 0x4ec447
mov esi, dword [edx]
cmp esi, dword [ecx]
jne 0x4ec44b
sub eax, 4
add ecx, 4
add edx, 4
cmp eax, 4
jae 0x4ec433
test eax, eax
je 0x4ec4a8
movzx esi, byte [edx]
movzx ebp, byte [ecx]
sub esi, ebp
jne 0x4ec49a
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x4ec4a8
movzx esi, byte [edx]
movzx ebp, byte [ecx]
sub esi, ebp
jne 0x4ec49a
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x4ec4a8
movzx esi, byte [edx]
movzx ebp, byte [ecx]
sub esi, ebp
jne 0x4ec49a
sub eax, 1
add ecx, 1
add edx, 1
test eax, eax
je 0x4ec4a8
movzx esi, byte [edx]
movzx edx, byte [ecx]
sub esi, edx
je 0x4ec4a8
test esi, esi
mov eax, 1
jg 0x4ec4aa
or eax, 0xffffffff
jmp 0x4ec4aa
xor eax, eax
test eax, eax
je 0x4ec4ef
mov eax, dword [esp + 0x28]
add dword [esp + 0x2c], 1
add eax, 0x1c
add ebx, 0x1c
cmp eax, 0x364
mov dword [esp + 0x28], eax
jb 0x4ec3b2
lea edi, [esp + 0x14]
call fcn.00401700
mov eax, 9
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov eax, dword [ebx + 0x10]
add eax, 0xffffffff
cmp eax, 4
ja case.default.0x4ec4fe
jmp dword [eax*4 + 0x4ec8fc]
mov ecx, dword [esp + 0x20]
mov ecx, dword [ecx + 4]
mov eax, dword [esp + 0x18]
mov edx, dword [ebx + 8]
mov ebp, dword [ebx + 0x18]
mov dword [esp + 0x3c], ecx
mov ecx, dword [esp + 0x1c]
mov esi, dword [ecx + 4]
add edx, eax
add esi, eax
lea eax, [edx + 2]
mov dword [esp + 0x48], eax
mov al, 1
mov ecx, ebx
call fcn.004dd1a0
mov ecx, dword [esp + 0x3c]
mov dword [edi], ebp
mov dword [edi + 4], ecx
mov dword [edi + 8], esi
mov dword [edi + 0xc], edx
mov edx, dword [esp + 0x48]
mov byte [esp + 0x4c], al
mov dword [edi + 0x10], edx
jmp 0x4ec752
mov ecx, dword [esp + 0x20]
mov edx, dword [ecx + 4]
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax + 4]
mov esi, dword [ebx + 8]
mov ebp, dword [ebx + 0x18]
add edx, dword [esp + 0x18]
lea eax, [esi + 2]
mov dword [esp + 0x40], ecx
mov dword [esp + 0x48], eax
mov al, 1
mov ecx, ebx
call fcn.004dd1a0
mov ecx, dword [esp + 0x40]
mov dword [edi], ebp
mov dword [edi + 4], edx
mov edx, dword [esp + 0x48]
mov dword [edi + 8], ecx
mov dword [edi + 0xc], esi
mov byte [esp + 0x4c], al
mov dword [edi + 0x10], edx
jmp 0x4ec752
mov ecx, dword [esp + 0x1c]
cmp dword [ecx + 4], 4
jae 0x4ec5ca
lea edi, [esp + 0x14]
call fcn.00401700
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov ecx, dword [ebx + 4]
mov edx, dword [esp + 0x20]
add ecx, dword [edx + 4]
mov ebp, dword [esp + 0x30]
add ecx, dword [esp + 0x18]
mov eax, ebp
call fcn.004e39f0
mov esi, eax
test esi, esi
jne 0x4ec8d9
mov esi, dword [ebp + 0x10]
cmp dword [esi + 0x14], eax
je 0x4ec653
lea ebp, [eax + 4]
mov eax, dword [esi + 0x1c]
cmp eax, ebp
jb 0x4ec609
mov ecx, dword [esi + 0x18]
lea edx, [ecx + 4]
cmp edx, eax
jbe 0x4ec612
mov ecx, dword [esi + 0x18]
sub eax, ecx
mov ebp, eax
je 0x4ec62e
mov eax, dword [esi + 0x14]
add ecx, eax
push ebp
push ecx
lea eax, [esp + 0x30]
push eax
call fcn.0060d1b0
add dword [esi + 0x18], ebp
add esp, 0xc
cmp ebp, 4
je 0x4ec688
lea edi, [esp + 0x14]
mov esi, 2
call fcn.00401700
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov ecx, dword [esi + 4]
push ecx
push 1
lea edx, [esp + 0x30]
push 4
push edx
call fcn.0060860a
add esp, 0x10
test eax, eax
je 0x4ec670
xor esi, esi
jmp 0x4ec680
cmp dword [esi + 4], 0
je 0x4ec67d
mov esi, 2
jmp 0x4ec680
mov esi, dword [esi + 0xc]
test esi, esi
jne 0x4ec8d9
mov eax, dword [esp + 0x1c]
mov eax, dword [eax + 4]
mov esi, dword [esp + 0x28]
cmp esi, eax
mov dword [esp + 0x34], eax
ja case.default.0x4ec4fe
mov ecx, dword [esp + 0x20]
mov edx, dword [ecx + 4]
mov ebp, dword [ebx + 0x18]
add edx, dword [esp + 0x18]
lea eax, [esi + 2]
mov dword [esp + 0x48], eax
mov al, 1
mov ecx, ebx
call fcn.004dd1a0
mov ecx, dword [esp + 0x34]
mov dword [edi], ebp
mov dword [edi + 4], edx
mov edx, dword [esp + 0x48]
mov dword [edi + 8], ecx
mov dword [edi + 0xc], esi
mov byte [esp + 0x4c], al
mov dword [edi + 0x10], edx
jmp 0x4ec752
mov eax, dword [ebx + 8]
mov ecx, dword [esp + 0x20]
mov ebp, dword [ecx + 4]
mov edx, dword [esp + 0x1c]
mov ecx, dword [edx + 4]
add ebp, eax
add ebp, dword [esp + 0x18]
sub ecx, eax
mov eax, dword [esp + 0x30]
mov dword [esp + 0x28], ecx
mov ecx, ebp
call fcn.004e39f0
mov esi, eax
test esi, esi
jne 0x4ec8d9
mov edx, dword [esp + 0x30]
mov esi, dword [edx + 0x10]
lea eax, [esp + 0x27]
push eax
lea ecx, [esp + 0x38]
push ecx
call fcn.004dcfa0
mov esi, eax
add esp, 8
test esi, esi
jne 0x4ec8d9
mov ebx, dword [ebx + 0x18]
mov eax, dword [esp + 0x34]
mov edx, dword [esp + 0x28]
mov cl, byte [esp + 0x27]
mov dword [edi], ebx
mov dword [edi + 4], ebp
mov dword [edi + 8], edx
lea esi, [eax + 2]
mov dword [edi + 0xc], eax
mov byte [esp + 0x4c], cl
mov dword [edi + 0x10], esi
mov eax, dword [esp + 0x4c]
mov dword [edi + 0x14], eax
mov eax, dword [esp + 0x2c]
cmp eax, 0x1f
jb 0x4ec785
lea edi, [esp + 0x14]
call fcn.00401700
mov eax, 9
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
lea edi, [eax*8]
sub edi, eax
cmp dword [edi*4 + 0x6a1550], 5
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax]
mov edx, dword [eax + 8]
lea edi, [edi*4 + 0x6a1540]
mov dword [esp + 0x50], ecx
mov ecx, dword [eax + 4]
mov dword [esp + 0x34], edi
mov dword [esp + 0x54], ecx
mov dword [esp + 0x58], edx
je 0x4ec7ce
mov eax, dword [edi + 8]
cmp eax, 1
jae 0x4ec7c8
mov eax, 1
mov ecx, eax
mov dword [esp + 0x54], ecx
cmp ecx, 4
mov esi, dword [esp + 0x20]
ja 0x4ec872
mov ecx, dword [esi + 4]
add ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x30]
call fcn.004e39f0
mov ebx, eax
test ebx, ebx
je 0x4ec811
lea edi, [esp + 0x14]
call fcn.00401700
mov eax, ebx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x6c]
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc
mov ecx, dword [esp + 0x30]
mov edi, dword [ecx + 0x10]
cmp dword [edi + 0x14], 0
mov eax, dword [esp + 0x54]
mov ebp, eax
je 0x4ec838
lea ebx, [esp + 0x58]
call fcn.00410220
cmp eax, ebp
je 0x4ec86e
mov ebx, 2
jmp 0x4ec7f1
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x4ec858
push ecx
push 1
push eax
lea edx, [esp + 0x64]
push edx
call fcn.0060860a
add esp, 0x10
test eax, eax
je 0x4ec858
xor edi, edi
jmp 0x4ec868
cmp dword [edi + 4], 0
je 0x4ec865
mov edi, 2
jmp 0x4ec868
mov edi, dword [edi + 0xc]
test edi, edi
mov ebx, edi
jne 0x4ec7f1
mov edi, dword [esp + 0x34]
mov ecx, dword [esi + 4]
mov eax, dword [esi]
mov edx, dword [esi + 8]
mov dword [esp + 0x38], eax
mov eax, dword [esi + 0xc]
mov dword [esp + 0x3c], ecx
mov ecx, dword [esi + 0x10]
mov dword [esp + 0x40], edx
mov edx, dword [esi + 0x14]
mov dword [esp + 0x44], eax
mov eax, dword [edi + 0xc]
push 0x45
mov dword [esp + 0x4c], ecx
lea ecx, [esp + 0x54]
mov dword [esp + 0x50], edx
push ecx
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x38]
lea edx, [esp + 0x40]
push edx
push eax
mov eax, dword [esp + 0x9c]
call fcn.004eefa0
mov esi, eax
test esi, esi
jne 0x4ec8d9
xor ecx, ecx
cmp dword [edi + 0x10], 5
setne cl
sub ecx, 1
and ecx, 0xf4240
mov esi, ecx
lea edi, [esp + 0x14]
call fcn.00401700
mov ecx, dword [esp + 0x7c]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00607d6d
add esp, 0x70
ret 0xc