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

Disassembly:
mov dword [rsp + 0x10], edx
mov r11, rsp
mov qword [r11 + 8], rcx
push rsi
push rdi
push r14
sub rsp, 0xa0
mov qword [r11 - 0x38], 0xfffffffffffffffe
mov qword [r11 + 0x20], rbx
mov rdi, rcx
mov rax, qword [rcx + 0x128]
mov qword [r11 - 0x68], rax
mov rax, qword [rcx + 0x30]
mov qword [r11 - 0x60], rax
mov rax, qword [rcx + 0x98]
mov qword [r11 - 0x58], rax
mov rcx, rdi
call fcn.1400451dc
test al, al
je 0x14004553e
xor sil, sil
cmp byte [rdi + 0x10], sil
je 0x1400452e4
mov rcx, rdi
call fcn.140045590
test al, al
je 0x140045441
and dword [rsp + 0xc8], 0
lea rax, [rdi + 0x18]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0xc8]
mov r8d, 0x1000
mov rdx, qword [rdi + 0x60]
mov rcx, qword [rdi + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1400453a4
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x140045370
cmp eax, 0x3e5
je 0x14004536a
lea rax, str.Channel_read_failure
mov qword [rsp + 0xd0], rax
lea rdx, [rsp + 0xd0]
lea rcx, [rsp + 0x68]
call fcn.1400b4118
nop
lea rax, vtable.CRSimpleIPCException.0
mov qword [rsp + 0x68], rax
lea rdx, [0x14014f950]
lea rcx, [rsp + 0x68]
call fcn.1400b8b68
mov byte [rdi + 0x10], 1
jmp 0x1400453a4
lea rcx, [rsp + 0x38]
call fcn.1400b4190
nop
lea rax, vtable.CRSimpleIPCException.0
mov qword [rsp + 0x38], rax
lea rax, vtable.CRSimpleIPCExceptionDisconnected.0
mov qword [rsp + 0x38], rax
lea rdx, [0x14014f908]
lea rcx, [rsp + 0x38]
call fcn.1400b8b68
cmp byte [rdi + 0x10], 0
jne 0x140045441
mov r14, qword [rdi + 0x50]
sub r14, qword [rdi + 0x48]
mov r8d, dword [0x14018cd80]
mov ecx, r8d
imul ecx, r8d
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*2]
shl eax, 3
sub ecx, eax
cmp ecx, 0x12
jne 0x140045406
mov ecx, 1
mov dword [rsp + 0x30], ecx
cmp ecx, r8d
jge 0x140045400
mov eax, r8d
cdq
idiv ecx
inc ecx
add ecx, edx
mov dword [rsp + 0x30], ecx
jmp 0x1400453eb
mov dword [0x14018cd80], ecx
lea rbx, [rdi + 0x48]
mov edx, dword [rsp + 0xc8]
add rdx, r14
mov rcx, rbx
call fcn.140020840
mov rcx, qword [rbx]
mov r8d, dword [rsp + 0xc8]
add rcx, r14
mov rdx, qword [rdi + 0x60]
call fcn.1400b0cc0
mov rcx, qword [rdi + 0x38]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
mov bl, 1
jmp 0x140045443
xor bl, bl
mov rcx, rdi
call fcn.14004569c
or al, bl
or sil, al
mov rcx, rdi
call fcn.140045b10
test sil, sil
je 0x140045462
jmp 0x1400452bb
mov r9d, 0x7530
xor r8d, r8d
lea rdx, [rsp + 0x50]
lea ecx, [r8 + 3]
call qword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
test eax, eax
jne 0x14004548d
mov rcx, qword [rdi + 0x128]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
jmp 0x14004545d
cmp eax, 3
jae 0x1400454a4
mov rcx, rdi
call fcn.140045590
mov rcx, rdi
call fcn.1400458f0
jmp 0x1400454ff
cmp eax, 0x102
jne 0x14004550c
mov eax, dword [0x14018cd80]
lea ecx, [rax + 1]
imul ecx, eax
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0xe
sub ecx, edx
cmp ecx, 4
jne 0x1400454f0
and qword [rsp + 0x28], 0
and qword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_PeekNamedPipe]
mov rcx, qword [rdi + 8]
test rcx, rcx
je 0x1400454ff
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, rdi
call fcn.140045b10
jmp 0x14004545d
lea rcx, [rsp + 0x88]
call fcn.1400b4190
nop
lea rax, vtable.CRSimpleIPCException.0
mov qword [rsp + 0x88], rax
lea rdx, [0x14014f950]
lea rcx, [rsp + 0x88]
call fcn.1400b8b68
nop
mov rbx, qword [rsp + 0xd8]
add rsp, 0xa0
pop r14
pop rdi
pop rsi
ret