Function at 0x4012d0
Capabilities:
Read pipe
Write pipe

Disassembly:
sub esp, 0x140
mov eax, dword [0x49ab28]
xor eax, esp
mov dword [esp + 0x13c], eax
cmp dword [esp + 0x144], 0xffffffff
mov eax, dword [esp + 0x14c]
mov ecx, dword [esp + 0x154]
push ebx
push ebp
mov ebp, dword [esp + 0x160]
push esi
push edi
mov edi, dword [esp + 0x160]
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], ecx
jne 0x401326
lea edx, [esp + 0x154]
push edx
call fcn.00401200
add esp, 4
mov eax, dword [esp + 0x154]
push eax
lea ecx, [esp + 0x4c]
push str..pipeK7TSUser_lu
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
mov edx, dword [ebp]
add esp, 0xc
lea eax, [edx + edi + 0x40]
push eax
push 0
mov dword [esp + 0x1c], 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
je 0x4014e7
mov edx, dword [esp + 0x158]
lea ebx, [esi + 0x1c]
mov eax, ebx
mov dword [esi + 0x10], edx
mov edx, dword [esp + 0x10]
add ebx, edi
lea ecx, [ebx + 0x24]
push edi
mov dword [esp + 0x20], ecx
mov dword [esi], 0x4b375453
mov dword [esi + 4], 1
mov dword [esi + 8], 0x1c
mov dword [esi + 0xc], 0
mov dword [esi + 0x14], edi
mov ecx, dword [ebp]
push edx
push eax
mov dword [esi + 0x18], ecx
call fcn.0046c470
add esp, 0xc
lea eax, [esp + 0x34]
push 1
mov ecx, eax
add edi, 0x1c
push ecx
mov dword [esp + 0x18], edi
mov dword [esp + 0x30], 0xc
mov dword [esp + 0x38], 1
mov dword [esp + 0x34], eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push 0
push 0
push 1
lea edx, [esp + 0x40]
push edx
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
push 0
push 0
push 3
lea eax, [esp + 0x34]
push eax
push 0
push 0xc0000000
lea ecx, [esp + 0x60]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x40145d
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xe7
jne 0x401454
push 0xffffffffffffffff
lea edx, [esp + 0x4c]
push edx
call dword [sym.imp.KERNEL32.dll_WaitNamedPipeA]
push 0
push 0
push 3
lea eax, [esp + 0x34]
push eax
push 0
push 0xc0000000
lea ecx, [esp + 0x60]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x401414
jmp 0x40145d
cmp edi, 0xffffffff
je 0x4014f7
push 0
push 0
lea edx, [esp + 0x28]
push edx
push edi
mov dword [esp + 0x30], 2
call dword [sym.imp.KERNEL32.dll_SetNamedPipeHandleState]
test eax, eax
je 0x4014eb
mov eax, dword [ebp]
mov edx, dword [esp + 0x10]
push 0
lea ecx, [esp + 0x28]
push ecx
add eax, 0x24
push eax
push ebx
push edx
push esi
push edi
mov dword [esp + 0x40], 0
call dword [sym.imp.KERNEL32.dll_TransactNamedPipe]
test eax, eax
je 0x4014eb
cmp dword [ebx], 0x4b375453
jne 0x4014eb
cmp dword [ebx + 4], 1
jne 0x4014eb
cmp dword [ebx + 8], 0x24
jne 0x4014eb
mov eax, dword [esp + 0x158]
cmp dword [ebx + 0x10], eax
jne 0x4014eb
mov ecx, dword [ebp]
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x18]
push ecx
push edx
push eax
call fcn.0046c470
mov ecx, dword [esi + 0x18]
add esp, 0xc
mov dword [ebp], ecx
mov dword [esp + 0x14], 1
jmp 0x4014eb
mov edi, dword [esp + 0x18]
cmp edi, 0xffffffff
je 0x4014f7
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x40150b
push esi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov ecx, dword [esp + 0x14c]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0046c1d2
add esp, 0x140
ret