Function at 0x57ec40
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x1c
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x10], 1
mov ebx, dword [ebp + 8]
mov esi, dword [ebp + 0x14]
test eax, eax
je 0x57efe0
cmp byte [eax], 0x31
setne al
cmp dword [ebp + 0x24], 0x38
setne dl
or eax, edx
test al, 1
jne 0x57efe0
test ebx, ebx
mov eax, 0xfffffffe
je 0x57efe5
mov dword [ebx + 0x18], 0
mov ecx, dword [ebx + 0x20]
test ecx, ecx
jne 0x57eca1
mov dword [ebx + 0x20], 0x583100
mov dword [ebx + 0x28], 0
mov edi, dword [ebx + 0x24]
test edi, edi
jne 0x57ecaf
mov dword [ebx + 0x24], 0x583120
cmp dword [ebp + 0xc], 0xffffffff
je 0x57f000
test esi, esi
js 0x57f010
cmp esi, 0xf
jg 0x57eff0
mov ecx, dword [ebp + 0x18]
dec ecx
cmp ecx, 8
seta dl
cmp dword [ebp + 0x10], 8
setne al
or eax, edx
test al, 1
jne 0x57f028
cmp esi, 7
setle al
cmp esi, 0xf
setg dl
or eax, edx
test al, 1
jne 0x57f028
mov edi, dword [ebp + 0xc]
xor ecx, ecx
shr edi, 0x1f
cmp dword [ebp + 0xc], 9
setg cl
or edi, ecx
jne 0x57f028
mov eax, dword [ebp + 0x1c]
xor edx, edx
shr eax, 0x1f
cmp dword [ebp + 0x1c], 4
setg dl
or eax, edx
jne 0x57f028
cmp esi, 8
je 0x57f01e
mov edx, 0x16c0
mov edi, 1
mov dword [esp + 4], edi
mov dword [esp + 8], edx
mov ecx, dword [ebx + 0x28]
mov dword [esp], ecx
call dword [ebx + 0x20]
mov edi, eax
test edi, edi
mov eax, 0xfffffffc
je 0x57efe5
mov dword [edi + 0x30], esi
mov ecx, esi
mov eax, 1
mov dword [ebx + 0x1c], edi
mov edx, dword [ebp - 0x10]
shl eax, cl
mov dword [edi + 0x2c], eax
mov ecx, dword [ebp + 0x18]
dec eax
mov dword [edi + 0x34], eax
mov esi, dword [ebp + 0x18]
mov eax, 0xaaaaaaab
mov dword [edi + 0x18], edx
add ecx, 7
mov edx, 1
mov dword [edi + 0x50], ecx
shl edx, cl
add esi, 9
mov dword [edi + 0x4c], edx
mov ecx, edx
dec ecx
mul esi
mov esi, 2
mov dword [edi + 0x54], ecx
mov dword [edi], ebx
shr edx, 1
mov dword [edi + 0x58], edx
mov edx, 2
mov dword [edi + 0x1c], 0
mov dword [ebp - 0x14], 1
mov dword [esp + 8], edx
mov ecx, dword [edi + 0x2c]
mov dword [esp + 4], ecx
mov eax, dword [ebx + 0x28]
mov dword [esp], eax
call dword [ebx + 0x20]
mov dword [edi + 0x38], eax
mov dword [esp + 8], esi
mov edx, dword [edi + 0x2c]
mov dword [esp + 4], edx
mov ecx, dword [ebx + 0x28]
mov dword [esp], ecx
call dword [ebx + 0x20]
mov dword [edi + 0x40], eax
mov eax, 2
mov dword [esp + 8], eax
mov esi, dword [edi + 0x4c]
mov dword [esp + 4], esi
mov edx, dword [ebx + 0x28]
mov esi, 4
mov dword [esp], edx
call dword [ebx + 0x20]
mov ecx, dword [ebp + 0x18]
add ecx, 6
shl dword [ebp - 0x14], cl
mov dword [edi + 0x44], eax
mov eax, dword [ebp - 0x14]
mov dword [edi + 0x169c], eax
mov dword [esp + 8], esi
mov edx, dword [edi + 0x169c]
mov dword [esp + 4], edx
mov ecx, dword [ebx + 0x28]
mov dword [esp], ecx
call dword [ebx + 0x20]
mov edx, dword [edi + 0x169c]
mov esi, dword [edi + 0x38]
mov ecx, eax
mov dword [edi + 8], eax
test esi, esi
lea eax, [edx*4]
mov dword [edi + 0xc], eax
je 0x57f035
mov esi, dword [edi + 0x40]
test esi, esi
je 0x57f035
mov eax, dword [edi + 0x44]
test eax, eax
je 0x57f035
test ecx, ecx
je 0x57f035
mov eax, edx
lea esi, [edx + edx*2]
and eax, 0xfffffffe
add eax, ecx
lea edx, [ecx + esi]
mov esi, dword [ebp + 0x1c]
movzx ecx, byte [ebp + 0x10]
mov dword [edi + 0x16a4], eax
mov eax, dword [ebp + 0xc]
test ebx, ebx
mov dword [edi + 0x1698], edx
mov dword [edi + 0x88], esi
mov dword [edi + 0x84], eax
mov byte [edi + 0x24], cl
je 0x57f028
mov esi, dword [ebx + 0x1c]
test esi, esi
je 0x57f028
mov edi, dword [ebx + 0x20]
test edi, edi
je 0x57f028
mov ecx, dword [ebx + 0x24]
test ecx, ecx
je 0x57f028
mov dword [ebx + 0x2c], 2
mov edx, dword [esi + 8]
mov dword [ebx + 0x14], 0
mov dword [ebx + 8], 0
mov dword [esi + 0x10], edx
mov edx, dword [esi + 0x18]
mov dword [ebx + 0x18], 0
mov dword [esi + 0x14], 0
test edx, edx
js 0x57f13a
cmp edx, 1
sbb eax, eax
and eax, 0x47
add eax, 0x2a
cmp edx, 2
mov dword [esi + 4], eax
je 0x57f11d
mov dword [esp], 0
xor eax, eax
xor edx, edx
mov dword [esp + 8], eax
mov dword [esp + 4], edx
call fcn.00585770
mov dword [ebx + 0x30], eax
mov dword [esi + 0x28], 0
mov dword [esp], esi
call fcn.00583140
mov eax, dword [esi + 0x2c]
xor ecx, ecx
mov ebx, dword [esi + 0x4c]
mov edi, dword [esi + 0x44]
add eax, eax
lea edx, [ebx + ebx - 2]
mov word [edi + ebx*2 - 2], 0
mov dword [esi + 0x3c], eax
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
mov dword [esp], edi
call sub.msvcrt.dll_memset
mov dword [esi + 0x6c], 0
mov eax, dword [esi + 0x84]
mov dword [esi + 0x5c], 0
mov dword [esi + 0x74], 0
lea edi, [eax + eax*2]
shl edi, 2
movzx ebx, word [edi + 0x6c0e62]
xor eax, eax
movzx edx, word [edi + 0x6c0e60]
movzx ecx, word [edi + 0x6c0e64]
mov dword [esi + 0x78], 2
mov dword [esi + 0x80], ebx
movzx ebx, word [edi + 0x6c0e66]
mov dword [esi + 0x8c], edx
mov dword [esi + 0x90], ecx
mov dword [esi + 0x60], 2
mov dword [esi + 0x7c], ebx
mov dword [esi + 0x68], 0
mov dword [esi + 0x48], 0
jmp 0x57efe5
mov eax, 0xfffffffa
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [ebp - 0x10], 2
sub esi, 0x10
jmp 0x57ecca
mov dword [ebp + 0xc], 6
test esi, esi
jns 0x57ecc1
nop
mov dword [ebp - 0x10], 0
neg esi
jmp 0x57ecca
mov esi, 9
jmp 0x57ed32
add esp, 0x1c
mov eax, 0xfffffffe
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [edi + 4], 0x29a
mov edi, dword [str.insufficient_memory]
test ebx, ebx
mov dword [ebx + 0x18], edi
je 0x57f091
mov ecx, dword [ebx + 0x1c]
test ecx, ecx
je 0x57f091
mov esi, dword [ecx + 4]
cmp esi, 0x2a
setne al
xor edx, edx
cmp esi, 0x45
setne dl
test edx, eax
je 0x57f09b
cmp esi, 0x49
setne al
xor edx, edx
cmp esi, 0x5b
setne dl
test edx, eax
je 0x57f09b
cmp esi, 0x67
setne al
xor edx, edx
cmp esi, 0x71
setne dl
test edx, eax
je 0x57f09b
cmp esi, 0x29a
je 0x57f09b
mov eax, 0xfffffffc
jmp 0x57efe5
mov eax, dword [ecx + 8]
test eax, eax
jne 0x57f0d5
mov eax, dword [ecx + 0x44]
test eax, eax
jne 0x57f10b
mov eax, dword [ecx + 0x40]
test eax, eax
jne 0x57f0f9
mov eax, dword [ecx + 0x38]
test eax, eax
jne 0x57f0e7
mov dword [esp + 4], ecx
mov edx, dword [ebx + 0x28]
mov dword [esp], edx
call dword [ebx + 0x24]
mov dword [ebx + 0x1c], 0
mov eax, 0xfffffffc
jmp 0x57efe5
mov dword [esp + 4], eax
mov ecx, dword [ebx + 0x28]
mov dword [esp], ecx
call dword [ebx + 0x24]
mov ecx, dword [ebx + 0x1c]
jmp 0x57f0a2
mov dword [esp + 4], eax
mov eax, dword [ebx + 0x28]
mov dword [esp], eax
call dword [ebx + 0x24]
mov ecx, dword [ebx + 0x1c]
jmp 0x57f0b7
mov dword [esp + 4], eax
mov edi, dword [ebx + 0x28]
mov dword [esp], edi
call dword [ebx + 0x24]
mov ecx, dword [ebx + 0x1c]
jmp 0x57f0b0
mov dword [esp + 4], eax
mov esi, dword [ebx + 0x28]
mov dword [esp], esi
call dword [ebx + 0x24]
mov ecx, dword [ebx + 0x1c]
jmp 0x57f0a9
mov dword [esp], 0
xor ecx, ecx
xor edi, edi
mov dword [esp + 8], ecx
mov dword [esp + 4], edi
call fcn.005807b0
jmp 0x57ef31
neg edx
mov dword [esi + 0x18], edx
jmp 0x57ef02