Function at 0x100468c0
Capabilities:
Read file on windows
Read pipe

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1009fcfb
mov eax, dword fs:[0]
push eax
sub esp, 0xdc
mov eax, dword [0x100a60a4]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, ecx
mov dword [ebp - 0xd0], ebx
push 0
push 0
push 0
push 0
push 0
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
test eax, eax
jne 0x1004691e
mov ecx, ebx
call fcn.10046830
jmp 0x10046a9e
cmp byte [ebx + 0x38], 0
jne 0x10046981
mov eax, dword [ebx]
push 1
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x100ac510]
mov ecx, ebx
call esi
mov dword [ebp - 0xdc], 0x10
mov dword [ebp - 0xe0], 1
mov eax, dword [ebx + 0x34]
mov dword [ebp - 0xd8], eax
inc dword [ebx + 8]
mov eax, dword [ebx + 8]
mov dword [ebp - 0xd4], eax
lea eax, [ebp - 0xe0]
push eax
mov ecx, ebx
call fcn.10046400
mov eax, dword [ebx]
push 0
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x100ac510]
mov ecx, ebx
call esi
mov dword [ebp - 4], 0
lea eax, [ebp - 0x94]
mov dword [ebp - 0xa0], eax
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0x80
mov byte [ebp - 4], 1
lea esp, [esp]
cmp dword [ebp - 0x98], 8
jae 0x10046a2c
push 0x28
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
test eax, eax
je 0x10046bec
mov dword [ebp - 0xac], eax
mov ecx, eax
and ecx, 0x1f
mov edx, 0x20
sub edx, ecx
lea esi, [eax + edx]
mov dword [ebp - 0xac], esi
mov dword [esi - 4], edx
mov dword [ebp - 0xb0], esi
push dword [ebp - 0x9c]
push dword [ebp - 0xa0]
push esi
call sub.msvcrt.dll_memcpy
add esp, 0xc
lea eax, [ebp - 0x94]
mov ecx, dword [ebp - 0xa0]
cmp ecx, eax
je 0x10046a24
test ecx, ecx
je 0x10046a24
sub ecx, dword [ecx - 4]
je 0x10046a24
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0xa0], esi
jmp 0x10046a32
mov esi, dword [ebp - 0xa0]
mov dword [ebp - 0x9c], 8
lea eax, [ebp - 0xe4]
push eax
lea eax, [ebp - 0xe8]
push eax
lea eax, [ebp - 0xa4]
push eax
push 8
push esi
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
test eax, eax
je 0x10046c11
mov eax, dword [ebp - 0x9c]
cmp dword [ebp - 0xa4], eax
jae 0x10046aba
mov byte [ebp - 4], 0
lea eax, [ebp - 0x94]
mov ecx, dword [ebp - 0xa0]
cmp ecx, eax
je 0x10046a97
test ecx, ecx
je 0x10046a97
sub ecx, dword [ecx - 4]
je 0x10046a97
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.1009ebb0
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0xa0]
mov edi, dword [ecx + 4]
cmp edi, dword [ebp - 0x98]
jbe 0x10046b6f
test edi, edi
je 0x10046b24
lea eax, [edi + 0x20]
test eax, eax
je 0x10046af4
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edx, eax
test edx, edx
jne 0x10046af6
mov dword [ebp - 0xbc], eax
jmp 0x10046c3a
xor edx, edx
mov dword [ebp - 0xa8], edx
mov eax, edx
and eax, 0x1f
mov ecx, 0x20
sub ecx, eax
lea esi, [edx + ecx]
mov dword [ebp - 0xa8], esi
mov dword [esi - 4], ecx
mov edx, esi
mov eax, dword [ebp - 0x9c]
mov ecx, dword [ebp - 0xa0]
jmp 0x10046b2e
xor esi, esi
mov dword [ebp - 0xa8], esi
xor edx, edx
mov dword [ebp - 0xbc], esi
test edx, edx
je 0x10046c3a
push eax
push ecx
push edx
call sub.msvcrt.dll_memcpy
add esp, 0xc
lea eax, [ebp - 0x94]
mov ecx, dword [ebp - 0xa0]
cmp ecx, eax
je 0x10046b67
test ecx, ecx
je 0x10046b67
sub ecx, dword [ecx - 4]
je 0x10046b67
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, esi
mov dword [ebp - 0xa0], ecx
mov dword [ebp - 0x9c], edi
cmp edi, 8
jb 0x10046c55
xor esi, esi
mov dword [ebp - 0xcc], esi
cmp esi, edi
jae 0x10046bc5
lea eax, [ecx + esi]
push 0
lea ecx, [ebp - 0xa4]
push ecx
sub edi, esi
push edi
push eax
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10046c70
add esi, dword [ebp - 0xa4]
mov dword [ebp - 0xcc], esi
mov edi, dword [ebp - 0x9c]
mov ecx, dword [ebp - 0xa0]
jmp 0x10046b86
mov eax, dword [ebx]
push ecx
mov esi, dword [eax]
mov ecx, esi
call dword [0x100ac510]
mov ecx, ebx
call esi
jmp 0x100469b0
mov dword [ebp - 0xb0], 0
mov dword [ebp - 0xb4], 0x8007000e
push 0x100a5080
lea eax, [ebp - 0xb4]
push eax
call sub.msvcrt.dll__CxxThrowException
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x10046c23
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 0xb8], eax
push 0x100a5080
lea eax, [ebp - 0xb8]
push eax
call sub.msvcrt.dll__CxxThrowException
mov dword [ebp - 0xc0], 0x8007000e
push 0x100a5080
lea eax, [ebp - 0xc0]
push eax
call sub.msvcrt.dll__CxxThrowException
mov dword [ebp - 0xc4], 0x80004005
push 0x100a5080
lea eax, [ebp - 0xc4]
push eax
call sub.msvcrt.dll__CxxThrowException
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x10046c82
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 0xc8], eax
push 0x100a5080
lea eax, [ebp - 0xc8]
push eax
call sub.msvcrt.dll__CxxThrowException
int3