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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x60
mov esi, ecx
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
mov eax, dword [0x8af4c0]
xor eax, ebp
mov dword [esp + 0x58], eax
mov eax, edx
and eax, ecx
cmp eax, 0xffffffff
je 0x40ab3c
mov dword [esi + 0x28], edx
mov dword [esi + 0x2c], ecx
movzx eax, byte [esi]
mov byte [esp + 0xb], al
mov eax, dword [esi + 0xd4]
mov dword [esp + 0x24], 0
mov dword [esp + 0x38], 0
test eax, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x1c], eax
je 0x40ab51
mov ecx, dword [eax + 0x18]
mov dword [esp + 4], ecx
cmp dword [eax + 0x4c], ecx
jae 0x40ab46
mov eax, dword [esp + 0x1c]
mov eax, dword [eax + 0x50]
mov edi, 9
test al, 2
jne 0x40aee4
test al, 1
jne 0x40aefb
mov eax, dword [esp + 0x1c]
mov eax, dword [eax + 0x44]
test eax, eax
je 0x40aefb
push dword [esp + 4]
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x40af10
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x18], eax
mov dword [edx + 0x44], eax
mov ecx, dword [esp + 4]
mov dword [edx + 0x4c], ecx
mov ecx, dword [esi + 0x7c]
test ecx, ecx
je 0x40ab46
mov eax, dword [esi + 0x78]
mov edx, dword [esp + 0x18]
add dword [esp + 4], edx
shl ecx, 2
xor edi, edi
mov dword [esp + 0x20], eax
jmp 0x40ab07
add edi, 4
cmp ecx, edi
je 0x40ab46
mov ebx, dword [eax + edi]
cmp byte [ebx + 8], 1
jne 0x40ab00
mov edx, dword [esp + 0x1c]
cmp dword [ebx + 0x68], edx
jne 0x40ab00
mov esi, dword [ebx + 0x74]
sub esi, dword [ebx + 0x6c]
mov eax, dword [esp + 0x18]
mov dword [ebx + 0x6c], eax
mov edx, dword [esp + 4]
mov dword [ebx + 0x70], edx
add esi, eax
mov eax, dword [esp + 0x20]
mov dword [ebx + 0x74], esi
mov esi, dword [esp + 0x14]
jmp 0x40ab00
mov edi, 2
jmp 0x40aee4
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax + 0x44]
mov dword [esp + 0x38], ecx
mov eax, dword [esi + 0xac]
test eax, eax
je 0x40ae9e
mov ecx, dword [esi + 0xa8]
lea eax, [ecx + eax*4]
mov dword [esp + 0x48], eax
movzx eax, byte [esp + 0xb]
and al, 1
movzx eax, al
xor eax, 3
mov dword [esp + 0x44], eax
mov dword [esp + 0x24], 0
jmp 0x40abcb
mov dword [esp + 0xc], 0x17
mov esi, dword [esp + 0x14]
mov ebx, dword [esp + 4]
mov edi, dword [esp + 0x18]
mov ecx, dword [esp + 0x28]
add ebx, 8
add edx, dword [esp + 0x20]
push ebx
push ecx
push edi
push edx
call fcn.00412800
add esp, 0x10
test al, al
je 0x40aee0
mov ecx, dword [esp + 0x4c]
add ecx, 4
cmp ecx, dword [esp + 0x48]
je 0x40ae9e
mov ebx, dword [ecx]
mov edi, dword [ebx + 4]
test edi, edi
je 0x40abbe
mov dword [esp + 0x4c], ecx
mov eax, dword [esi + 0x84]
mov ecx, dword [ebx + 0x14]
cmp ecx, 0xffffffff
je 0x40abf0
mov ecx, dword [eax + ecx*4]
mov dword [esp + 0x10], ecx
jmp 0x40abf8
mov dword [esp + 0x10], 0
mov ecx, dword [ebx + 0x10]
mov edx, dword [eax + ecx*4]
mov eax, dword [ebx + 0x20]
mov ecx, dword [ebx + 0x24]
mov dword [esp + 0x28], ecx
mov dword [esp + 0x54], ecx
mov dword [esp + 0x18], eax
mov dword [esp + 0x50], eax
mov eax, dword [edx + 0x48]
mov ecx, dword [ebx + 0x18]
cmp ecx, eax
mov esi, dword [ebx + 0x1c]
mov dword [esp + 0x30], esi
sbb esi, 0
jae case.default.0x40ac57
mov dword [esp + 4], ebx
movzx ebx, byte [ebx + 0xa]
sub eax, ecx
cmp eax, ebx
jb case.default.0x40ac57
dec edi
cmp edi, 4
ja case.default.0x40ac57
mov esi, ecx
mov ecx, dword [edx + 0x14]
mov eax, dword [edx + 0x10]
mov edx, dword [edx + 0x44]
mov dword [esp + 0x20], esi
jmp dword [edi*4 + 0x7917fc]
mov dword [esp + 0x10], edx
mov ecx, dword [esp + 0x18]
lea edx, [esp + 0x50]
call fcn.0040af30
test eax, eax
jne 0x40af17
mov dword [esp + 0xc], 0x17
mov edi, dword [esp + 0x50]
mov ecx, dword [esp + 0x54]
jmp 0x40ad89
mov dword [esp + 0xc], 0x17
mov eax, dword [esp + 0x10]
test eax, eax
je 0x40aee0
mov edi, dword [esp + 0x18]
add edi, dword [ebp + 8]
mov ecx, dword [esp + 0x28]
adc ecx, dword [ebp + 0xc]
add edi, dword [eax + 0x10]
adc ecx, dword [eax + 0x14]
mov esi, dword [esp + 0x14]
mov ebx, dword [esp + 4]
jmp 0x40ab9f
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], 0x17
add eax, dword [ebp + 8]
adc ecx, dword [ebp + 0xc]
add eax, esi
adc ecx, dword [esp + 0x30]
add eax, ebx
adc ecx, 0
mov edi, dword [esp + 0x18]
sub edi, eax
mov edx, ecx
mov ecx, dword [esp + 0x28]
sbb ecx, edx
test byte [esp + 0xb], 1
jne 0x40ad84
mov edx, edi
sar edx, 0x1f
xor edx, ecx
mov esi, dword [esp + 0x14]
mov ebx, dword [esp + 4]
mov edx, dword [esp + 0x10]
je 0x40ab9f
jmp 0x40af1b
mov dword [esp + 0x2c], eax
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], 0x17
mov eax, dword [esp + 4]
cmp byte [eax + 0xb], 4
jne 0x40aee0
movzx eax, byte [eax + 0xc]
add eax, esi
mov dword [esp + 0x34], eax
cmp eax, 2
jb 0x40aee0
mov edx, dword [esp + 0x2c]
add edx, dword [ebp + 8]
mov dword [esp + 0x3c], ecx
mov edi, ecx
adc edi, dword [ebp + 0xc]
add edx, esi
adc edi, dword [esp + 0x30]
mov dword [esp + 0x40], ebx
add edx, ebx
adc edi, 0
mov eax, dword [esp + 0x18]
mov ebx, eax
sub ebx, edx
mov ecx, dword [esp + 0x28]
mov edx, ecx
sbb edx, edi
mov esi, ebx
sar esi, 0x1f
xor esi, edx
jne 0x40ad9a
mov edi, ebx
mov ecx, edx
jmp 0x40ad89
mov ecx, edi
sar ecx, 0x1f
mov esi, dword [esp + 0x14]
mov ebx, dword [esp + 4]
mov edx, dword [esp + 0x10]
jmp 0x40ab9f
mov edx, dword [esp + 0x14]
mov edi, dword [edx + 0xd8]
test edi, edi
je 0x40aee0
nop dword [eax]
mov edx, dword [edi + 8]
mov esi, dword [edi + 0xc]
cmp eax, edx
mov ebx, ecx
sbb ebx, esi
setb bl
cmp edx, eax
sbb esi, ecx
movzx edx, bl
sbb edx, 0
je 0x40addb
shr edx, 0x1f
mov edi, dword [edi + edx*4]
and edi, 0xfffffffe
jne 0x40adb0
jmp 0x40aee0
mov edx, dword [edi + 0x10]
cmp edx, 0xffffffff
jne 0x40adf1
mov eax, dword [esp + 0x24]
mov dword [edi + 0x10], eax
mov edx, eax
inc eax
mov dword [esp + 0x24], eax
mov esi, dword [esp + 0x14]
mov ebx, dword [esp + 4]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x44]
shl edx, cl
mov dword [esp + 4], edx
mov ecx, dword [esp + 0x20]
add ecx, eax
mov edi, dword [esp + 0x30]
adc edi, dword [esp + 0x3c]
add ecx, dword [esp + 0x40]
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x10]
adc edi, 0
sub edx, ecx
mov ecx, dword [eax + 0x14]
mov eax, edx
sbb ecx, edi
mov edx, dword [esp + 4]
add eax, edx
adc ecx, 0
mov edx, eax
sar edx, 0x1f
xor edx, ecx
jne 0x40af1b
mov dword [esp + 0x18], eax
mov edi, dword [esp + 0x10]
mov edx, dword [esp + 0x34]
mov eax, edi
movzx edi, byte [edx + edi - 1]
mov dl, 0x15
cmp edi, 0xe8
je 0x40ae69
cmp edi, 0xe9
jne 0x40aee0
mov dl, 0x25
mov edi, dword [esp + 0x34]
mov byte [eax + edi - 2], 0xff
mov byte [eax + edi - 1], dl
movsd xmm0, qword [ebx + 0x20]
mov edx, dword [esp + 0x38]
mov edi, dword [esp + 4]
movsd qword [edx + edi], xmm0
mov edx, ecx
mov ecx, dword [ebx + 0x18]
mov dword [esp + 0x20], ecx
mov ecx, edx
mov edx, eax
mov edi, dword [esp + 0x18]
jmp 0x40ab9f
mov eax, dword [esi + 0x90]
mov ecx, dword [esi + 0x94]
mov edx, dword [esp + 0x1c]
cmp dword [eax + ecx*4 - 4], edx
jne 0x40aed4
mov eax, edx
movzx ecx, byte [esp + 0xb]
and cl, 1
xor cl, 3
mov edx, dword [esp + 0x24]
shl edx, cl
mov dword [eax + 0x48], edx
mov dword [eax + 0x18], edx
mov dword [eax + 0x1c], 0
xor edi, edi
jmp 0x40aee4
mov dword [esp + 0xc], 0x17
mov edi, dword [esp + 0xc]
mov ecx, dword [esp + 0x58]
xor ecx, ebp
call fcn.0055e764
mov eax, edi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret 8
push dword [esp + 4]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
add esp, 4
test eax, eax
jne 0x40aad0
mov edi, 1
jmp 0x40aee4
mov edi, eax
jmp 0x40aee4
mov dword [esp + 0xc], 0x18
jmp 0x40aee0