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

Disassembly:
push rbp
push rbx
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x598]
sub rsp, 0x698
mov rax, qword [0x1402ba4e0]
xor rax, rsp
mov qword [rbp + 0x580], rax
mov rax, qword [str._rename_]
mov rdi, rcx
mov rbx, rdx
mov qword [rsp + 0x48], rax
movzx eax, byte [0x140231540]
lea rcx, [rsp + 0x61]
xor edx, edx
mov r8d, 0x103
or r12d, 0xffffffff
mov byte [rsp + 0x50], al
mov byte [rsp + 0x60], 0
call fcn.14010da60
lea rdx, [rsp + 0x60]
mov r8d, 0x104
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetShortPathNameA]
xor r15d, r15d
test eax, eax
jne 0x1400d4aee
test rbx, rbx
jne 0x1400d4ad0
mov qword [rsp + 0x30], r15
xor r9d, r9d
xor r8d, r8d
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 1
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp rax, 0xffffffffffffffff
je 0x1400d4a9e
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, [rsp + 0x60]
mov r8d, 0x104
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetShortPathNameA]
test eax, eax
jne 0x1400d4aee
lea rcx, [rsp + 0x60]
sub rcx, rdi
nop
movzx eax, byte [rdi]
inc rdi
mov byte [rcx + rdi - 1], al
test al, al
jne 0x1400d4ac0
jmp 0x1400d4aee
lea rcx, [rsp + 0x60]
sub rcx, rdi
nop dword [rax + rax]
movzx eax, byte [rdi]
inc rdi
mov byte [rcx + rdi - 1], al
test al, al
jne 0x1400d4ae0
lea rcx, [rbp + 0x180]
xor edx, edx
mov r8d, 0x400
call fcn.14010da60
lea r9, [rsp + 0x60]
lea rdx, str._hs_hs
lea rcx, [rbp + 0x180]
lea r8, [0x140231528]
test rbx, rbx
je 0x1400d4b24
mov r8, rbx
call qword [sym.imp.USER32.dll_wsprintfA]
lea rcx, [rbp + 0x180]
call fcn.140115670
lea rcx, [rbp + 0x70]
mov edx, 0x104
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rbp + 0x70]
mov qword [rsp + 0x30], r15
xor r9d, r9d
repne scasb al, byte [rdi]
mov rax, qword [str.wininit.ini]
lea rcx, [rbp + 0x70]
mov qword [rdi - 1], rax
mov eax, dword [0x140231520]
xor r8d, r8d
mov dword [rdi + 7], eax
movzx eax, byte [0x140231524]
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
mov byte [rdi + 0xb], al
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov r14, rax
cmp rax, 0xffffffffffffffff
je 0x1400d4e2e
xor edx, edx
mov rcx, rax
mov qword [rsp + 0x6e0], rsi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp eax, r12d
je 0x1400d4e1d
lea ebx, [rax + 0x1000]
inc eax
mov qword [rsp + 0x690], r13
mov ecx, eax
mov dword [rsp + 0x40], r15d
mov edi, eax
call fcn.1400854f0
mov r8d, edi
xor edx, edx
mov rcx, rax
mov r13, rax
call fcn.14010da60
mov ecx, ebx
mov edi, ebx
call fcn.1400854f0
mov r8d, edi
xor edx, edx
mov rcx, rax
mov rbx, rax
call fcn.14010da60
lea r9, [rsp + 0x40]
mov r8d, esi
mov rdx, r13
mov rcx, r14
mov qword [rsp + 0x20], r15
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400d4e05
cmp dword [rsp + 0x40], esi
jne 0x1400d4e05
mov rdx, rbx
mov rcx, r13
sub rdx, r13
nop
movzx eax, byte [rcx]
inc rcx
mov byte [rdx + rcx - 1], al
test al, al
jne 0x1400d4c40
mov rcx, r13
call fcn.140115670
lea rdx, [rsp + 0x48]
mov rcx, r13
call fcn.14010d30c
test rax, rax
je 0x1400d4d11
lea rcx, [rax + 1]
mov edx, 0x5b
call fcn.140110904
or rcx, 0xffffffffffffffff
mov rdi, rbx
mov r11, rax
lea rdx, [rbp + 0x180]
test rax, rax
je 0x1400d4cf5
sub rax, r13
mov byte [rax + rbx], r15b
xor eax, eax
repne scasb al, byte [rdi]
xor ecx, ecx
nop dword [rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x1400d4ca0
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasb al, byte [rdi]
movzx eax, word [0x1402065d0]
or rcx, 0xffffffffffffffff
mov word [rdi - 1], ax
movzx eax, byte [0x1402065d2]
mov byte [rdi + 1], al
xor eax, eax
mov rdi, rbx
repne scasb al, byte [rdi]
xor ecx, ecx
nop dword [rax]
movzx eax, byte [r11 + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x1400d4ce0
jmp 0x1400d4daf
repne scasb al, byte [rdi]
xor ecx, ecx
nop dword [rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x1400d4d00
jmp 0x1400d4d8f
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasb al, byte [rdi]
xor ecx, ecx
lea rdx, [rsp + 0x48]
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x1400d4d30
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasb al, byte [rdi]
movzx eax, word [0x1402065d0]
or rcx, 0xffffffffffffffff
mov word [rdi - 1], ax
movzx eax, byte [0x1402065d2]
lea rdx, [rbp + 0x180]
mov byte [rdi + 1], al
xor eax, eax
mov rdi, rbx
repne scasb al, byte [rdi]
xor ecx, ecx
nop word [rax + rax]
movzx eax, byte [rdx + rcx]
inc rcx
mov byte [rdi + rcx - 2], al
test al, al
jne 0x1400d4d80
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasb al, byte [rdi]
movzx eax, word [0x1402065d0]
mov word [rdi - 1], ax
movzx eax, byte [0x1402065d2]
mov byte [rdi + 1], al
or rcx, 0xffffffffffffffff
xor eax, eax
mov dword [rsp + 0x40], r15d
mov rdi, rbx
xor r9d, r9d
xor r8d, r8d
repne scasb al, byte [rdi]
xor edx, edx
not rcx
lea rdi, [rcx - 1]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
lea r9, [rsp + 0x40]
mov r8d, edi
mov rdx, rbx
mov rcx, r14
mov qword [rsp + 0x20], r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1400d4e05
cmp dword [rsp + 0x40], edi
cmove r12d, r15d
mov rcx, rbx
call fcn.140085540
mov rcx, r13
call fcn.140085540
mov r13, qword [rsp + 0x690]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rsi, qword [rsp + 0x6e0]
mov eax, r12d
mov rcx, qword [rbp + 0x580]
xor rcx, rsp
call fcn.14010d170
add rsp, 0x698
pop r15
pop r14
pop r12
pop rdi
pop rbx
pop rbp
ret