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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x93c
mov eax, dword [0x61094c]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x104
lea eax, [ebp - 0x108]
mov dword [ebp - 0x934], edx
push 0
push eax
mov dword [ebp - 0x930], ecx
call fcn.00556180
add esp, 0xc
lea eax, [ebp - 0x108]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jne 0x431ca9
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00553cca
mov esp, ebp
pop ebp
ret
mov ecx, 0x104
lea eax, [ebp - 0x108]
cmp byte [eax], 0
je 0x431cbf
inc eax
sub ecx, 1
jne 0x431cb4
push ebx
push esi
mov edx, 0x104
mov esi, ecx
mov eax, edx
sub eax, ecx
neg esi
sbb esi, esi
and esi, eax
test ecx, ecx
je 0x431d0f
lea ecx, [ebp - 0x108]
lea ecx, [ecx + esi]
sub edx, esi
je 0x431d04
mov esi, str.WinInit.Ini
mov eax, SysReAllocString
sub esi, ecx
nop
test eax, eax
je 0x431d04
mov bl, byte [esi + ecx]
test bl, bl
je 0x431d04
mov byte [ecx], bl
dec eax
inc ecx
sub edx, 1
jne 0x431cf0
test edx, edx
lea eax, [ecx - 1]
cmovne eax, ecx
mov byte [eax], 0
push 0
push 0x8000080
push 4
push 0
push 0
push 0xc0000000
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x431d3c
xor ebx, ebx
jmp 0x431e48
push edi
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x431dc5
lea ecx, [ebx + 1]
push ecx
call fcn.0056027d
mov edi, eax
add esp, 4
test edi, edi
je 0x431eff
push 0
lea eax, [ebp - 0x92c]
mov dword [ebp - 0x92c], 0
push eax
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x431eff
mov eax, dword [ebp - 0x92c]
push str._Rename_
push edi
mov byte [eax + edi], 0
call fcn.00556d60
add esp, 8
test eax, eax
jne 0x431e61
push str._rename_
push edi
call fcn.00556d60
add esp, 8
test eax, eax
jne 0x431e61
push edi
call fcn.0055e7dd
add esp, 4
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0x410
lea eax, [ebp - 0x928]
push 0
push eax
call fcn.00556180
push dword [ebp - 0x930]
lea eax, [ebp - 0x928]
push dword [ebp - 0x934]
push str._r_n_rename__r_n_s_s_r_n
push 0x410
push eax
call fcn.00434f70
lea ecx, [ebp - 0x928]
mov dword [ebp - 0x93c], 0
add esp, 0x20
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x431e20
push 0
lea eax, [ebp - 0x93c]
sub ecx, edx
push eax
push ecx
lea eax, [ebp - 0x928]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ebx, eax
pop edi
test esi, esi
je 0x431e4f
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov eax, ebx
pop esi
xor ecx, ebp
pop ebx
call fcn.00553cca
mov esp, ebp
pop ebp
ret
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0x410
lea eax, [ebp - 0x518]
push 0
push eax
call fcn.00556180
push dword [ebp - 0x930]
cmp byte [edi + ebx - 1], 0xa
mov ecx, str._s_s_r_n
push dword [ebp - 0x934]
mov eax, str._r_n_s_s_r_n
cmove eax, ecx
push eax
lea eax, [ebp - 0x518]
push 0x410
push eax
call fcn.00434f70
lea ecx, [ebp - 0x518]
mov dword [ebp - 0x938], 0
add esp, 0x20
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x431ec7
push 0
lea eax, [ebp - 0x938]
sub ecx, edx
push eax
push ecx
lea eax, [ebp - 0x518]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x431eff
push edi
mov ebx, 1
call fcn.0055e7dd
add esp, 4
jmp 0x431e43
push edi
xor ebx, ebx
call fcn.0055e7dd
add esp, 4
jmp 0x431e43