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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1009c75b
mov eax, dword fs:[0]
push eax
sub esp, 0xdc
mov eax, dword [0x100a20a4]
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 0x100462fe
mov ecx, ebx
call fcn.10046210
jmp 0x1004647e
cmp byte [ebx + 0x38], 0
jne 0x10046361
mov eax, dword [ebx]
push 1
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x100a8504]
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.10045de0
mov eax, dword [ebx]
push 0
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x100a8504]
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 0x1004640c
push 0x28
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
test eax, eax
je 0x100465cc
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 0x10046404
test ecx, ecx
je 0x10046404
sub ecx, dword [ecx - 4]
je 0x10046404
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0xa0], esi
jmp 0x10046412
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 0x100465f1
mov eax, dword [ebp - 0x9c]
cmp dword [ebp - 0xa4], eax
jae 0x1004649a
mov byte [ebp - 4], 0
lea eax, [ebp - 0x94]
mov ecx, dword [ebp - 0xa0]
cmp ecx, eax
je 0x10046477
test ecx, ecx
je 0x10046477
sub ecx, dword [ecx - 4]
je 0x10046477
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.1009b610
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0xa0]
mov edi, dword [ecx + 4]
cmp edi, dword [ebp - 0x98]
jbe 0x1004654f
test edi, edi
je 0x10046504
lea eax, [edi + 0x20]
test eax, eax
je 0x100464d4
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edx, eax
test edx, edx
jne 0x100464d6
mov dword [ebp - 0xbc], eax
jmp 0x1004661a
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 0x1004650e
xor esi, esi
mov dword [ebp - 0xa8], esi
xor edx, edx
mov dword [ebp - 0xbc], esi
test edx, edx
je 0x1004661a
push eax
push ecx
push esi
call sub.msvcrt.dll_memcpy
add esp, 0xc
lea eax, [ebp - 0x94]
mov ecx, dword [ebp - 0xa0]
cmp ecx, eax
je 0x10046547
test ecx, ecx
je 0x10046547
sub ecx, dword [ecx - 4]
je 0x10046547
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 0x10046635
xor esi, esi
mov dword [ebp - 0xcc], esi
cmp esi, edi
jae 0x100465a5
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 0x10046650
add esi, dword [ebp - 0xa4]
mov dword [ebp - 0xcc], esi
mov edi, dword [ebp - 0x9c]
mov ecx, dword [ebp - 0xa0]
jmp 0x10046566
mov eax, dword [ebx]
push ecx
mov esi, dword [eax]
mov ecx, esi
call dword [0x100a8504]
mov ecx, ebx
call esi
jmp 0x10046390
mov dword [ebp - 0xb0], 0
mov dword [ebp - 0xb4], 0x8007000e
push 0x100a19e0
lea eax, [ebp - 0xb4]
push eax
call sub.msvcrt.dll__CxxThrowException
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x10046603
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 0xb8], eax
push 0x100a19e0
lea eax, [ebp - 0xb8]
push eax
call sub.msvcrt.dll__CxxThrowException
mov dword [ebp - 0xc0], 0x8007000e
push 0x100a19e0
lea eax, [ebp - 0xc0]
push eax
call sub.msvcrt.dll__CxxThrowException
mov dword [ebp - 0xc4], 0x80004005
push 0x100a19e0
lea eax, [ebp - 0xc4]
push eax
call sub.msvcrt.dll__CxxThrowException
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x10046662
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 0xc8], eax
push 0x100a19e0
lea eax, [ebp - 0xc8]
push eax
call sub.msvcrt.dll__CxxThrowException
int3