Function at 0x10018590
Capabilities:
Read pipe
Write pipe

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x144
mov eax, dword [0x10087004]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0x14]
push esi
mov dword [ebp - 0x11c], eax
mov esi, ecx
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x118], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x120], edx
mov dword [ebp - 0x124], eax
mov dword [ebp - 0x114], ebx
push edi
cmp esi, 0xffffffff
jne 0x1001866b
cmp byte [0x10089b50], 0
jne 0x100185e9
call fcn.100181e0
mov edi, dword [0x10089b5c]
xor esi, esi
test edi, edi
je 0x1001866b
lea eax, [ebp - 0x110]
mov dword [ebp - 0x10c], esi
push eax
lea eax, [ebp - 0x10c]
mov dword [ebp - 0x110], esi
push eax
push 1
push esi
push esi
mov ecx, edi
call dword [0x10077548]
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp - 0x10c]
test eax, eax
je 0x1001866b
mov edx, dword [ebp - 0x110]
xor ecx, ecx
test edx, edx
je 0x10018651
nop dword [eax]
cmp dword [eax + 8], esi
je 0x1001864f
inc ecx
add eax, 0xc
cmp ecx, edx
jb 0x10018640
jmp 0x10018651
mov esi, dword [eax]
mov edi, dword [0x10089b58]
test edi, edi
je 0x1001866b
push dword [ebp - 0x10c]
mov ecx, edi
call dword [0x10077548]
call edi
push esi
lea eax, [ebp - 0x108]
push str..pipeK7TSUser_lu
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
mov eax, dword [ebx]
add esp, 0xc
mov esi, dword [ebp - 0x118]
add eax, 0x40
add eax, esi
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
test edi, edi
je 0x1001884f
lea ebx, [edi + 0x1c]
mov dword [edi], 0x4b375453
mov ecx, ebx
mov dword [edi + 4], 1
add ebx, esi
mov dword [edi + 8], 0x1c
push esi
push dword [ebp - 0x11c]
mov dword [edi + 0xc], 0
lea eax, [ebx + 0x24]
mov dword [edi + 0x14], esi
mov dword [ebp - 0x10c], eax
mov eax, dword [ebp - 0x120]
mov dword [edi + 0x10], eax
mov eax, dword [ebp - 0x114]
push ecx
mov eax, dword [eax]
mov dword [edi + 0x18], eax
call fcn.1002b2f0
add esp, 0xc
mov dword [ebp - 0x130], 0xc
lea eax, [esi + 0x1c]
mov dword [ebp - 0x128], 1
mov dword [ebp - 0x11c], eax
lea eax, [ebp - 0x144]
mov dword [ebp - 0x12c], eax
push 1
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push 0
push 0
push 1
lea eax, [ebp - 0x144]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
push 0
push 0
push 3
lea eax, [ebp - 0x130]
push eax
push 0
push 0xc0000000
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x100187b6
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xe7
jne 0x100187ad
push 0xffffffffffffffff
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_WaitNamedPipeA]
push 0
push 0
push 3
lea eax, [ebp - 0x130]
push eax
push 0
push 0xc0000000
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x10018767
jmp 0x100187b6
cmp esi, 0xffffffff
je 0x10018865
push 0
push 0
lea eax, [ebp - 0x118]
mov dword [ebp - 0x118], 2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetNamedPipeHandleState]
test eax, eax
je 0x10018855
mov eax, dword [ebp - 0x114]
lea ecx, [ebp - 0x110]
push 0
push ecx
mov dword [ebp - 0x110], 0
mov eax, dword [eax]
add eax, 0x24
push eax
push ebx
push dword [ebp - 0x11c]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_TransactNamedPipe]
test eax, eax
je 0x10018855
cmp dword [ebx], 0x4b375453
jne 0x10018855
cmp dword [ebx + 4], 1
jne 0x10018855
cmp dword [ebx + 8], 0x24
jne 0x10018855
mov eax, dword [ebp - 0x120]
cmp dword [ebx + 0x10], eax
jne 0x10018855
mov ebx, dword [ebp - 0x114]
push dword [ebx]
push dword [ebp - 0x10c]
push dword [ebp - 0x124]
call fcn.1002b2f0
mov eax, dword [edi + 0x18]
add esp, 0xc
mov dword [ebx], eax
mov ebx, 1
jmp 0x10018857
mov esi, dword [ebp - 0x124]
xor ebx, ebx
cmp esi, 0xffffffff
je 0x10018867
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x10018867
xor ebx, ebx
test edi, edi
je 0x1001887b
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10029e88
mov esp, ebp
pop ebp
ret