Function at 0x4643f0
Capabilities:
Connect pipe

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xd8
mov edi, dword [rdx + 0x2c]
mov r15, r8
mov r13, rcx
mov r12, rdx
mov r8d, 0x32
cmp edi, 0xff
ja 0x46448b
cmp edi, 3
mov eax, 3
cmovl edi, eax
movsxd rax, edi
lea rcx, [rax + rax*8 + 4]
call fcn.0043ebc0
test rax, rax
mov rbx, rax
je 0x464900
mov dword [rax], edi
mov r8, 0xffffffffffffffff
xor eax, eax
nop dword [rax]
mov byte [rbx + rax + 4], 0
mov ecx, dword [rbx]
lea rdx, [rbx + rax*8]
add rax, 1
cmp edi, eax
mov qword [rcx + rdx + 4], r8
jg 0x464450
xor esi, esi
cmp dword [r12 + 0x2c], esi
mov edx, esi
jg 0x4644a2
cmp rsi, 2
jbe 0x464a24
add rsi, 1
cmp edi, esi
jg 0x46446a
mov qword [r15], rbx
xor r8d, r8d
mov eax, r8d
add rsp, 0xd8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rax, rsi
shl rax, 4
add rax, qword [r12 + 0x30]
mov r9d, dword [rax]
mov rbp, qword [rax + 8]
mov eax, r9d
and eax, 7
cmp eax, 1
je 0x4645a0
jb 0x464473
cmp eax, 2
je 0x464524
cmp eax, 4
jne 0x464500
mov eax, dword [rbp + 0x10]
cmp eax, 0xe
je 0x464860
cmp eax, 7
je 0x4647b4
mov r8d, 0x32
mov rcx, rbx
mov dword [rsp + 0x48], r8d
call fcn.00464390
mov r8d, dword [rsp + 0x48]
jmp 0x46448b
lea rdx, str.src_win_process_stdio.c
lea rcx, [0x004b39d1]
mov r8d, 0x1b6
call fcn.00480c40
mov r8d, 0xffffffff
jmp 0x46448b
cmp ebp, 0xffffffff
je 0x464572
mov ecx, ebp
call qword [sym.imp.msvcrt.dll__get_osfhandle]
lea rdx, [rax - 1]
cmp rdx, 0xfffffffffffffffd
ja 0x464820
cmp rax, 0xfffffffffffffffe
je 0x464820
lea rdx, [rsp + 0x90]
mov rcx, rax
call fcn.004642b0
test eax, eax
mov r8d, eax
je 0x4648d0
cmp eax, 6
jne 0x4644eb
cmp ebp, 2
jg 0x4644eb
mov byte [rbx + rsi + 4], 0
mov edx, dword [rbx]
lea rax, [rbx + rsi*8]
add rsi, 1
cmp edi, esi
mov qword [rdx + rax + 4], 0xffffffffffffffff
jg 0x46446a
jmp 0x464485
cmp dword [rbp + 0x10], 7
je 0x4645c9
lea rdx, str.src_win_process_stdio.c
lea rcx, str.fdopt.data.stream__type__UV_NAMED_PIPE
mov r8d, 0x14e
mov dword [rsp + 0x48], r9d
call fcn.00480c40
mov r9d, dword [rsp + 0x48]
mov eax, dword [rbp + 0x58]
test ah, 0x10
jne 0x464871
test eax, 0x2000000
jne 0x4648a2
mov r14d, r9d
and r14d, 0x10
cmp r14d, 1
sbb r10d, r10d
not r10d
and r10d, 0x80000100
cmp r14d, 1
sbb r8d, r8d
not r8d
and r8d, 3
and r9d, 0x20
mov dword [rsp + 0x5c], r9d
je 0x46461c
or r8d, 1
or r10d, 0x40000080
lea r11, [rsp + 0x90]
mov qword [rsp + 0x20], 0x40
mov rdx, rbp
mov rcx, r13
mov dword [rsp + 0x50], r10d
mov r9, r11
mov qword [rsp + 0x48], r11
call fcn.0044dc10
test eax, eax
mov r8d, eax
jne 0x464760
mov ecx, dword [rbp + 0x110]
xor eax, eax
mov r10d, dword [rsp + 0x50]
mov r11, qword [rsp + 0x48]
mov dword [rsp + 0x70], 0x18
lea r9, [rsp + 0x70]
mov qword [rsp + 0x78], 0
mov dword [rsp + 0x80], 1
test ecx, ecx
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x20], 3
setne al
mov edx, r10d
mov rcx, r11
shl eax, 0x1e
mov dword [rsp + 0x28], eax
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp rax, 0xffffffffffffffff
je 0x464840
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x6c]
mov dword [rsp + 0x30], 0
mov qword [rsp + 0x28], 0
mov rcx, rax
mov qword [rsp + 0x20], 0
mov qword [rsp + 0x48], rax
call qword [sym.imp.KERNEL32.dll_GetNamedPipeHandleStateA]
cmp eax, 1
mov r10, qword [rsp + 0x48]
je 0x464711
lea rdx, str.src_win_process_stdio.c
lea rcx, str.r__TRUE
mov r8d, 0x9d
call fcn.00480c40
mov r10, qword [rsp + 0x48]
mov edx, dword [rsp + 0x6c]
test edx, edx
jne 0x4649c3
mov qword [rsp + 0x48], r10
xor edx, edx
mov rcx, qword [rbp + 0x118]
call qword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
mov r10, qword [rsp + 0x48]
je 0x464970
test r14d, r14d
je 0x46474a
or dword [rbp + 0x58], 0x10000
mov eax, dword [rsp + 0x5c]
test eax, eax
je 0x464793
or dword [rbp + 0x58], 0x8000
jmp 0x464793
cmp qword [rbp + 0x118], 0xffffffffffffffff
je 0x4644eb
mov rdx, rbp
mov rcx, r13
mov dword [rsp + 0x48], r8d
call fcn.0044ea90
mov r8d, dword [rsp + 0x48]
test r8d, r8d
jne 0x4644eb
mov r10, 0xffffffffffffffff
mov edx, dword [rbx]
lea rax, [rbx + rsi*8]
mov qword [rdx + rax + 4], r10
mov byte [rbx + rsi + 4], 9
add rsi, 1
cmp edi, esi
jg 0x46446a
jmp 0x464485
test byte [rbp + 0x59], 0x10
je 0x4644e5
mov rcx, qword [rbp + 0x118]
mov ebp, 9
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x4644e5
cmp rcx, 0xfffffffffffffffe
je 0x464835
lea rdx, [rsp + 0x90]
call fcn.004642b0
test eax, eax
mov r8d, eax
jne 0x4644eb
mov edx, dword [rbx]
mov rcx, qword [rsp + 0x90]
lea rax, [rbx + rsi*8]
mov qword [rdx + rax + 4], rcx
mov byte [rbx + rsi + 4], bpl
add rsi, 1
cmp edi, esi
jg 0x46446a
jmp 0x464485
cmp ebp, 2
mov qword [rsp + 0x90], 0xffffffffffffffff
jle 0x464572
mov r8d, 6
jmp 0x4644eb
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp qword [rbp + 0x118], 0xffffffffffffffff
mov r8d, eax
je 0x464783
jmp 0x46476e
mov rcx, qword [rbp + 0x110]
mov ebp, 0x41
jmp 0x4647ca
lea rdx, str.src_win_process_stdio.c
lea rcx, str.__fdopt.data.stream__flags__UV_HANDLE_CONNECTION_
mov r8d, 0x14f
mov dword [rsp + 0x48], r9d
call fcn.00480c40
mov eax, dword [rbp + 0x58]
mov r9d, dword [rsp + 0x48]
test eax, 0x2000000
je 0x4645e0
lea rdx, str.src_win_process_stdio.c
lea rcx, str.__fdopt.data.stream__flags__UV_HANDLE_PIPESERVER_
mov r8d, 0x150
mov dword [rsp + 0x48], r9d
call fcn.00480c40
mov r9d, dword [rsp + 0x48]
jmp 0x4645e0
mov rcx, qword [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 2
je 0x464940
ja 0x464910
test eax, eax
je 0x4649f5
cmp eax, 1
jne 0x464920
mov byte [rbx + rsi + 4], 1
jmp 0x464945
mov r8d, 0xe
jmp 0x46448b
cmp eax, 3
je 0x4649eb
cmp eax, 0x8000
je 0x464940
lea rdx, str.src_win_process_stdio.c
lea rcx, [0x004b39d1]
mov r8d, 0x188
call fcn.00480c40
jmp 0x464519
mov byte [rbx + rsi + 4], 0x41
mov edx, dword [rbx]
mov rcx, qword [rsp + 0x90]
lea rax, [rbx + rsi*8]
add rsi, 1
cmp edi, esi
mov qword [rdx + rax + 4], rcx
jg 0x46446a
jmp 0x464485
mov rdx, qword [sym.imp.KERNEL32.dll_GetLastError]
mov qword [rsp + 0x50], rdx
call rdx
cmp eax, 0x217
mov r10, qword [rsp + 0x48]
je 0x46473e
mov rdx, qword [rsp + 0x50]
call rdx
cmp qword [rbp + 0x118], 0xffffffffffffffff
mov r8d, eax
mov r10, qword [rsp + 0x48]
jne 0x464a59
mov dword [rsp + 0x48], r8d
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, dword [rsp + 0x48]
jmp 0x464783
lea rdx, str.src_win_process_stdio.c
lea rcx, str.mode___PIPE_READMODE_BYTE__PIPE_WAIT_
mov r8d, 0x9e
mov qword [rsp + 0x48], r10
call fcn.00480c40
mov r10, qword [rsp + 0x48]
jmp 0x46471d
mov byte [rbx + rsi + 4], 9
jmp 0x464945
mov rbp, qword [sym.imp.KERNEL32.dll_GetLastError]
call rbp
test eax, eax
je 0x464940
call rbp
mov rcx, qword [rsp + 0x90]
mov dword [rsp + 0x48], eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, dword [rsp + 0x48]
jmp 0x4644eb
mov eax, dword [rbx]
cmp edx, 1
sbb edx, edx
and edx, 0xfffffef3
add edx, 0x120196
lea rcx, [rax + rsi*8 + 4]
add rcx, rbx
call fcn.00464320
test eax, eax
mov r8d, eax
jne 0x4644eb
mov byte [rbx + rsi + 4], 0x41
jmp 0x46447d
mov rdx, rbp
mov rcx, r13
mov qword [rsp + 0x48], r10
mov dword [rsp + 0x50], eax
call fcn.0044ea90
mov r8d, dword [rsp + 0x50]
mov r10, qword [rsp + 0x48]
jmp 0x4649ab