Function at 0x425650
Capabilities:
Connect pipe
Create pipe
Read file on windows
Read pipe

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x430100
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ebx
sub esp, 0x670
mov eax, ecx
push esi
xor esi, esi
mov dword [ebp - 0x20], eax
push edi
mov dword [ebp - 0x28], esi
cmp dword [eax + 4], esi
je 0x425699
mov esi, dword [eax + 8]
mov dword [ebp - 0x28], esi
push 0x400
lea eax, [ebp - 0x680]
mov dword [ebp - 0x18], 0xffffffff
push 0
push eax
mov byte [ebp - 0x11], 0
call fcn.0040d1e0
mov edi, dword [sym.imp.KERNEL32.dll_CreateEventW]
add esp, 0xc
push 0
push 0
push 1
push 0
call edi
mov dword [ebp - 0x4c], eax
test eax, eax
jne 0x425701
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Create_Event_for_Pipe_fail_with_errcode__d
lea eax, [ebp - 0x200]
push str._s_d
push eax
call fcn.00402000
add esp, 0x10
lea ecx, [ebp - 0x200]
call fcn.00402020
jmp 0x425d06
push 0
push 0
push 1
xorps xmm0, xmm0
mov dword [ebp - 0x64], 0
push 0
movups xmmword [ebp - 0x74], xmm0
mov dword [ebp - 0x64], eax
call edi
test eax, eax
je 0x4256d1
push 0x14
xorps xmm0, xmm0
mov dword [ebp - 0x78], 0
push 0x40
movups xmmword [ebp - 0x88], xmm0
mov dword [ebp - 0x78], eax
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
mov dword [ebp - 0x30], edi
test edi, edi
jne 0x42575d
mov ecx, str.Error_in_LocalAlloc_for_pSD
call fcn.00402020
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x425d06
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
jne 0x42579c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x200]
push str.Error:_InitializeSecurityDescriptor____d
push eax
call fcn.00402000
add esp, 0xc
lea ecx, [ebp - 0x200]
call fcn.00402020
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x425d06
push 0
push 0
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
test eax, eax
jne 0x4257df
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x200]
push str.Error:_SetSecurityDescriptorDacl____d
push eax
call fcn.00402000
add esp, 0xc
lea ecx, [ebp - 0x200]
call fcn.00402020
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x425d06
push 0x2a
lea eax, [ebp - 0xf4]
mov dword [ebp - 0x58], 0xc
push 0
push eax
mov dword [ebp - 0x54], edi
mov dword [ebp - 0x50], 1
call fcn.0040d1e0
mov edi, dword [ebp - 0x20]
lea eax, [ebp - 0xf4]
add esp, 0xc
push dword [edi + 0xc]
push str..Pipewritevlc_d
push eax
call fcn.00402000
add esp, 0xc
cmp byte [edi + 0x10], 0
jne 0x425cd3
mov eax, dword [ebp - 0x18]
cmp eax, 0xffffffff
jne 0x425861
lea eax, [ebp - 0x58]
push eax
push 0
push 0x800
push 0x800
push 0x64
push 6
push 0x40000003
lea eax, [ebp - 0xf4]
push eax
call dword [sym.imp.KERNEL32.dll_CreateNamedPipeA]
mov dword [ebp - 0x18], eax
cmp eax, 0xffffffff
je 0x425d1b
cmp byte [ebp - 0x11], 0
jne 0x4258b6
lea ecx, [ebp - 0x88]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
jne 0x42588a
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x425d4c
push str.ConnectNamedPipe_ok
lea eax, [ebp - 0x200]
push 0x446c60
push eax
call fcn.00402000
add esp, 0xc
lea ecx, [ebp - 0x200]
call fcn.00402020
mov byte [ebp - 0x11], 1
mov byte [edi + 0x18], 1
cmp byte [edi + 0x10], 0
jne 0x425cd3
lea eax, [ebp - 0x34]
mov dword [ebp - 0x24], 0
push eax
lea eax, [ebp - 0x24]
mov dword [ebp - 0x34], 0
push eax
push 0
push 0
push 0
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
mov ecx, dword [ebp - 0x24]
test eax, eax
je 0x4258fd
test ecx, ecx
jne 0x4258fd
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x425cc9
cmp byte [edi + 0x10], 0
jne 0x425cd3
mov dword [ebp - 0x38], 0
test ecx, ecx
je 0x425932
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp - 0x38]
push eax
push 0x400
lea eax, [ebp - 0x680]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [ebp - 0x24]
test eax, eax
jne 0x425948
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x425d82
mov ecx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x18]
cmp eax, 0xffffffff
je 0x425cc0
test ecx, ecx
je 0x425cc0
push 0
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0
push ecx
lea ecx, [ebp - 0x74]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetOverlappedResult]
mov ecx, dword [ebp - 0x2c]
lea eax, [ecx - 1]
cmp eax, 0x3ff
ja 0x425ca7
cmp dword [edi + 8], 0
je 0x425ca7
mov eax, dword [ebp - 0x680]
cmp eax, 1
jne 0x4259f1
mov eax, dword [ebp - 0x20]
xor edi, edi
mov ecx, dword [eax + 0x1c]
mov eax, dword [ecx]
mov dword [ebp - 0x1c], eax
cmp eax, ecx
je 0x4259d4
nop dword [eax + eax]
cmp dword [eax + 0x14], 0
je 0x4259c1
mov eax, dword [eax + 0x10]
mov dword [ebp + edi*4 - 0xc8], eax
inc edi
lea ecx, [ebp - 0x1c]
call fcn.00402910
mov ecx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x1c]
cmp eax, dword [ecx + 0x1c]
jne 0x4259b0
test esi, esi
je 0x425ca7
push ecx
push edi
lea eax, [ebp - 0xc8]
mov ecx, esi
push eax
call fcn.00429960
jmp 0x425ca7
cmp eax, 2
jne 0x425a10
test esi, esi
je 0x425ca7
push dword [ebp - 0x67c]
mov ecx, esi
call fcn.004299b0
jmp 0x425ca7
cmp eax, 4
jne 0x425aa5
mov edi, dword [ebp - 0x678]
test edi, edi
jne 0x425a54
test esi, esi
je 0x425ca7
mov eax, dword [esi + 0xc]
test eax, eax
je 0x425ca7
push edi
push 0x7fffffff
push edi
push edi
push 4
push dword [ebp - 0x67c]
push eax
call sub.libvlc.dll_libvlc_video_set_osd_text
add esp, 0x1c
jmp 0x425ca7
push 0x80
lea eax, [ebp - 0x280]
push 0
push eax
call fcn.0040d1e0
add esp, 0xc
lea eax, [ebp - 0x674]
push edi
push eax
lea eax, [ebp - 0x280]
push eax
call fcn.0040bf00
add esp, 0xc
test esi, esi
je 0x425ca7
lea eax, [ebp - 0x280]
mov ecx, esi
push eax
sub esp, 0x10
push dword [ebp - 0x67c]
call fcn.00429ae0
jmp 0x425ca7
cmp eax, 5
jne 0x425b0e
mov ecx, str.pipe_receive_stop
call fcn.00402020
cmp dword [edi + 0x20], 0
jbe 0x425ca7
mov eax, dword [ebp - 0x20]
xor edi, edi
mov ecx, dword [eax + 0x1c]
mov eax, dword [ecx]
mov dword [ebp - 0x1c], eax
cmp eax, ecx
je 0x425af0
mov esi, dword [ebp - 0x20]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x1c]
mov dword [ebp + edi*4 - 0xc8], eax
inc edi
call fcn.00402910
mov eax, dword [ebp - 0x1c]
cmp eax, dword [esi + 0x1c]
jne 0x425ad2
mov esi, dword [ebp - 0x28]
test esi, esi
je 0x425ca7
push 0
push edi
lea eax, [ebp - 0xc8]
mov ecx, esi
push eax
call fcn.00429c30
jmp 0x425ca7
cmp eax, 6
jne 0x425b33
test esi, esi
je 0x425ca7
push dword [ebp - 0x678]
mov ecx, esi
push dword [ebp - 0x67c]
call fcn.0042a010
jmp 0x425ca7
cmp eax, 7
jne 0x425b86
cmp ecx, 8
jbe 0x425b5a
lea eax, [ecx - 8]
mov ecx, esi
push eax
lea eax, [ebp - 0x678]
push eax
push dword [ebp - 0x67c]
call fcn.0042a0b0
jmp 0x425ca7
push 0
push dword [ebp - 0x67c]
lea eax, [ebp - 0xb4]
push str._d__d
push eax
call fcn.00402000
add esp, 0x10
lea ecx, [ebp - 0xb4]
call fcn.00402020
jmp 0x425ca7
cmp eax, 8
jne 0x425c0f
cmp dword [ebp - 0x67c], 0
mov edx, dword [ebp - 0x678]
setne al
mov dword [ebp - 0x44], edx
mov byte [ebp - 0x48], al
test edx, edx
jle 0x425bf8
lea ecx, [edi + 0x1c]
movzx eax, al
mov dword [ebp - 0x40], ecx
xor edi, edi
mov dword [ebp - 0x3c], eax
mov esi, edx
nop dword [eax]
mov eax, dword [ebp + edi - 0x674]
mov dword [ebp + edi - 0xc8], eax
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x60]
push eax
call fcn.00402de0
mov eax, dword [ebp - 0x60]
lea edi, [edi + 4]
mov ecx, dword [ebp - 0x3c]
mov dword [eax + 0x14], ecx
mov ecx, dword [ebp - 0x40]
sub esi, 1
jne 0x425bc0
mov esi, dword [ebp - 0x28]
mov edx, dword [ebp - 0x44]
push dword [ebp - 0x48]
lea eax, [ebp - 0xc8]
mov ecx, esi
push edx
push eax
call fcn.00429c30
jmp 0x425ca7
cmp eax, 9
jne 0x425c31
test esi, esi
je 0x425ca7
push dword [ebp - 0x678]
mov ecx, esi
push dword [ebp - 0x67c]
call fcn.0042a140
jmp 0x425ca7
cmp eax, 0xa
jne 0x425c49
test esi, esi
je 0x425ca7
push dword [ebp - 0x67c]
mov ecx, esi
call fcn.0042a200
jmp 0x425ca7
cmp eax, 0xb
jne 0x425c67
test esi, esi
je 0x425ca7
push dword [ebp - 0x678]
mov ecx, esi
push dword [ebp - 0x67c]
call fcn.0042a250
jmp 0x425ca7
cmp eax, 0xc
jne 0x425c7f
test esi, esi
je 0x425ca7
push dword [ebp - 0x67c]
mov ecx, esi
call fcn.0042a310
jmp 0x425ca7
cmp eax, 0x10
jne 0x425c91
test esi, esi
je 0x425ca7
mov ecx, esi
call fcn.0042a3f0
jmp 0x425ca7
cmp eax, 0x11
jne 0x425ca7
test esi, esi
je 0x425ca7
push dword [ebp - 0x67c]
mov ecx, esi
call fcn.0042a510
push 0x400
lea eax, [ebp - 0x680]
push 0
push eax
call fcn.0040d1e0
mov edi, dword [ebp - 0x20]
add esp, 0xc
push dword [ebp - 0x4c]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
cmp byte [edi + 0x10], 0
je 0x425827
mov esi, dword [sym.imp.KERNEL32.dll_DisconnectNamedPipe]
mov ecx, str.pipe_thread_exit
call fcn.00402020
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x18]
cmp eax, 0xffffffff
je 0x425d00
push eax
call esi
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [edi], 0
mov ecx, dword [ebp - 0xc]
xor eax, eax
pop edi
mov dword fs:[0], ecx
pop esi
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x200]
push 0x446c08
push eax
call fcn.00402000
add esp, 0xc
lea ecx, [ebp - 0x200]
call fcn.00402020
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x425d06
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.ConnectNamedPipe__fail_with_errcode:
lea eax, [ebp - 0x200]
push str._s_d
push eax
call fcn.00402000
add esp, 0x10
lea ecx, [ebp - 0x200]
call fcn.00402020
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x425d06
push dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DisconnectNamedPipe]
call esi
mov ecx, str.pipe_break
mov byte [edi + 0x18], 0
call fcn.00402020
jmp 0x425cd9