Function at 0x140006740
Capabilities:
Delete file
Get common file path
Move file
Write file on windows

Disassembly:
mov r11, rsp
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x930
mov rax, qword [0x1402ba790]
xor rax, rsp
mov qword [rsp + 0x920], rax
mov r13, rdx
mov r14, rcx
or rdi, 0xffffffffffffffff
mov qword [rsp + 0x58], rdi
or rsi, rdi
mov qword [rsp + 0x50], rsi
xor ebx, ebx
lea rax, [r11 - 0x258]
mov qword [rsp + 0x20], rax
lea r9, [r11 - 0x148]
lea r8, [r11 - 0x368]
lea rdx, [r11 - 0x478]
mov rcx, r13
call fcn.1401dd430
lea rdx, [rsp + 0x4e0]
lea rcx, [rsp + 0x3d0]
call qword [sym.imp.KERNEL32.dll_lstrcpyA]
lea rdx, [rsp + 0x5f0]
lea rcx, [rsp + 0x3d0]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
mov rdx, r13
lea rcx, [rsp + 0x2c0]
call qword [sym.imp.KERNEL32.dll_lstrcpyA]
lea rdx, str..bak
lea rcx, [rsp + 0x2c0]
call qword [sym.imp.KERNEL32.dll_lstrcatA]
lea r9, [rsp + 0x1b0]
xor r8d, r8d
lea rdx, [0x14026ee5c]
lea rcx, [rsp + 0x3d0]
call qword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
je 0x1400069f5
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 2
xor r9d, r9d
xor r8d, r8d
mov edx, 0x40000000
lea rcx, [rsp + 0x1b0]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rdi, rax
mov qword [rsp + 0x58], rax
cmp rax, 0xffffffffffffffff
je 0x1400069f5
movsxd rcx, dword [r14 + 0x4c]
lea rax, [0x14026eef0]
mov rax, qword [rax + rcx*8]
mov qword [rsp + 0x68], rax
or r12, 0xffffffffffffffff
inc r12
cmp byte [rax + r12], bl
jne 0x140006881
lea rcx, [r14 + 0x58]
call fcn.140007df4
mov qword [rsp + 0x60], rax
mov r15d, ebx
mov dword [rsp + 0x48], ebx
cmp r15d, eax
jge 0x140006950
movsxd rdx, r15d
call fcn.1400080b4
mov eax, dword [rax + 8]
mov dword [rsp + 0x44], eax
test eax, eax
jle 0x140006900
movsxd rdx, r15d
lea rcx, [r14 + 0x58]
call fcn.1400080b4
mov rcx, qword [rax]
call fcn.140005e84
mov rdx, rax
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x40]
mov r8d, dword [rsp + 0x44]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1400069f5
mov eax, dword [rsp + 0x44]
cmp eax, dword [rsp + 0x40]
jne 0x1400069f5
mov rax, qword [rsp + 0x60]
dec eax
cmp r15d, eax
jge 0x14000693a
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x40]
mov r8d, r12d
mov rdx, qword [rsp + 0x68]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1400069f5
cmp r12d, dword [rsp + 0x40]
jne 0x1400069f5
inc r15d
mov dword [rsp + 0x48], r15d
mov rax, qword [rsp + 0x60]
lea rcx, [r14 + 0x58]
jmp 0x14000689f
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
or rdi, 0xffffffffffffffff
mov qword [rsp + 0x58], rdi
mov rcx, r13
cmp dword [r14 + 0x50], ebx
je 0x1400069b9
lea rdx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov rsi, rax
mov qword [rsp + 0x50], rax
cmp rax, rdi
je 0x1400069bf
lea rcx, [rsp + 0x2c0]
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
lea rdx, [rsp + 0x2c0]
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
je 0x1400069f5
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
or rsi, rdi
mov qword [rsp + 0x50], rsi
jmp 0x1400069bf
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
mov rdx, r13
lea rcx, [rsp + 0x1b0]
call qword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
je 0x1400069f5
mov rax, qword [r14]
xor edx, edx
mov rcx, r14
call qword [rax + 0xa8]
mov eax, dword [r14 + 0xa8]
mov dword [r14 + 0xac], eax
mov ebx, 1
cmp rsi, 0xffffffffffffffff
je 0x140006a04
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
cmp rdi, 0xffffffffffffffff
je 0x140006a13
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, [rsp + 0x1b0]
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, ebx
mov rcx, qword [rsp + 0x920]
xor rcx, rsp
call fcn.1401d5080
lea r11, [rsp + 0x930]
mov rbx, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret