Function at 0x1402c21a8
Capabilities:
Check if file exists
Delete file

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x298]
sub rsp, 0x370
mov qword [rsp + 0x70], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x14045cbf0]
xor rax, rsp
mov qword [rbp + 0x260], rax
mov r12, rdx
mov rcx, rdx
call fcn.1402c1f38
neg al
sbb esi, esi
not esi
and esi, 5
mov rdx, qword [r12]
xor r14d, r14d
test rdx, rdx
je 0x1402c24a0
test esi, esi
jne 0x1402c24a0
lea esi, [r14 + 5]
mov rdx, qword [rdx + 0x38]
lea rcx, [rsp + 0x30]
call fcn.14000cb18
nop
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
or r15, 0xffffffffffffffff
test eax, eax
jne 0x1402c2251
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x1402c2251
lea esi, [rax + 2]
jmp 0x1402c247f
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
je 0x1402c23e8
lea rcx, [rbp - 0x70]
call fcn.1400779cc
nop
lea rax, vtable.Piriform::CFilteredDirectory.0
mov qword [rbp - 0x70], rax
lea rdx, [0x14034fa44]
lea rcx, [rbp + 0x230]
call fcn.14000cb18
mov qword [rbp + 0x238], r14
mov qword [rbp + 0x240], r14
mov qword [rbp + 0x248], r14
mov word [rbp + 0x258], 1
mov byte [rbp + 0x25a], 1
mov rdx, qword [rsp + 0x30]
lea rcx, [rbp - 0x70]
call fcn.140077f08
lea rax, [rbp + 0x238]
mov qword [rsp + 0x78], rax
mov rbx, qword [rbp + 0x238]
mov rdi, qword [rbp + 0x240]
mov qword [rbp - 0x80], rdi
mov qword [rsp + 0x68], rbx
cmp rbx, rdi
je 0x1402c234b
mov qword [rsp + 0x38], r15
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov r8d, 0xc0000000
mov rdx, qword [rbx]
lea rcx, [rsp + 0x38]
call fcn.140021fb8
test eax, eax
sete r13b
mov rcx, qword [rsp + 0x38]
cmp rcx, r15
je 0x1402c2325
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rsp + 0x38], r15
test r13b, r13b
sete al
test al, al
je 0x1402c2341
mov rcx, qword [rbx]
call fcn.140229cb0
test al, al
je 0x1402c2341
add rbx, 8
jmp 0x1402c22dd
mov esi, 5
jmp 0x1402c23da
test r14b, r14b
jne 0x1402c23da
mov rcx, r12
call fcn.1402c2038
mov esi, eax
test eax, eax
jne 0x1402c23da
lea rdi, vtable.Piriform::IOperationImpl_struct_Piriform::IOperation_.0
mov qword [rsp + 0x48], rdi
mov byte [rsp + 0x50], r14b
mov qword [rsp + 0x58], r14
xor r9d, r9d
xor r8d, r8d
lea edx, [rax + 1]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rsp + 0x58], rax
lea rax, vtable.Piriform::CCleanDirectory.0
mov qword [rsp + 0x48], rax
mov byte [rsp + 0x60], 1
mov rax, qword [r12]
mov rbx, qword [rax + 0x38]
lea rcx, [rsp + 0x48]
call qword [method.Piriform::IOperationImpl_struct_Piriform::IOperation_.virtual_16]
test al, al
jne 0x1402c23c4
mov rdx, rbx
lea rcx, [rsp + 0x48]
call fcn.1400722dc
nop
mov qword [rsp + 0x48], rdi
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x1402c23da
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop
lea rcx, [rbp - 0x70]
call fcn.1400786d4
jmp 0x1402c247f
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x1402c247f
mov rax, qword [r12]
mov qword [rsp + 0x40], r15
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov r8d, 0xc0000000
mov rdx, qword [rax + 0x38]
lea rcx, [rsp + 0x40]
call fcn.140021fb8
test eax, eax
sete bl
mov rcx, qword [rsp + 0x40]
cmp rcx, r15
je 0x1402c2438
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test bl, bl
sete al
test al, al
je 0x1402c247f
mov rax, qword [r12]
mov rcx, qword [rax + 0x38]
call fcn.140229cb0
test al, al
je 0x1402c247f
mov rcx, r12
call fcn.1402c2038
mov esi, eax
test eax, eax
jne 0x1402c247f
mov rax, qword [r12]
mov rcx, qword [rax + 0x38]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x1402c247c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x1402c247f
mov esi, r14d
mov rdx, qword [rsp + 0x30]
add rdx, 0xffffffffffffffe8
mov eax, r15d
lock xadd dword [rdx + 0x10], eax
add eax, r15d
test eax, eax
jg 0x1402c24a0
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov eax, esi
mov rcx, qword [rbp + 0x260]
xor rcx, rsp
call fcn.1400be110
lea r11, [rsp + 0x370]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret