Function at 0x4620c0
Capabilities:
Connect pipe

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xd8
mov esi, dword [rdx + 0x2c]
mov r14d, 0x32
mov qword [rsp + 0x120], rcx
mov rbp, rdx
mov qword [rsp + 0x130], r8
cmp esi, 0xff
jbe 0x462110
mov eax, r14d
add rsp, 0xd8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
cmp esi, 3
mov eax, 3
mov r14d, 0xe
cmovl esi, eax
movsxd rax, esi
lea rcx, [rax + rax*8 + 4]
call fcn.0043d450
test rax, rax
mov rbx, rax
je 0x4620f7
mov dword [rax], esi
mov r8, 0xffffffffffffffff
xor eax, eax
mov byte [rbx + rax + 4], 0
mov ecx, dword [rbx]
lea rdx, [rbx + rax*8]
add rax, 1
cmp esi, eax
mov qword [rcx + rdx + 4], r8
jg 0x462141
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
lea r15, [rbx + 4]
xor r12d, r12d
xor edi, edi
mov qword [rsp + 0x58], rax
cmp dword [rbp + 0x2c], edi
jg 0x4621a0
cmp edi, 2
jle 0x4626e9
add edi, 1
add r15, 1
add r12, 8
cmp edi, esi
jl 0x46216e
mov rax, qword [rsp + 0x130]
xor r14d, r14d
mov qword [rax], rbx
jmp 0x4620f7
mov rax, qword [rbp + 0x30]
lea rax, [rax + r12*2]
mov r14d, dword [rax]
mov r13, qword [rax + 8]
mov eax, r14d
and eax, 7
cmp eax, 1
je 0x462255
jb 0x462173
cmp eax, 2
je 0x462220
cmp eax, 4
jne 0x4621f3
mov eax, dword [r13 + 0x10]
cmp eax, 0xe
je 0x462512
cmp eax, 7
je 0x4625d0
mov r14d, 0x32
mov rcx, rbx
call fcn.00462070
jmp 0x4620f7
lea rdx, str.src_win_process_stdio.c
lea rcx, [0x0051dc61]
mov r8d, 0x1b6
call fcn.00472160
mov r14d, 0xffffffff
jmp 0x4620f7
cmp r13d, 0xffffffff
jne 0x462460
mov byte [r15], 0
mov edx, dword [rbx]
lea rax, [rbx + r12]
add edi, 1
add r15, 1
add r12, 8
cmp edi, esi
mov qword [rdx + rax + 4], 0xffffffffffffffff
jl 0x46216e
jmp 0x46218b
cmp dword [r13 + 0x10], 7
je 0x462275
lea rdx, str.src_win_process_stdio.c
lea rcx, str.fdopt.data.stream__type__UV_NAMED_PIPE
mov r8d, 0x14e
call fcn.00472160
mov eax, dword [r13 + 0x58]
test ah, 0x10
jne 0x4624f0
test eax, 0x2000000
jne 0x4624d0
mov eax, r14d
and eax, 0x10
cmp eax, 1
mov dword [rsp + 0x50], eax
sbb r10d, r10d
not r10d
and r10d, 0x80000100
cmp eax, 1
sbb r8d, r8d
not r8d
and r8d, 3
and r14d, 0x20
mov dword [rsp + 0x54], r14d
je 0x4622ca
or r8d, 1
or r10d, 0x40000080
lea r14, [rsp + 0x90]
mov rcx, qword [rsp + 0x120]
mov qword [rsp + 0x20], 0x40
mov rdx, r13
mov dword [rsp + 0x4c], r10d
mov r9, r14
call fcn.0044bea0
test eax, eax
mov r8d, eax
jne 0x462420
mov r9d, dword [r13 + 0x110]
xor eax, eax
mov r10d, dword [rsp + 0x4c]
mov rcx, r14
mov dword [rsp + 0x70], 0x18
mov qword [rsp + 0x78], 0
mov dword [rsp + 0x80], 1
mov qword [rsp + 0x30], 0
test r9d, r9d
mov dword [rsp + 0x20], 3
lea r9, [rsp + 0x70]
setne al
mov edx, r10d
shl eax, 0x1e
mov dword [rsp + 0x28], eax
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp rax, 0xffffffffffffffff
mov r14, rax
je 0x46268d
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
call qword [sym.imp.KERNEL32.dll_GetNamedPipeHandleStateA]
cmp eax, 1
je 0x4623b0
lea rdx, str.src_win_process_stdio.c
lea rcx, str.r__TRUE
mov r8d, 0x9d
call fcn.00472160
mov ecx, dword [rsp + 0x6c]
test ecx, ecx
jne 0x46262d
xor edx, edx
mov rcx, qword [r13 + 0x118]
call qword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
je 0x4625ed
mov edx, dword [rsp + 0x50]
test edx, edx
je 0x4623e3
or dword [r13 + 0x58], 0x10000
mov eax, dword [rsp + 0x54]
test eax, eax
je 0x4623f3
or dword [r13 + 0x58], 0x8000
mov edx, dword [rbx]
lea rax, [rbx + r12]
add edi, 1
add r15, 1
add r12, 8
mov qword [rdx + rax + 4], r14
mov byte [r15 - 1], 9
cmp edi, esi
jl 0x46216e
jmp 0x46218b
cmp qword [r13 + 0x118], 0xffffffffffffffff
je 0x4624c2
mov rcx, qword [rsp + 0x120]
mov rdx, r13
mov dword [rsp + 0x4c], r8d
call fcn.0044ccb0
mov r8d, dword [rsp + 0x4c]
test r8d, r8d
jne 0x4624c2
mov r14, 0xffffffffffffffff
jmp 0x4623f3
mov ecx, r13d
call qword [sym.imp.msvcrt.dll__get_osfhandle]
lea rdx, [rax - 1]
cmp rdx, 0xfffffffffffffffd
seta dl
cmp rax, 0xfffffffffffffffe
sete cl
or dl, cl
jne 0x4624a2
lea rdx, [rsp + 0x90]
mov rcx, rax
call fcn.00461f90
test eax, eax
mov r8d, eax
je 0x462580
cmp eax, 6
sete dl
jmp 0x4624b4
mov qword [rsp + 0x90], 0xffffffffffffffff
mov r8d, 6
cmp r13d, 2
jg 0x4624c2
test dl, dl
jne 0x46222a
mov r14d, r8d
jmp 0x4621e6
lea rdx, str.src_win_process_stdio.c
lea rcx, str.__fdopt.data.stream__flags__UV_HANDLE_PIPESERVER_
mov r8d, 0x150
call fcn.00472160
jmp 0x46228d
lea rdx, str.src_win_process_stdio.c
lea rcx, str.__fdopt.data.stream__flags__UV_HANDLE_CONNECTION_
mov r8d, 0x14f
call fcn.00472160
mov eax, dword [r13 + 0x58]
jmp 0x462282
mov rcx, qword [r13 + 0x110]
mov r13d, 0x41
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x4621e0
cmp rcx, 0xfffffffffffffffe
je 0x462682
lea rdx, [rsp + 0x90]
call fcn.00461f90
test eax, eax
mov r8d, eax
jne 0x4624c2
mov edx, dword [rbx]
mov rcx, qword [rsp + 0x90]
lea rax, [rbx + r12]
add edi, 1
add r15, 1
add r12, 8
mov qword [rdx + rax + 4], rcx
mov byte [r15 - 1], r13b
cmp edi, esi
jl 0x46216e
jmp 0x46218b
mov rcx, qword [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 2
je 0x462679
ja 0x46264b
test eax, eax
je 0x4626b0
cmp eax, 1
jne 0x46265b
mov byte [r15], 1
mov edx, dword [rbx]
mov rcx, qword [rsp + 0x90]
lea rax, [rbx + r12]
mov qword [rdx + rax + 4], rcx
jmp 0x46217c
test byte [r13 + 0x59], 0x10
je 0x4621e0
mov rcx, qword [r13 + 0x118]
mov r13d, 9
jmp 0x46251f
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x217
je 0x4623d3
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp qword [r13 + 0x118], 0xffffffffffffffff
mov r8d, eax
jne 0x46271d
mov dword [rsp + 0x4c], r8d
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, dword [rsp + 0x4c]
jmp 0x462448
lea rdx, str.src_win_process_stdio.c
lea rcx, str.mode___PIPE_READMODE_BYTE__PIPE_WAIT_
mov r8d, 0x9e
call fcn.00472160
jmp 0x4623bc
cmp eax, 3
je 0x4626e0
cmp eax, 0x8000
je 0x462679
lea rdx, str.src_win_process_stdio.c
lea rcx, [0x0051dc61]
mov r8d, 0x188
call fcn.00472160
jmp 0x46220c
mov byte [r15], 0x41
jmp 0x4625b2
mov r14d, 6
jmp 0x4621e6
mov rax, qword [rsp + 0x58]
call rax
cmp qword [r13 + 0x118], 0xffffffffffffffff
mov r8d, eax
je 0x462448
jmp 0x46242e
mov r13, qword [sym.imp.KERNEL32.dll_GetLastError]
call r13
test eax, eax
je 0x462679
call r13
mov rcx, qword [rsp + 0x90]
mov r14d, eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4621e6
mov byte [r15], 9
jmp 0x4625b2
mov eax, dword [rbx]
cmp edi, 1
sbb edx, edx
and edx, 0xfffffef3
add edx, 0x120196
lea rcx, [r12 + rax + 4]
add rcx, rbx
call fcn.00462000
test eax, eax
mov r8d, eax
jne 0x4624c2
mov byte [r15], 0x41
jmp 0x46217c
mov rcx, qword [rsp + 0x120]
mov rdx, r13
mov dword [rsp + 0x4c], eax
call fcn.0044ccb0
mov r8d, dword [rsp + 0x4c]
jmp 0x462615