Function at 0x1401b3ff0
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r14
sub rsp, 0x6c0
lea rbp, [rsp + 0x40]
mov rax, qword [0x1406836b8]
xor rax, rbp
mov qword [rbp + 0x670], rax
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
xor edx, edx
mov r8d, 0x432
lea rcx, [rbp + 0x20]
call sub.VCRUNTIME140.dll_memset
mov eax, 8
mov dword [rbp + 0x20], 0x4034b50
lea rcx, [rbp + 0x10]
mov word [rbp + 0x28], ax
call qword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
xor r14d, r14d
lea r8, [rbp + 4]
lea rdx, [rbp]
mov word [rbp + 4], r14w
lea rcx, [rbp + 0x10]
mov word [rbp], r14w
call qword [sym.imp.KERNEL32.dll_FileTimeToDosDateTime]
movzx eax, word [rbp]
mov word [rbp + 0x2c], ax
movzx eax, word [rbp + 4]
mov word [rbp + 0x2a], ax
test rbx, rbx
jne 0x1401b4081
mov eax, r14d
jmp 0x1401b409a
mov rax, 0xffffffffffffffff
nop dword [rax + rax]
inc rax
cmp word [rbx + rax*2], r14w
jne 0x1401b4090
test rdi, rdi
jne 0x1401b40a4
mov ecx, r14d
jmp 0x1401b40ba
mov rcx, 0xffffffffffffffff
nop dword [rax + rax]
inc rcx
cmp word [rdi + rcx*2], r14w
jne 0x1401b40b0
cmp eax, ecx
ja 0x1401b429e
test rbx, rbx
jne 0x1401b40cc
mov eax, r14d
jmp 0x1401b40dd
mov rax, 0xffffffffffffffff
inc rax
cmp word [rbx + rax*2], r14w
jne 0x1401b40d3
mov eax, eax
lea r8, [rdi + rax*2]
test r8, r8
je 0x1401b429e
mov edx, 0x104
lea rcx, [rbp + 0x460]
mov r9, 0xffffffffffffffff
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy_s]
mov edx, 0x104
lea rcx, [rbp + 0x460]
call sym.ErrorReportClient.exe_SfAddSlashToPathName
lea rcx, [rbp + 0x460]
mov rax, 0xffffffffffffffff
inc rax
cmp word [rcx + rax*2], r14w
jne 0x1401b4124
mov word [rbp + 0x3a], ax
lea r8, [rbp + 0x460]
mov eax, dword [rsi + 0x18]
lea rcx, [rbp + 0x42]
mov r9, 0xffffffffffffffff
mov dword [rbp + 0x3e], eax
mov edx, 0x104
mov dword [rbp + 8], r14d
mov dword [rbp + 0xc], r14d
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy_s]
mov rcx, qword [rsi + 0x10]
lea rax, [rbp + 0xc]
mov r9d, 0xffffffff
mov qword [rsp + 0x20], rax
mov r8d, 0x432
mov word [rbp + 0x24a], r14w
lea rdx, [rbp + 0x20]
call sym.ErrorReportClient.exe_SfList_AllocAndInsertItem
mov ebx, eax
test eax, eax
js 0x1401b42a3
mov rcx, qword [rsi + 8]
lea r9, [rbp + 8]
mov r8d, 0x1e
mov qword [rsp + 0x20], r14
lea rdx, [rbp + 0x20]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, eax
mov eax, dword [rbp + 8]
add dword [rsi + 0x18], eax
test ecx, ecx
je 0x1401b429a
mov qword [rsp + 0x38], r14
lea r8, [rbp + 0x460]
mov qword [rsp + 0x30], r14
mov r9d, 0xffffffff
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], r14
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
dec ax
movzx edi, ax
mov word [rbp + 0x3a], di
lea rax, [rdi + 1]
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x1401b420a
movabs rcx, 0xffffffffffffff0
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.14039bb40
sub rsp, rcx
lea rbx, [rsp + 0x40]
cmp r14w, word [rbp + 0x460]
jne 0x1401b422d
mov byte [rbx], r14b
jmp 0x1401b425a
mov qword [rsp + 0x38], r14
lea eax, [rdi + 1]
mov qword [rsp + 0x30], r14
lea r8, [rbp + 0x460]
mov dword [rsp + 0x28], eax
mov r9d, 0xffffffff
xor edx, edx
mov qword [rsp + 0x20], rbx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
movsxd rax, edi
lea r9, [rbp + 8]
mov rdx, rbx
mov qword [rsp + 0x20], r14
mov byte [rax + rbx], r14b
movzx r8d, word [rbp + 0x3a]
mov rcx, qword [rsi + 8]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1401b4293
movzx ecx, word [rbp + 0x3a]
mov edx, dword [rbp + 8]
cmp edx, ecx
jne 0x1401b4293
add dword [rsi + 0x18], edx
mov eax, r14d
jmp 0x1401b42a3
mov eax, 0x8004e009
jmp 0x1401b42a3
mov eax, ebx
jmp 0x1401b42a3
mov eax, 0x8004e00d
mov rcx, qword [rbp + 0x670]
xor rcx, rbp
call fcn.14039bbb0
lea rsp, [rbp + 0x680]
pop r14
pop rdi
pop rsi
pop rbx
pop rbp
ret