Function at 0x1400015e4
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Parse pe header
Read file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x98
lea rbp, [rsp + 0x90]
mov qword [rbp + 0x30], rcx
mov qword [rbp - 0x10], 0
mov qword [rbp - 0x18], 0
mov dword [rbp - 0x1c], 0
lea rdx, section..rdata
mov rcx, qword [rbp + 0x30]
call sym.fopen
mov qword [rbp - 0x28], rax
cmp qword [rbp - 0x28], 0
jne 0x140001637
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x28]
mov r8d, 2
mov edx, 0
mov rcx, rax
call sym.fseek
mov rax, qword [rbp - 0x28]
mov rcx, rax
call sym.ftell
mov dword [rbp - 0x2c], eax
mov rax, qword [rbp - 0x28]
mov r8d, 0
mov edx, 0
mov rcx, rax
call sym.fseek
mov eax, dword [rbp - 0x2c]
mov rcx, rax
call sym.malloc
mov qword [rbp - 0x38], rax
cmp qword [rbp - 0x38], 0
jne 0x140001694
mov eax, 1
jmp 0x14000194b
mov edx, dword [rbp - 0x2c]
mov rcx, qword [rbp - 0x28]
mov rax, qword [rbp - 0x38]
mov r9, rcx
mov r8, rdx
mov edx, 1
mov rcx, rax
call sym.fread
mov qword [rbp - 0x40], rax
mov eax, dword [rbp - 0x2c]
cmp qword [rbp - 0x40], rax
je 0x1400016c9
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x38]
mov qword [rbp - 0x18], rax
mov eax, dword [rbp - 0x2c]
mov dword [rbp - 0x1c], eax
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x48], rax
mov rax, qword [rbp - 0x48]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x14000170d
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
lea rcx, str.DOS_signature_error:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x48]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 0x18]
add rax, rdx
mov qword [rbp - 0x50], rax
mov rax, qword [rbp - 0x50]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x140001750
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
lea rcx, str.PE_signature_error:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x50]
mov rax, qword [rax + 0x30]
mov qword [0x140011030], rax
mov rax, qword [rbp - 0x50]
mov eax, dword [rax + 0x50]
cmp eax, 0x621db1
je 0x14000178c
mov rax, qword [rbp - 0x50]
mov eax, dword [rax + 0x50]
mov edx, eax
lea rcx, str.Size_of_image_not_known__was_executable_updated__:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x50]
mov eax, dword [rax + 0x50]
mov esi, eax
mov rax, qword [rbp - 0x50]
mov rax, qword [rax + 0x30]
mov rbx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
mov dword [rsp + 0x20], 0x40
mov r9d, 0x3000
mov r8, rsi
mov rdx, rbx
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
call rax
mov qword [rbp - 0x10], rax
cmp qword [rbp - 0x10], 0
jne 0x1400017f5
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
lea rcx, str.Virtual_allocation_error:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
mov rax, qword [rbp - 0x50]
mov eax, dword [rax + 0x54]
mov esi, eax
mov rax, qword [rbp - 0x50]
mov rax, qword [rax + 0x30]
mov rbx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
mov rdx, qword [rbp - 0x18]
mov qword [rsp + 0x20], 0
mov r9, rsi
mov r8, rdx
mov rdx, rbx
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
call rax
test eax, eax
jne 0x140001859
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
lea rcx, str.Write_PE_header_error:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
mov dword [rbp - 4], 0
jmp 0x140001932
mov rax, qword [rbp - 0x48]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 0x18]
lea rcx, [rdx + rax]
mov eax, dword [rbp - 4]
movsxd rdx, eax
mov rax, rdx
shl rax, 2
add rax, rdx
shl rax, 3
add rax, rcx
add rax, 0x108
mov qword [rbp - 0x58], rax
mov rax, qword [rbp - 0x58]
mov eax, dword [rax + 0x10]
mov edi, eax
mov rax, qword [rbp - 0x58]
mov eax, dword [rax + 0x14]
mov edx, eax
mov rax, qword [rbp - 0x18]
add rax, rdx
mov rsi, rax
mov rax, qword [rbp - 0x50]
mov rdx, qword [rax + 0x30]
mov rax, qword [rbp - 0x58]
mov eax, dword [rax + 0xc]
mov eax, eax
add rax, rdx
mov rbx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
call rax
mov qword [rsp + 0x20], 0
mov r9, rdi
mov r8, rsi
mov rdx, rbx
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
call rax
test eax, eax
jne 0x14000192e
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov dword [rbp - 0x5c], eax
cmp dword [rbp - 0x5c], 0x57
jne 0x140001916
lea rcx, str.Got_ERROR_INVALID_PARAMETER_but_continuing_n
call sym.printf
jmp 0x14000192e
mov eax, dword [rbp - 0x5c]
mov edx, eax
lea rcx, str.Write_section_memory_error:__x_n
call sym.printf
mov eax, 1
jmp 0x14000194b
add dword [rbp - 4], 1
mov rax, qword [rbp - 0x50]
movzx eax, word [rax + 6]
movzx eax, ax
cmp dword [rbp - 4], eax
jl 0x140001865
mov eax, 0
add rsp, 0x98
pop rbx
pop rsi
pop rdi
pop rbp
ret