Function at 0x423681
Capabilities:
Get common file path
Read file on windows
Write file on windows

Disassembly:
mov eax, 0x484170
call fcn.004801f0
sub esp, 0x4e0
mov ax, word [0x4b5520]
push esi
push edi
mov word [ebp - 0x2e4], ax
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x2e2]
push 0x104
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x4ec]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea eax, [ebp - 0x4ec]
push str.winsta.dll
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 0x4ec]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
xor esi, esi
cmp edi, esi
je 0x423724
push str.WinStationQueryInformationW
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, esi
je 0x42371d
lea ecx, [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x2e4]
push 0x208
push ecx
push 0x21
push dword [ebp + 8]
push esi
call eax
test al, al
jne 0x42371d
mov word [ebp - 0x2e4], si
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp word [ebp - 0x2e4], si
jne 0x423745
push dword [ebp + 8]
lea eax, [ebp - 0x2e4]
push str..PipeTerminalServerSystemExecSrvr_d
push eax
call dword [sym.imp.MSVCRT.dll_swprintf]
add esp, 0xc
push esi
push esi
push 3
push esi
push esi
lea eax, [ebp - 0x2e4]
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
jne 0x42378f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xe7
jne 0x423788
lea eax, [ebp - 0x2e4]
push 0x7530
push eax
call dword [sym.imp.KERNEL32.dll_WaitNamedPipeW]
test eax, eax
jne 0x423745
xor eax, eax
jmp 0x4238e7
push ebx
push 0x400
lea ecx, [ebp - 0x28]
call fcn.0042d769
mov ebx, 0x94
lea ecx, [ebp - 0x28]
push ebx
push esi
mov dword [ebp - 4], esi
call fcn.0042d8d0
push ebx
lea eax, [ebp - 0xdc]
push esi
push eax
call sub.MSVCRT.dll_memset
mov eax, dword [ebp + 0x24]
add esp, 0xc
mov dword [ebp - 0xac], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0xd4], eax
mov eax, dword [ebp + 0x28]
mov dword [ebp - 0xa8], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov dword [ebp - 0xd8], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0xd0], eax
lea eax, [ebp - 0x28]
push eax
push dword [ebp + 0x14]
call fcn.0042364e
mov dword [ebp - 0xcc], eax
lea eax, [ebp - 0x28]
push eax
push dword [ebp + 0x18]
call fcn.0042364e
mov esi, dword [ebp + 0x34]
push 0x11
mov dword [ebp - 0xc8], eax
pop ecx
lea eax, [ebp - 0x28]
lea edi, [ebp - 0x9c]
push eax
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x94]
call fcn.0042364e
mov dword [ebp - 0x94], eax
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x90]
call fcn.0042364e
mov dword [ebp - 0x90], eax
mov eax, dword [ebp - 0x1c]
add esp, 0x20
mov dword [ebp - 0xdc], eax
lea eax, [ebp - 0xdc]
xor esi, esi
push ebx
push eax
lea ecx, [ebp - 0x28]
mov dword [ebp - 0xa4], esi
call fcn.0042e949
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
lea eax, [ebp - 0x10]
lea ecx, [ebp - 0x28]
push esi
push eax
push dword [ebp - 0x1c]
call fcn.0042e949
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4238cd
lea eax, [ebp - 0x10]
push esi
push eax
lea eax, [ebp - 0x48]
push 0x1c
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4238cd
mov ebx, dword [ebp - 0x44]
cmp ebx, esi
je 0x4238c2
mov edi, dword [ebp + 0x38]
lea esi, [ebp - 0x3c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
jmp 0x4238cf
push dword [ebp - 0x40]
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x4238cf
xor ebx, ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.0042d7f5
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret