Function at 0x4af5e0
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x614fd8
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x68e4d8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x40], ecx
xor eax, eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x3c], 0xffffffff
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x30], ecx
cmp dword [ebp + 8], 0x200000
ja 0x4af69c
mov dword [ebp - 0x34], 1
mov edx, dword [ebp + 8]
push edx
call fcn.005b0f0c
add esp, 4
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
je 0x4af69c
mov eax, dword [ebp - 0x40]
add eax, 8
push eax
lea ecx, [ebp - 0x48]
call fcn.004af050
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x2c]
push ecx
mov ecx, dword [ebp - 0x40]
call fcn.004af320
mov edx, dword [ebp - 0x3c]
mov dword [eax], edx
mov ecx, dword [ebp - 0x38]
mov dword [eax + 4], ecx
mov edx, dword [ebp - 0x34]
mov dword [eax + 8], edx
mov ecx, dword [ebp - 0x30]
mov dword [eax + 0xc], ecx
mov edx, dword [ebp - 0x2c]
mov dword [eax + 0x10], edx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x48]
call fcn.004af1f0
cmp dword [ebp - 0x2c], 0
jne 0x4af864
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x44], 0
lea eax, [ebp - 0x28]
push eax
call fcn.004af9b0
add esp, 4
mov dword [ebp - 4], 1
push 0
push 0x4000100
push 2
push 0
push 0
push 0xc0000000
lea ecx, [ebp - 0x28]
call fcn.0040e830
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0xffffffff
jne 0x4af705
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
jmp 0x4af819
push 0
push 0
mov ecx, dword [ebp - 0x30]
push ecx
mov edx, dword [ebp - 0x3c]
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0xffffffff
jne 0x4af734
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
jmp 0x4af819
mov eax, dword [ebp - 0x3c]
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x4af756
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
jmp 0x4af819
push 0
push 0
push 0
push 4
push 0
mov ecx, dword [ebp - 0x3c]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
jne 0x4af787
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
jmp 0x4af819
push 0
push 0
push 0
push 6
mov edx, dword [ebp - 0x38]
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
jne 0x4af7b3
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
jmp 0x4af819
mov eax, dword [ebp - 0x40]
add eax, 8
push eax
lea ecx, [ebp - 0x50]
call fcn.004af050
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x2c]
push ecx
mov ecx, dword [ebp - 0x40]
call fcn.004af320
mov edx, dword [ebp - 0x3c]
mov dword [eax], edx
mov ecx, dword [ebp - 0x38]
mov dword [eax + 4], ecx
mov edx, dword [ebp - 0x34]
mov dword [eax + 8], edx
mov ecx, dword [ebp - 0x30]
mov dword [eax + 0xc], ecx
mov edx, dword [ebp - 0x2c]
mov dword [eax + 0x10], edx
mov dword [ebp - 0x44], 1
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x50]
call fcn.004af1f0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0040ea10
xor eax, eax
jne 0x4af6b4
cmp dword [ebp - 0x44], 0
jne 0x4af864
cmp dword [ebp - 0x2c], 0
je 0x4af836
mov ecx, dword [ebp - 0x2c]
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [ebp - 0x2c], 0
cmp dword [ebp - 0x38], 0
je 0x4af84d
mov edx, dword [ebp - 0x38]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x38], 0
cmp dword [ebp - 0x3c], 0xffffffff
je 0x4af864
mov eax, dword [ebp - 0x3c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x3c], 0xffffffff
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005367cc
mov esp, ebp
pop ebp
ret 4