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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push r14
push r15
lea rbp, [rsp - 0x190]
sub rsp, 0x290
mov r14, r8
mov r15, rdx
mov rsi, rcx
test r9b, r9b
je 0x140004010
xor edx, edx
lea rcx, [rbp - 0x80]
mov r8d, 0x208
call fcn.1400a5760
mov edx, 0x104
lea rcx, [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x140004080
movabs rax, 0xa5b89f0b6b8c1503
mov qword [rsp + 0x2b0], rdi
mov qword [rsp + 0x60], rax
xor ecx, ecx
movabs rax, 0x7c7a43d5f57f66fd
mov qword [rsp + 0x68], rax
movabs rax, 0x7f94d6a806b4fd82
mov qword [rsp + 0x70], rax
movabs rax, 0xe66fa662a0d8dcc4
mov qword [rsp + 0x78], rax
movabs rax, 0xd7a57f9fe26b5f15
mov qword [rsp + 0x40], rax
movabs rax, 0x147ca74314f58e66
mov qword [rsp + 0x48], rax
movabs rax, 0xec7fcdd69a06b3fd
mov qword [rsp + 0x50], rax
movabs rax, 0x6fe662a6d8a0a1dc
mov qword [rsp + 0x58], rax
nop word [rax + rax]
movzx eax, word [rsp + rcx*2 + 0x40]
mov rdi, rcx
rol ax, 8
mov word [rsp + rcx*2 + 0x40], ax
and edi, 3
jne 0x140003bfa
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
movzx eax, word [rsp + rcx*2 + 0x42]
lea rdx, [rcx + 1]
rol ax, 8
mov word [rsp + rcx*2 + 0x42], ax
and edx, 3
jne 0x140003c5e
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
movzx eax, word [rsp + rcx*2 + 0x44]
lea r8, [rcx - 2]
rol ax, 8
mov word [rsp + rcx*2 + 0x44], ax
and r8d, 3
jne 0x140003c89
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
movzx eax, word [rsp + rcx*2 + 0x46]
lea r9, [rcx - 1]
rol ax, 8
mov word [rsp + rcx*2 + 0x46], ax
and r9d, 3
jne 0x140003cb5
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
jmp 0x140003cc5
cmp rcx, 4
jne 0x140003b84
mov eax, dword [rsp + 0x4a]
lea rdx, [rcx + 1]
bswap eax
mov dword [rsp + 0x4a], eax
lea r8, [rcx - 2]
movzx eax, word [rsp + rcx*2 + 0x42]
lea r9, [rcx - 1]
rol ax, 8
and edx, 3
mov word [rsp + rcx*2 + 0x42], ax
and r8d, 3
movzx eax, word [rsp + rcx*2 + 0x44]
and r9d, 3
rol ax, 8
mov word [rsp + rcx*2 + 0x44], ax
movzx eax, word [rsp + rcx*2 + 0x46]
rol ax, 8
mov word [rsp + rcx*2 + 0x46], ax
movzx eax, word [rsp + rcx*2 + 0x48]
rol ax, 8
mov word [rsp + rcx*2 + 0x48], ax
jmp 0x140003cf3
cmp rcx, 3
jne 0x140003ba9
mov eax, dword [rsp + 0x4a]
lea r8, [rcx - 2]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x44]
rol ax, 8
mov word [rsp + rcx*2 + 0x44], ax
and r8d, ecx
jmp 0x140003c9d
cmp rcx, 2
jne 0x140003bcf
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x46]
lea r9, [rcx - 1]
rol ax, 8
mov word [rsp + rcx*2 + 0x46], ax
and r9d, 3
jmp 0x140003cc5
cmp rcx, 1
jne 0x140003cc5
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x48]
rol ax, 8
mov word [rsp + rcx*2 + 0x48], ax
test rdi, rdi
jne 0x140003ce4
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
jmp 0x140003cf3
test rcx, rcx
jne 0x140003cf3
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x4a]
rol ax, 8
mov word [rsp + rcx*2 + 0x4a], ax
test rdx, rdx
jne 0x140003d12
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
jmp 0x140003d22
cmp rcx, 0xffffffffffffffff
jne 0x140003d22
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x4c]
rol ax, 8
mov word [rsp + rcx*2 + 0x4c], ax
test r8, r8
jne 0x140003d41
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
jmp 0x140003d51
cmp rcx, 0xfffffffffffffffe
jne 0x140003d51
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
movzx eax, word [rsp + rcx*2 + 0x4e]
rol ax, 8
mov word [rsp + rcx*2 + 0x4e], ax
test r9, r9
jne 0x140003d70
mov eax, dword [rsp + 0x42]
bswap eax
mov dword [rsp + 0x42], eax
jmp 0x140003d80
cmp rcx, 0xfffffffffffffffd
jne 0x140003d80
mov eax, dword [rsp + 0x4a]
bswap eax
mov dword [rsp + 0x4a], eax
add rcx, 8
cmp rcx, 8
jb 0x140003b60
movdqa xmm0, xmmword [rsp + 0x40]
xor eax, eax
pxor xmm0, xmmword [rsp + 0x60]
movdqa xmmword [rsp + 0x40], xmm0
movzx ecx, word [rsp + rax*2 + 0x50]
mov rdi, rax
rol cx, 8
mov word [rsp + rax*2 + 0x50], cx
and edi, 3
jne 0x140003e3c
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
movzx ecx, word [rsp + rax*2 + 0x52]
lea rdx, [rax + 1]
rol cx, 8
mov word [rsp + rax*2 + 0x52], cx
and edx, 3
jne 0x140003ea0
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
movzx ecx, word [rsp + rax*2 + 0x54]
lea r8, [rax - 2]
rol cx, 8
mov word [rsp + rax*2 + 0x54], cx
and r8d, 3
jne 0x140003ecb
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
movzx ecx, word [rsp + rax*2 + 0x56]
lea r9, [rax - 1]
rol cx, 8
mov word [rsp + rax*2 + 0x56], cx
and r9d, 3
jne 0x140003ef7
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
jmp 0x140003f07
cmp rax, 4
jne 0x140003dc6
mov ecx, dword [rsp + 0x5a]
lea rdx, [rax + 1]
bswap ecx
mov dword [rsp + 0x5a], ecx
lea r8, [rax - 2]
movzx ecx, word [rsp + rax*2 + 0x52]
lea r9, [rax - 1]
rol cx, 8
and edx, 3
mov word [rsp + rax*2 + 0x52], cx
and r8d, 3
movzx ecx, word [rsp + rax*2 + 0x54]
and r9d, 3
rol cx, 8
mov word [rsp + rax*2 + 0x54], cx
movzx ecx, word [rsp + rax*2 + 0x56]
rol cx, 8
mov word [rsp + rax*2 + 0x56], cx
movzx ecx, word [rsp + rax*2 + 0x58]
rol cx, 8
mov word [rsp + rax*2 + 0x58], cx
jmp 0x140003f35
cmp rax, 3
jne 0x140003deb
mov ecx, dword [rsp + 0x5a]
lea r8, [rax - 2]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x54]
rol cx, 8
mov word [rsp + rax*2 + 0x54], cx
and r8d, eax
jmp 0x140003edf
cmp rax, 2
jne 0x140003e11
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x56]
lea r9, [rax - 1]
rol cx, 8
mov word [rsp + rax*2 + 0x56], cx
and r9d, 3
jmp 0x140003f07
cmp rax, 1
jne 0x140003f07
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x58]
rol cx, 8
mov word [rsp + rax*2 + 0x58], cx
test rdi, rdi
jne 0x140003f26
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
jmp 0x140003f35
test rax, rax
jne 0x140003f35
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x5a]
rol cx, 8
mov word [rsp + rax*2 + 0x5a], cx
test rdx, rdx
jne 0x140003f54
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
jmp 0x140003f64
cmp rax, 0xffffffffffffffff
jne 0x140003f64
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x5c]
rol cx, 8
mov word [rsp + rax*2 + 0x5c], cx
test r8, r8
jne 0x140003f83
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
jmp 0x140003f93
cmp rax, 0xfffffffffffffffe
jne 0x140003f93
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
movzx ecx, word [rsp + rax*2 + 0x5e]
rol cx, 8
mov word [rsp + rax*2 + 0x5e], cx
test r9, r9
jne 0x140003fb2
mov ecx, dword [rsp + 0x52]
bswap ecx
mov dword [rsp + 0x52], ecx
jmp 0x140003fc2
cmp rax, 0xfffffffffffffffd
jne 0x140003fc2
mov ecx, dword [rsp + 0x5a]
bswap ecx
mov dword [rsp + 0x5a], ecx
add rax, 8
cmp rax, 8
jb 0x140003da2
movdqa xmm0, xmmword [rsp + 0x50]
lea r8, [rsp + 0x40]
pxor xmm0, xmmword [rsp + 0x70]
lea rcx, [rbp - 0x80]
mov edx, 0x104
movdqa xmmword [rsp + 0x50], xmm0
call fcn.1400a82f8
mov r8d, 0xb
lea rdx, [rbp - 0x80]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_MoveFileExW]
mov rdi, qword [rsp + 0x2b0]
mov qword [rsp + 0x30], 0
xor r9d, r9d
mov dword [rsp + 0x28], pe_nt_image_headers64
xor r8d, r8d
mov edx, 0x40000000
mov dword [rsp + 0x20], 2
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
lea rcx, [rax - 1]
cmp rcx, 0xfffffffffffffffd
ja 0x140004080
lea r9, [rbp + 0x1c8]
mov dword [rbp + 0x1c8], 0
mov r8d, r14d
mov qword [rsp + 0x20], 0
mov rdx, r15
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, rbx
test eax, eax
jne 0x14000409b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
lea r11, [rsp + 0x290]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x140004082