Function at 0x140004a5c
Capabilities:
Get file size
Parse pe header
Read file on windows

Disassembly:
jmp 0x14007e8d0
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0xa8
mov rax, qword [0x14023c868]
xor rax, rsp
mov qword [rsp + 0x90], rax
lea rdx, [rsp + 0x58]
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
mov dword [rsp + 0x54], eax
cmp dword [rsp + 0x54], 0
jne 0x14007e925
mov eax, 0x200
jmp 0x14007ebd1
mov eax, dword [rsp + 0x58]
mov dword [rsp + 0x34], eax
mov dword [rsp + 0x30], 0
mov eax, dword [rsp + 0x34]
and eax, 1
test eax, eax
je 0x14007e94b
mov eax, dword [rsp + 0x30]
or eax, 1
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 2
test eax, eax
je 0x14007e961
mov eax, dword [rsp + 0x30]
or eax, 2
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 4
test eax, eax
je 0x14007e977
mov eax, dword [rsp + 0x30]
or eax, 4
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 0x10
test eax, eax
je 0x14007e98d
mov eax, dword [rsp + 0x30]
or eax, 0x10
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 0x20
test eax, eax
je 0x14007e9a3
mov eax, dword [rsp + 0x30]
or eax, 0x20
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 0x10
test eax, eax
je 0x14007e9bc
mov eax, dword [rsp + 0x30]
bts eax, 0x1e
mov dword [rsp + 0x30], eax
jmp 0x14007e9c8
mov eax, dword [rsp + 0x30]
bts eax, 0x1f
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x30]
bts eax, 0x18
mov dword [rsp + 0x30], eax
mov eax, dword [rsp + 0x34]
and eax, 1
test eax, eax
je 0x14007e9e1
jmp 0x14007e9ed
mov eax, dword [rsp + 0x30]
bts eax, 0x17
mov dword [rsp + 0x30], eax
xor edx, edx
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0x48], eax
cmp dword [rsp + 0x48], 0x28
jbe 0x14007eb19
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x50]
mov r8d, 2
lea rdx, [rsp + 0x3c]
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor r9d, r9d
xor r8d, r8d
mov edx, 0x24
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x50]
mov r8d, 4
lea rdx, [rsp + 0x4c]
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_ReadFile]
movzx eax, word [rsp + 0x3c]
cmp eax, 0x54ad
jne 0x14007eb19
mov eax, dword [rsp + 0x4c]
add eax, 0x34
cmp dword [rsp + 0x48], eax
jbe 0x14007eb19
xor r9d, r9d
xor r8d, r8d
mov edx, dword [rsp + 0x4c]
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x50]
mov r8d, 4
lea rdx, [rsp + 0x38]
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [rsp + 0x38], 0x5a4d
je 0x14007eb0d
cmp dword [rsp + 0x38], 0x454e
je 0x14007eb0d
cmp dword [rsp + 0x38], 0x454c
je 0x14007eb0d
cmp dword [rsp + 0x38], 0x4550
jne 0x14007eb19
mov eax, dword [rsp + 0x30]
bts eax, 0x16
mov dword [rsp + 0x30], eax
cmp qword [rsp + 0xb8], 0
je 0x14007eb32
mov rax, qword [rsp + 0xb8]
mov ecx, dword [rsp + 0x30]
mov dword [rax], ecx
cmp qword [rsp + 0xc0], 0
je 0x14007eb4b
mov rax, qword [rsp + 0xc0]
mov ecx, dword [rsp + 0x48]
mov dword [rax], ecx
cmp qword [rsp + 0xc8], 0
je 0x14007eb97
mov rcx, qword [rsp + 0x64]
call fcn.1400099bc
mov rcx, qword [rsp + 0xc8]
mov qword [rcx], rax
mov rcx, qword [rsp + 0x6c]
call fcn.1400099bc
mov rcx, qword [rsp + 0xc8]
mov qword [rcx + 8], rax
mov rcx, qword [rsp + 0x5c]
call fcn.1400099bc
mov rcx, qword [rsp + 0xc8]
mov qword [rcx + 0x10], rax
cmp qword [rsp + 0xd0], 0
je 0x14007ebcf
lea r8, [rsp + 0x40]
lea rdx, [rsp + 0x44]
mov rcx, qword [rsp + 0x6c]
call fcn.140007d47
movzx eax, word [rsp + 0x40]
movzx ecx, word [rsp + 0x44]
shl ecx, 0x10
or eax, ecx
mov rcx, qword [rsp + 0xd0]
mov dword [rcx], eax
xor eax, eax
mov rcx, qword [rsp + 0x90]
xor rcx, rsp
call fcn.140004de0
add rsp, 0xa8
ret