Function at 0x4705f0
Capabilities:
Check if file exists
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x350
mov eax, dword [0x68e4d8]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x320], ecx
mov eax, dword [ebp - 0x320]
cmp dword [eax + 0x10], 0
jne 0x47061c
xor eax, eax
jmp 0x470a9c
cmp dword [ebp + 8], 0
je 0x470630
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x470637
xor eax, eax
jmp 0x470a9c
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
mov dword [ebp - 0x334], eax
cmp dword [ebp + 0xc], 0
je 0x470666
mov eax, dword [ebp + 0xc]
push eax
call fcn.005afdb4
add esp, 4
test eax, eax
jbe 0x470666
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x334], ecx
push 0x697b18
push 0x2e
call fcn.0053762b
add esp, 8
mov dword [ebp - 0x344], eax
mov edx, dword [ebp - 0x344]
mov dword [ebp - 0x31c], edx
push 0x2e
push 0
mov eax, dword [ebp - 0x31c]
push eax
call fcn.0058abd0
add esp, 0xc
mov ecx, dword [ebp - 0x31c]
mov dword [ecx], 0x2014b50
mov edx, 0x1400
mov eax, dword [ebp - 0x31c]
mov word [eax + 4], dx
mov ecx, 0x14
mov edx, dword [ebp - 0x31c]
mov word [edx + 6], cx
xor eax, eax
mov ecx, dword [ebp - 0x31c]
mov word [ecx + 8], ax
xor edx, edx
mov eax, dword [ebp - 0x31c]
mov word [eax + 0x1e], dx
xor ecx, ecx
mov edx, dword [ebp - 0x31c]
mov word [edx + 0x20], cx
xor eax, eax
mov ecx, dword [ebp - 0x31c]
mov word [ecx + 0x22], ax
xor edx, edx
mov eax, dword [ebp - 0x31c]
mov word [eax + 0x24], dx
push 0x314
push 0
lea ecx, [ebp - 0x318]
push ecx
call fcn.0058abd0
add esp, 0xc
mov edx, dword [ebp - 0x31c]
mov dword [ebp - 0x318], edx
mov eax, dword [ebp - 0x334]
push eax
push 0x104
lea ecx, [ebp - 0x314]
push ecx
call fcn.005b0cd4
add esp, 0xc
mov dword [ebp - 0x330], 0
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
je 0x470807
xor eax, eax
mov ecx, dword [ebp - 0x31c]
mov word [ecx + 0xa], ax
mov edx, dword [ebp - 0x31c]
mov dword [edx + 0x10], 0
mov eax, dword [ebp - 0x31c]
mov dword [eax + 0x14], 0
mov ecx, dword [ebp - 0x31c]
mov dword [ecx + 0x18], 0
mov edx, dword [ebp - 0x31c]
add edx, 0xc
push edx
mov eax, dword [ebp - 0x31c]
add eax, 0xe
push eax
mov ecx, dword [ebp - 0x320]
call fcn.00471100
mov ecx, dword [ebp - 0x31c]
mov dword [ecx + 0x26], 0x10
push 0x630a7c
push 0x104
lea edx, [ebp - 0x314]
push edx
call fcn.005b0db0
add esp, 0xc
lea eax, [ebp - 0x318]
push eax
mov ecx, dword [ebp - 0x320]
add ecx, 0x1c
call fcn.00473210
mov ecx, dword [ebp - 0x334]
push ecx
mov edx, dword [ebp + 8]
push edx
mov ecx, dword [ebp - 0x320]
call fcn.00470390
mov dword [ebp - 0x330], eax
jmp 0x470a70
mov dword [ebp - 0x324], 0xffffffff
mov dword [ebp - 0x32c], 0
mov dword [ebp - 0x328], 0
mov eax, dword [ebp - 0x31c]
mov dword [eax + 0x26], 0x20
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x324], eax
cmp dword [ebp - 0x324], 0xffffffff
jne 0x470862
jmp 0x470a2e
push 0
mov edx, dword [ebp - 0x324]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, dword [ebp - 0x31c]
mov dword [ecx + 0x18], eax
lea edx, [ebp - 0x350]
push edx
push 0
push 0
mov eax, dword [ebp - 0x324]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileTime]
test eax, eax
je 0x4708b9
mov ecx, dword [ebp - 0x31c]
add ecx, 0xc
push ecx
mov edx, dword [ebp - 0x31c]
add edx, 0xe
push edx
lea eax, [ebp - 0x350]
push eax
call dword [sym.imp.KERNEL32.dll_FileTimeToDosDateTime]
jmp 0x4708d8
mov ecx, dword [ebp - 0x31c]
add ecx, 0xc
push ecx
mov edx, dword [ebp - 0x31c]
add edx, 0xe
push edx
mov ecx, dword [ebp - 0x320]
call fcn.00471100
mov eax, dword [ebp - 0x31c]
cmp dword [eax + 0x18], 0
jne 0x47090f
xor ecx, ecx
mov edx, dword [ebp - 0x31c]
mov word [edx + 0xa], cx
mov eax, dword [ebp - 0x31c]
mov dword [eax + 0x14], 0
mov ecx, dword [ebp - 0x31c]
mov dword [ecx + 0x10], 0
jmp 0x470a07
mov edx, 8
mov eax, dword [ebp - 0x31c]
mov word [eax + 0xa], dx
push 0
push 0
push 0
push 2
push 0
mov ecx, dword [ebp - 0x324]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x32c], eax
cmp dword [ebp - 0x32c], 0
jne 0x470949
jmp 0x470a2e
push 0
push 0
push 0
push 4
mov edx, dword [ebp - 0x32c]
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x328], eax
cmp dword [ebp - 0x328], 0
jne 0x470972
jmp 0x470a2e
mov eax, dword [ebp - 0x31c]
mov ecx, dword [eax + 0x18]
mov dword [ebp - 0x33c], ecx
mov dword [ebp - 0x338], 0
lea edx, [ebp - 0x33c]
push edx
lea eax, [ebp - 0x338]
push eax
mov ecx, dword [ebp - 0x320]
call fcn.00470e40
test eax, eax
jne 0x4709ad
jmp 0x470a2e
mov ecx, dword [ebp - 0x31c]
add ecx, 0x10
push ecx
mov edx, dword [ebp - 0x33c]
push edx
mov eax, dword [ebp - 0x338]
push eax
mov ecx, dword [ebp - 0x31c]
mov edx, dword [ecx + 0x18]
push edx
mov eax, dword [ebp - 0x328]
push eax
call fcn.004ad740
add esp, 0x14
mov dword [ebp - 0x340], eax
cmp dword [ebp - 0x340], 0xffffffff
jne 0x4709ef
jmp 0x470a2e
mov ecx, dword [ebp - 0x31c]
mov edx, dword [ebp - 0x340]
mov dword [ecx + 0x14], edx
mov eax, dword [ebp - 0x338]
mov dword [ebp - 8], eax
lea ecx, [ebp - 0x318]
push ecx
mov ecx, dword [ebp - 0x320]
add ecx, 0x1c
call fcn.00473210
mov dword [ebp - 0x330], 1
xor edx, edx
jne 0x470825
cmp dword [ebp - 0x328], 0
je 0x470a44
mov eax, dword [ebp - 0x328]
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
cmp dword [ebp - 0x32c], 0
je 0x470a5a
mov ecx, dword [ebp - 0x32c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x324], 0xffffffff
je 0x470a70
mov edx, dword [ebp - 0x324]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x330], 0
jne 0x470a96
mov eax, dword [ebp - 0x31c]
mov dword [ebp - 0x348], eax
push 0x2e
mov ecx, dword [ebp - 0x348]
push ecx
call fcn.00537023
add esp, 8
mov eax, dword [ebp - 0x330]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005367cc
mov esp, ebp
pop ebp
ret 8