Function at 0x14002d370
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
push rdi
sub rsp, 0x50
cmp qword [rcx + 0x18], 8
mov rdi, rcx
jb 0x14002d383
mov rcx, qword [rcx]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x14002d5b7
cmp qword [rdi + 0x18], 8
mov rcx, rdi
mov qword [rsp + 0x68], rbp
mov qword [rsp + 0x70], rsi
jb 0x14002d3a8
mov rcx, qword [rdi]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
cmp qword [rdi + 0x18], 8
mov rcx, rdi
jb 0x14002d3bb
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp eax, 1
lea rbp, [0x14018bd54]
sete sil
je 0x14002d4d1
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x14002d4d1
cmp qword [rdi + 0x18], 8
mov rcx, rdi
jb 0x14002d3f1
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov r8d, eax
test al, 1
je 0x14002d4d1
mov rax, qword [0x1401cde08]
test rax, rax
je 0x14002d454
cmp qword [rdi + 0x18], 8
mov rcx, rdi
jb 0x14002d41b
mov rcx, qword [rdi]
mov dword [rsp + 0x38], r8d
lea rdx, str.File__s_is_with_read_only._Its_attribute_is:__d._UnSetting_its_read_only_attr_and_retry_deleting
mov qword [rsp + 0x30], rcx
lea r8, str.FileUtils
mov qword [rsp + 0x28], rdx
mov r9, rbp
lea rdx, str.OOBEUtils
mov qword [rsp + 0x20], rbp
mov ecx, 0x14
call qword [case.0x14004792d.0]
jmp 0x14002d49f
mov rcx, qword [0x1401cde10]
test rcx, rcx
je 0x14002d49f
cmp qword [rdi + 0x18], 8
mov rdx, rdi
jb 0x14002d46d
mov rdx, qword [rdi]
mov rax, qword [rcx]
lea r9, str.FileUtils
mov dword [rsp + 0x30], r8d
mov r8, rbp
mov qword [rsp + 0x28], rdx
lea rdx, str.File__s_is_with_read_only._Its_attribute_is:__d._UnSetting_its_read_only_attr_and_retry_deleting
mov qword [rsp + 0x20], rdx
mov edx, 0x14
mov rax, qword [rax + 0x68]
call qword [case.0x14004792d.0]
cmp qword [rdi + 0x18], 8
mov rcx, rdi
jb 0x14002d4ac
mov rcx, qword [rdi]
mov edx, 0x80
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp qword [rdi + 0x18], 8
mov rcx, rdi
jb 0x14002d4c4
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp eax, 1
sete sil
test sil, sil
jne 0x14002d5a3
cmp qword [0x1401cde08], 0
je 0x14002d545
cmp qword [rdi + 0x18], 8
jb 0x14002d4ee
mov rdi, qword [rdi]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x38], eax
mov r9, rbp
mov qword [rsp + 0x30], rdi
lea r8, str.FileUtils
lea rax, str.Failed_to_delete_file:__s_LastError:_d
mov ecx, 0x32
mov qword [rsp + 0x28], rax
lea rdx, str.OOBEUtils
mov rax, qword [0x1401cde08]
mov qword [rsp + 0x20], rbp
call qword [case.0x14004792d.0]
mov rbp, qword [rsp + 0x68]
movzx eax, sil
mov rsi, qword [rsp + 0x70]
add rsp, 0x50
pop rdi
ret
mov qword [rsp + 0x60], rbx
mov rbx, qword [0x1401cde10]
test rbx, rbx
je 0x14002d59e
cmp qword [rdi + 0x18], 8
jb 0x14002d560
mov rdi, qword [rdi]
mov rbx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [0x1401cde10]
lea r9, str.FileUtils
mov dword [rsp + 0x30], eax
mov r8, rbp
lea rax, str.Failed_to_delete_file:__s_LastError:_d
mov qword [rsp + 0x28], rdi
mov qword [rsp + 0x20], rax
mov edx, 0x32
mov rax, qword [rbx + 0x68]
call qword [case.0x14004792d.0]
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x68]
movzx eax, sil
mov rsi, qword [rsp + 0x70]
add rsp, 0x50
pop rdi
ret
mov al, 1
add rsp, 0x50
pop rdi
ret