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

Disassembly:
push ebp
mov ebp, dword [esp + 8]
mov eax, dword [ebp + 0x20]
mov eax, dword [eax + 0x88]
test eax, eax
push esi
je 0x42a1f8
cmp byte [eax], 0
jne 0x42a1fd
mov eax, 0x4727f1
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocStringLen
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x42a28c
push esi
call dword [sym.imp.KERNEL32.dll_GetFileType]
and eax, 0x7fff
cmp eax, 2
jne 0x42a268
mov ecx, dword [ebp + 0x20]
cmp dword [ecx + 0x80], 0
jne 0x42a25c
push 0
mov ecx, str.This_is_a_reserved_device_name_and_not_a_valid_file_name.
call fcn.00417350
mov edx, dword [ebp + 0x20]
mov dword [edx + 0x80], eax
mov eax, dword [ebp + 0x20]
add esp, 4
or dword [eax + 8], 0x10000
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x42a437
mov eax, dword [ebp + 0x20]
mov ecx, dword [eax + 0x84]
cmp ecx, dword [eax + 0x88]
jne 0x42a328
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 2
call dword [sym.imp.KERNEL32.dll_SetLastError]
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x42a2a5
cmp eax, 3
je 0x42a2a5
or dword [edi + 0x38], 0x40000
jmp 0x42a2f0
mov ecx, dword [ebp + 0x20]
or dword [ecx + 8], 0x80000
mov ecx, dword [edi + 0x50]
test ecx, ecx
je 0x42a2e9
cmp ecx, ebp
je 0x42a2e9
mov ecx, ebp
lea esp, [esp]
mov edx, dword [ecx + 0x10]
test dl, 8
jne 0x42a2dd
test dl, 0x20
jne 0x42a2e3
mov ecx, dword [ecx + 4]
test ecx, ecx
jne 0x42a2c0
or dword [edi + 0x38], 0x200
jmp 0x42a2f0
or dword [edi + 0x38], 2
jmp 0x42a2f0
or dword [edi + 0x38], 1
jmp 0x42a2f0
or dword [edi + 0x38], 0x20000
mov edx, dword [ebp + 0x20]
cmp dword [edx + 0x80], 0
jne 0x42a448
push eax
mov ecx, str.Error_opening_file.
call fcn.00417350
mov ecx, dword [ebp + 0x20]
add esp, 4
mov dword [ecx + 0x80], eax
mov ebp, dword [ebp + 0x20]
or dword [ebp + 8], 0x10000
pop esi
xor eax, eax
pop ebp
ret 4
push 0
push esi
mov byte [edi + 0x10], 1
mov dword [edi + 8], esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
test eax, eax
mov dword [edi + 0xc], eax
je 0x42a402
cmp eax, 0xffffffff
je 0x42a402
mov edx, dword [edi + 8]
push 0
push 0
push 0
push 2
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
test eax, eax
mov dword [edi + 0x14], eax
jne 0x42a3af
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp + 0x20]
cmp dword [ecx + 0x80], 0
jne 0x42a39a
push eax
mov ecx, str.Error_reading_file.
call fcn.00417350
mov edx, dword [ebp + 0x20]
mov dword [edx + 0x80], eax
mov ebp, dword [ebp + 0x20]
add esp, 4
or dword [ebp + 8], 0x10000
mov esi, edi
call fcn.0042a450
or dword [edi + 0x38], 0x40000
pop esi
xor eax, eax
pop ebp
ret 4
push 0
push 0
push 0
push 4
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
test eax, eax
mov dword [edi + 0x18], eax
jne 0x42a3f8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp + 0x20]
cmp dword [ecx + 0x80], 0
jne 0x42a3e3
mov ecx, str.Error_reading_file.
mov esi, ebp
call fcn.0042aa20
mov esi, edi
call fcn.0042a450
or dword [edi + 0x38], 0x40000
pop esi
xor eax, eax
pop ebp
ret 4
pop esi
mov eax, 1
pop ebp
ret 4
mov edx, dword [ebp + 0x20]
cmp dword [edx + 0x80], 0
jne 0x42a430
push 0
mov ecx, str.This_file_is_not_a_valid_32_bit_or_64_bit_Windows_module.
call fcn.00417350
mov ecx, dword [ebp + 0x20]
mov dword [ecx + 0x80], eax
mov eax, dword [ebp + 0x20]
add esp, 4
or dword [eax + 8], 0x10000
mov esi, edi
call fcn.0042a450
or dword [edi + 0x38], 0x100
mov ebp, dword [ebp + 0x20]
or dword [ebp + 8], 0x40000
pop esi
xor eax, eax
pop ebp
ret 4