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

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x890]
sub rsp, 0x990
mov rax, qword [0x1400580e8]
xor rax, rsp
mov qword [rbp + 0x880], rax
mov r13, rdx
mov r12, rcx
mov ebx, 0x104
lea rcx, [rsp + 0x50]
mov r8d, ebx
xor edx, edx
call fcn.14001d380
mov edx, ebx
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
xor r15d, r15d
test eax, eax
je 0x140007e96
lea r8, str.WinInit.Ini
mov rdx, rbx
lea rcx, [rsp + 0x50]
call fcn.140007b48
mov qword [rsp + 0x30], r15
lea rcx, [rsp + 0x50]
mov dword [rsp + 0x28], 0x8000080
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x20], 4
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rdi, rax
cmp rax, 0xffffffffffffffff
jne 0x140007d56
mov esi, r15d
jmp 0x140007e8b
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov r14d, eax
test eax, eax
je 0x140007e0a
lea ecx, [rax + 1]
mov rbx, r15
mov esi, 1
test rcx, rcx
jne 0x140007d81
mov rcx, r15
jmp 0x140007d93
xor edx, edx
or rax, 0xffffffffffffffff
div rcx
cmp rax, rsi
jb 0x140007f43
call fcn.14001f8cc
mov rbx, rax
test rax, rax
je 0x140007f43
lea r9, [rsp + 0x40]
mov dword [rsp + 0x40], r15d
mov r8d, r14d
mov qword [rsp + 0x20], r15
mov rdx, rax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140007f43
mov eax, dword [rsp + 0x40]
lea rdx, str._Rename_
mov rcx, rbx
mov byte [rax + rbx], r15b
call fcn.14001d6a8
test rax, rax
jne 0x140007ec0
lea rdx, str._rename_
mov rcx, rbx
call fcn.14001d6a8
test rax, rax
jne 0x140007ec0
mov rcx, rbx
call fcn.14001f6dc
mov r9d, 2
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov r15d, 0x410
lea rcx, [rbp + 0x470]
mov r8d, r15d
xor edx, edx
call fcn.14001d380
mov r9, r13
mov qword [rsp + 0x20], r12
lea r8, str._r_n_rename__r_n_s_s_r_n
mov edx, r15d
lea rcx, [rbp + 0x470]
call fcn.140007c08
xor r15d, r15d
lea rcx, [rbp + 0x470]
mov dword [rsp + 0x48], r15d
call fcn.14001f700
mov r8, rax
mov qword [rsp + 0x20], r15
lea r9, [rsp + 0x48]
mov rcx, rdi
lea rdx, [rbp + 0x470]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov esi, eax
test rdi, rdi
je 0x140007e94
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
mov rcx, qword [rbp + 0x880]
xor rcx, rsp
call fcn.14001a5c0
mov rbx, qword [rsp + 0x9e0]
add rsp, 0x990
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov r9d, 2
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov r15d, 0x410
lea rcx, [rbp + 0x60]
mov r8d, r15d
xor edx, edx
call fcn.14001d380
lea eax, [r14 - 1]
mov qword [rsp + 0x20], r12
mov r9, r13
lea rcx, [rbp + 0x60]
mov edx, r15d
lea r8, str._s_s_r_n
cmp byte [rax + rbx], 0xa
je 0x140007f0f
lea r8, str._r_n_s_s_r_n
call fcn.140007c08
xor r15d, r15d
lea rcx, [rbp + 0x60]
mov dword [rsp + 0x44], r15d
call fcn.14001f700
mov r8, rax
mov qword [rsp + 0x20], r15
lea r9, [rsp + 0x44]
mov rcx, rdi
lea rdx, [rbp + 0x60]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x140007f46
mov esi, r15d
mov rcx, rbx
call fcn.14001f6dc
jmp 0x140007e86