Function at 0x470bb0
Capabilities:
Create pipe
Delete file
Get common file path
Read file on windows
Write file on windows
Write pipe

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x244
mov eax, dword [0x76d134]
test eax, eax
je 0x471290
lea ebx, [ebp - 0x214]
mov dword [esp], 0x104
mov dword [esp + 4], ebx
call dword [sym.imp.kernel32.dll_GetTempPathA]
lea eax, [ebp - 0x110]
sub esp, 8
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x59b207
call dword [sym.imp.kernel32.dll_GetTempFileNameA]
lea eax, [ebp - 0x110]
sub esp, 0x10
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], pe_nt_image_headers32
mov dword [esp + 0x10], 2
mov dword [esp + 0xc], 0
mov dword [esp + 8], 1
mov dword [esp + 4], 0x40000000
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CreateFileA]
sub esp, 0x1c
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12b6
mov edi, dword fs:[0x18]
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.failed_to_create_file__error__lu_n
mov dword [esp + 8], eax
xor eax, eax
cmp esi, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
lea eax, [ebp - 0x21c]
mov dword [esp], esi
mov dword [esp + 0xc], eax
mov eax, dword [sym.imp.kernel32.dll_WriteFile]
mov dword [esp + 0x10], 0
mov dword [esp + 8], 4
mov dword [esp + 4], 0x59898a
mov dword [ebp - 0x228], eax
call eax
sub esp, 0x14
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12b8
mov eax, dword [edi + 0x34]
mov dword [esp], ebx
mov dword [esp + 8], eax
mov dword [esp + 4], str.failed_to_write_file__error__lu_n
call fcn.0045bef0
mov dword [ebp - 0x220], esi
xor edx, edx
mov ebx, edx
nop
mov eax, dword [ebx*4 + 0x59db00]
mov dword [edi + 0x34], 0xdeadbeef
mov dword [esp + 8], 3
mov dword [esp + 0xc], eax
mov dword [esp + 4], 0x80000000
mov eax, dword [ebp - 0x220]
mov dword [esp], eax
call dword [0x76d134]
sub esp, 0x10
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12be
xor eax, eax
cmp esi, 0xffffffff
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], 0x59bc3d
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12bf
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x5995e7
mov dword [esp + 8], eax
xor eax, eax
cmp dword [edi + 0x34], 0x57
sete al
add ebx, 1
mov dword [esp], eax
call fcn.0045bef0
cmp ebx, 8
jne 0x470cf0
mov esi, dword [ebp - 0x220]
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp], esi
mov dword [esp + 4], 0x80000000
call dword [0x76d134]
sub esp, 0x10
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12c3
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x5995e7
mov dword [esp + 8], eax
xor eax, eax
cmp ebx, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
lea eax, [ebp - 0x21c]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x218]
mov dword [esp + 4], eax
mov eax, dword [sym.imp.kernel32.dll_ReadFile]
mov dword [esp + 8], 4
mov dword [esp], ebx
mov dword [ebp - 0x22c], eax
call eax
sub esp, 0x14
mov dword [ebp - 0x220], eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12c6
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.failed_to_read_file__error__lu_n
mov dword [esp + 8], eax
mov edx, dword [ebp - 0x220]
mov dword [esp], edx
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12c7
mov eax, dword [ebp - 0x21c]
mov dword [esp + 4], 0x59bc68
cmp eax, 4
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12c8
lea eax, [ebp - 0x218]
mov dword [esp], eax
mov eax, dword [sym.imp.msvcrt.dll_strcmp]
mov dword [esp + 4], 0x59898a
mov dword [ebp - 0x230], eax
call eax
mov dword [esp + 4], str.got_wrong_data_n
test eax, eax
sete al
movzx eax, al
mov dword [esp], eax
mov edi, dword fs:[0x18]
call fcn.0045bef0
mov eax, dword [sym.imp.kernel32.dll_CloseHandle]
mov dword [esp], ebx
mov dword [ebp - 0x220], eax
call eax
xor edx, edx
mov dword [ebp - 0x224], esi
sub esp, 4
mov esi, edx
lea esi, [esi]
mov eax, dword [esi*4 + 0x59dadc]
mov dword [esp + 8], 3
mov dword [esp + 4], 0x80000000
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x224]
mov dword [esp], eax
call dword [0x76d134]
sub esp, 0x10
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12ce
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x5995e7
mov dword [esp + 8], eax
xor eax, eax
cmp ebx, 0xffffffff
setne al
add esi, 1
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], ebx
mov eax, dword [ebp - 0x220]
call eax
sub esp, 4
cmp esi, 6
jne 0x470f00
mov esi, dword [ebp - 0x224]
mov dword [edi + 0x34], 0xdeadbeef
mov dword [esp + 0xc], 0
mov dword [esp], esi
mov dword [esp + 8], 3
mov dword [esp + 4], 0x40000000
call dword [0x76d134]
sub esp, 0x10
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12d4
xor eax, eax
cmp ebx, 0xffffffff
sete al
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], 0x59bc3d
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12d5
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x5995e7
mov dword [esp + 8], eax
xor eax, eax
cmp dword [edi + 0x34], 0x20
sete al
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], esi
mov eax, dword [ebp - 0x220]
call eax
lea ecx, [ebp - 0x110]
sub esp, 4
mov dword [esp], ecx
call dword [sym.imp.kernel32.dll_DeleteFileA]
sub esp, 4
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12d9
mov eax, dword [edi + 0x34]
mov dword [esp], ebx
mov dword [esp + 8], eax
mov dword [esp + 4], str.failed_to_delete_file__error__lu_n
call fcn.0045bef0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0x3e8
mov dword [esp + 0x14], 0x3e8
mov dword [esp + 0x10], 0x3e8
mov dword [esp + 0xc], 1
mov dword [esp + 8], 0
mov dword [esp + 4], 3
mov dword [esp], str..pipe_test_pipe
call dword [sym.imp.kernel32.dll_CreateNamedPipeA]
sub esp, 0x20
mov ebx, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12dc
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x59bcc0
mov dword [esp + 8], eax
xor eax, eax
cmp ebx, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], ebx
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0x80000000
call dword [0x76d134]
sub esp, 0x10
mov esi, eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12df
mov eax, dword [edi + 0x34]
mov dword [esp + 4], 0x5995e7
mov dword [esp + 8], eax
xor eax, eax
cmp esi, 0xffffffff
setne al
mov dword [esp], eax
call fcn.0045bef0
lea ecx, [ebp - 0x21c]
mov dword [esp], ebx
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ecx
mov dword [esp + 8], 4
mov dword [esp + 4], 0x59898a
mov ecx, dword [ebp - 0x228]
call ecx
sub esp, 0x14
mov dword [ebp - 0x224], eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12e2
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.failed_to_write_file__error__lu_n
mov dword [esp + 8], eax
mov edx, dword [ebp - 0x224]
mov dword [esp], edx
call fcn.0045bef0
lea ecx, [ebp - 0x21c]
mov dword [esp], esi
mov dword [esp + 0xc], ecx
lea ecx, [ebp - 0x218]
mov dword [esp + 0x10], 0
mov dword [esp + 8], 4
mov dword [esp + 4], ecx
mov ecx, dword [ebp - 0x22c]
call ecx
sub esp, 0x14
mov dword [ebp - 0x224], eax
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12e4
mov eax, dword [edi + 0x34]
mov dword [esp + 4], str.failed_to_read_file__error__lu_n
mov dword [esp + 8], eax
mov edx, dword [ebp - 0x224]
mov dword [esp], edx
call fcn.0045bef0
call fcn.0057d110
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12e5
mov eax, dword [ebp - 0x21c]
mov dword [esp + 4], 0x59bc68
cmp eax, 4
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
call fcn.0057d110
lea ecx, [ebp - 0x218]
mov dword [eax], 0x597dfd
mov dword [eax + 4], 0x12e6
mov dword [esp + 4], 0x59898a
mov dword [esp], ecx
mov ecx, dword [ebp - 0x230]
call ecx
mov dword [esp + 4], str.got_wrong_data_n
test eax, eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.0045bef0
mov dword [esp], esi
mov edi, dword [ebp - 0x220]
mov eax, edi
call eax
mov eax, edi
sub esp, 4
mov dword [esp], ebx
call eax
sub esp, 4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, 0x12ad
call fcn.0045b740
mov dword [esp], str.ReOpenFile___is_not_available_n
call fcn.0045bec0
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret