Function at 0x1400018a0
Capabilities:
Create pipe
Create thread

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
lea rbp, [rax - 0x808]
sub rsp, 0x8f0
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x14001e020]
xor rax, rsp
mov qword [rbp + 0x7e0], rax
mov rbx, rcx
xor r13d, r13d
lea rcx, [rsp + 0x48]
call fcn.1400017c0
movzx r12d, al
lea rsi, [rsp + 0x48]
test al, al
cmove rsi, r13
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
call fcn.140001080
test al, al
je 0x140001939
mov ecx, dword [rbx + 0x24]
cmp ecx, 1
je 0x140001917
cmp ecx, 3
jne 0x140001939
lea rcx, [0x140016ad0]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140001939
lea rdx, str.GetNamedPipeServerProcessId
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [rbx + 0x24]
test ecx, ecx
je 0x140001cb7
dec ecx
je 0x140001c59
dec ecx
je 0x140001c3d
dec ecx
je 0x140001962
mov eax, 8
jmp 0x140001dbd
cmp qword [rbx + 0xc0], r13
jne 0x140001975
mov eax, 9
jmp 0x140001dbd
lea rdx, [rbx + 0x88]
lea rcx, [rbp - 0x70]
call fcn.140002050
nop
lea rcx, [rbp - 0x70]
cmp qword [rbp - 0x58], 8
cmovae rcx, qword [rbp - 0x70]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_WaitNamedPipeW]
test eax, eax
jne 0x1400019a5
jmp 0x140001c84
lea rdi, [rbx + 0xb0]
mov rdx, rdi
lea rcx, [rsp + 0x68]
call fcn.1400020c0
nop
lea rcx, [rsp + 0x68]
cmp qword [rbp - 0x80], 8
cmovae rcx, qword [rsp + 0x68]
call fcn.140001120
cmp rax, 0xffffffffffffffff
je 0x140001a09
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop
cmp qword [rbp - 0x80], 8
jb 0x1400019f1
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001d62
lea rcx, [rsp + 0x68]
cmp qword [rbp - 0x80], 8
cmovae rcx, qword [rsp + 0x68]
mov qword [rsp + 0x38], rsi
mov dword [rsp + 0x30], 0x3e8
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x20], r13d
mov edx, 3
lea r9d, [rdx - 2]
lea r8d, [rdx + 3]
call qword [sym.imp.KERNEL32.dll_CreateNamedPipeW]
mov qword [rbx + 0x58], rax
test r12b, r12b
je 0x140001a57
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_LocalFree]
cmp qword [rbx + 0x58], 0xffffffffffffffff
jne 0x140001a88
cmp qword [rbp - 0x80], 8
jb 0x140001a70
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001d7a
mov rcx, qword [rbx + 0x18]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
lea r11, [rsp + 0x40]
mov qword [rsp + 0x28], r11
mov dword [rsp + 0x20], r13d
mov r9, rbx
lea r8, [fcn.140001150]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rbx + 0x60], rax
test rax, rax
jne 0x140001ae8
cmp qword [rbp - 0x80], 8
jb 0x140001ad0
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001d7a
mov qword [rbp - 0x40], r13
mov qword [rbp - 0x38], r13
xor edx, edx
mov r8d, 0x400
lea rcx, [rbp - 0x30]
call sub.MSVCR100.dll_memset
mov qword [rbp + 0x3d0], r13
mov dword [rbp + 0x3d8], r13d
xor edx, edx
mov r8d, 0x400
lea rcx, [rbp + 0x3dc]
call sub.MSVCR100.dll_memset
lea rcx, [rbx + 0xd8]
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x68]
call fcn.1400029d0
mov r11, qword [rbx + 0xc0]
cmp qword [rdi + 0x18], 8
jb 0x140001b4c
mov rdi, qword [rdi]
lea esi, [r11 + r11]
cmp esi, 0x400
ja 0x140001b9b
xor edx, edx
mov r8d, 0x410
lea rcx, [rbp - 0x40]
call sub.MSVCR100.dll_memset
mov dword [rbp - 0x40], 1
mov dword [rbp - 0x3c], 1
mov dword [rbp - 0x38], 1
test rdi, rdi
je 0x140001b9b
mov dword [rbp - 0x34], esi
mov r9d, esi
mov r8, rdi
mov edx, 0x400
lea rcx, [rbp - 0x30]
call qword [sym.imp.MSVCR100.dll_memcpy_s]
xor r9d, r9d
lea r8, [rbp + 0x3d0]
lea rdx, [rbp - 0x40]
mov rcx, rbx
call fcn.140002450
mov ebx, eax
test eax, eax
jne 0x140001c13
cmp dword [rbp + 0x3d4], eax
je 0x140001be9
cmp qword [rbp - 0x80], 8
jb 0x140001bd1
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001c84
cmp qword [rbp - 0x80], 8
jb 0x140001bfb
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001c9f
cmp qword [rbp - 0x80], 8
jb 0x140001c25
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov qword [rbp - 0x80], 7
mov qword [rsp + 0x78], r13
mov word [rsp + 0x68], r13w
jmp 0x140001daa
mov edx, 1
mov rcx, rbx
call fcn.140002740
mov edx, 2
mov rcx, rbx
call fcn.140002740
jmp 0x140001cb7
lea rdx, [rbx + 0x88]
lea rcx, [rbp - 0x70]
call fcn.140002050
nop
lea rcx, [rbp - 0x70]
cmp qword [rbp - 0x58], 8
cmovae rcx, qword [rbp - 0x70]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_WaitNamedPipeW]
test eax, eax
jne 0x140001c9f
cmp qword [rbp - 0x58], 8
jb 0x140001c95
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov eax, 4
jmp 0x140001dbd
cmp qword [rbp - 0x58], 8
jb 0x140001cb0
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
xor eax, eax
jmp 0x140001dbd
mov byte [rbx + 0x21], r13b
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 1]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventA]
mov qword [rbx + 0x18], rax
test rax, rax
je 0x140001d8b
lea rdx, [rbx + 0x88]
lea rcx, [rbp - 0x70]
call fcn.140002050
nop
lea rcx, [rbx + 0xd8]
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rbp - 0x70]
call fcn.1400029d0
lea rcx, [rbp - 0x70]
cmp qword [rbp - 0x58], 8
cmovae rcx, qword [rbp - 0x70]
mov qword [rsp + 0x38], rsi
mov dword [rsp + 0x30], 0x3e8
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x20], r13d
mov edx, 0x80003
mov r9d, 1
lea r8d, [r9 + 5]
call qword [sym.imp.KERNEL32.dll_CreateNamedPipeW]
mov qword [rbx + 0x50], rax
test r12b, r12b
je 0x140001d50
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_LocalFree]
cmp qword [rbx + 0x50], 0xffffffffffffffff
jne 0x140001d92
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x140001d7a
cmp qword [rbp - 0x58], 8
jb 0x140001d73
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov eax, 3
jmp 0x140001dbd
cmp qword [rbp - 0x58], 8
jb 0x140001d8b
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov eax, 2
jmp 0x140001dbd
mov dword [rbx + 8], r13d
mov rcx, qword [rbx + 0x18]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
mov rcx, rbx
call fcn.140001150
mov ebx, eax
cmp qword [rbp - 0x58], 8
jb 0x140001dbb
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete_void____ptr64_]
mov eax, ebx
mov rcx, qword [rbp + 0x7e0]
xor rcx, rsp
call fcn.1400133b0
lea r11, [rsp + 0x8f0]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r13
pop r12
pop rbp
ret