Function at 0x140084ad0
Capabilities:
Check if file exists
Copy file
Create directory
Move file

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r14
push r15
lea rbp, [rsp - 0x190]
sub rsp, 0x290
mov rax, qword [0x14017b278]
xor rax, rsp
mov qword [rbp + 0x180], rax
mov rsi, rdx
mov r14, rcx
lea rbx, [rcx + 0x28]
mov qword [rsp + 0x60], rbx
xor r15d, r15d
test rbx, rbx
je 0x140084b1d
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_AcquireSRWLockExclusive]
nop
lea rdi, [r14 + 0x48]
mov rdx, rdi
cmp qword [rdi + 0x18], 8
jb 0x140084b2e
mov rdx, qword [rdi]
mov r8d, 1
lea rcx, [rsp + 0x30]
call fcn.1400834bc
xor edx, edx
mov r8d, 0x208
lea rcx, [rsp + 0x70]
call fcn.14009b2d0
mov rdx, rdi
cmp qword [rdi + 0x18], 8
jb 0x140084b5d
mov rdx, qword [rdi]
mov r8d, 0x104
lea rcx, [rsp + 0x70]
lea rax, [rsp + 0x70]
sub rdx, rax
lea rax, [r8 + 0x7ffffefa]
test rax, rax
je 0x140084b92
movzx eax, word [rdx + rcx]
test ax, ax
je 0x140084b92
mov word [rcx], ax
add rcx, 2
sub r8, 1
jne 0x140084b70
lea rax, [rcx - 2]
test r8, r8
cmovne rax, rcx
mov word [rax], r15w
lea rcx, [rsp + 0x70]
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
xor r8d, r8d
lea rdx, [rsp + 0x70]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
lea rdx, str.trusted.tmp
lea rcx, [rsp + 0x70]
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
xor r8d, r8d
lea rdx, [rsp + 0x70]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x140084c6d
mov rcx, rdi
cmp qword [rdi + 0x18], 8
jb 0x140084bf4
mov rcx, qword [rdi]
lea rsi, [r14 + 0x48]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x140084c2f
cmp qword [rsi + 0x18], 8
jb 0x140084c0c
mov rsi, qword [rsi]
mov qword [rsp + 0x28], r15
mov qword [rsp + 0x20], r15
mov r9d, 2
xor r8d, r8d
lea rdx, [rsp + 0x70]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_ReplaceFileW]
jmp 0x140084c47
cmp qword [rsi + 0x18], 8
jb 0x140084c39
mov rsi, qword [rsi]
mov rdx, rsi
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x140084cdc
cmp qword [rdi + 0x18], 8
jb 0x140084c59
mov rdi, qword [rdi]
mov r8d, 4
mov rdx, rdi
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_MoveFileExW]
mov rcx, qword [rsp + 0x30]
cmp rcx, 0xffffffffffffffff
je 0x140084ca3
cmp dword [rsp + 0x38], r15d
je 0x140084c9d
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
or r8d, 0xffffffff
mov r9d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_UnlockFileEx]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, r15d
test rbx, rbx
je 0x140084cb4
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_ReleaseSRWLockExclusive]
mov eax, edi
mov rcx, qword [rbp + 0x180]
xor rcx, rsp
call fcn.140086e90
mov rbx, qword [rsp + 0x2d0]
add rsp, 0x290
pop r15
pop r14
pop rdi
pop rsi
pop rbp
ret
mov rcx, qword [rsp + 0x30]
cmp rcx, 0xffffffffffffffff
je 0x140084d12
cmp dword [rsp + 0x38], r15d
je 0x140084d0c
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
or r8d, 0xffffffff
mov r9d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_UnlockFileEx]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.67136527_5D6B_4AC9_865B_3E392E982420
call qword [sym.imp.KERNEL32.dll_GlobalAddAtomW]
mov rcx, r14
call fcn.140083edc
mov rcx, r14
call fcn.140084334
mov edi, eax
jmp 0x140084ca6