Function at 0x4082c4
Capabilities:
Check if file exists
Delete file
Move file
Set file attributes

Disassembly:
push 0x108
mov eax, 0x470ca0
call fcn.0045d4e7
mov edi, ecx
push 0x80
push edi
mov dword [ebp - 0x60], edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x40891b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov dword [ebp - 0x64], esi
cmp esi, 2
je 0x40891b
cmp esi, 3
je 0x40891b
cmp byte [ebp + 8], 0
je 0x408608
push edi
push str.delete_on_reboot:__s
call fcn.00416edc
pop ecx
pop ecx
cmp esi, 5
jne 0x408406
and dword [ebp - 4], 0
mov ecx, dword [ebp - 0x60]
mov ebx, 0x1f01ff
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x30]
push eax
push 1
movsd dword es:[edi], dword [esi]
call fcn.0041c25e
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
pop ecx
movsd dword es:[edi], dword [esi]
pop ecx
lea eax, [ebp - 0x114]
push eax
movsd dword es:[edi], dword [esi]
call fcn.00406c26
pop ecx
push eax
lea eax, [ebp - 0x30]
push eax
mov byte [ebp - 4], 1
push dword [ebp - 0x60]
xor ecx, ecx
inc ecx
call fcn.0041c2e2
add esp, 0xc
lea ecx, [ebp - 0x114]
mov byte [ebp - 4], 0
call fcn.00406b81
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x114]
push eax
movsd dword es:[edi], dword [esi]
call fcn.00406c05
pop ecx
push eax
lea eax, [ebp - 0x30]
push eax
mov byte [ebp - 4], 2
push dword [ebp - 0x60]
xor ecx, ecx
inc ecx
call fcn.0041c2e2
add esp, 0xc
lea ecx, [ebp - 0x114]
call fcn.00406b81
or dword [ebp - 4], 0xffffffff
mov ebx, dword [ebp - 0x60]
push 4
pop esi
push esi
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x4085fe
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push ebx
push str.DING::CUtils::DeleteFileW_965__:_MoveFileEx_failed_to_delete_file:__s___lu__r_n
mov dword [ebp - 0x64], edi
call fcn.00416f04
add esp, 0xc
cmp edi, 5
jne 0x4085e7
push 1
push ebx
call fcn.00408923
pop ecx
pop ecx
lea ecx, [ebp - 0x5c]
call fcn.0042a635
mov dword [ebp - 4], esi
push ebx
lea ecx, [ebp - 0x60]
mov byte [ebp - 4], 5
call fcn.0040533e
lea esi, [ebp - 0x60]
mov byte [ebp - 4], 6
call fcn.00409edf
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
push 0xffffffffffffffff
mov ecx, esi
call fcn.0040a796
push 1
push dword [ebp - 0x60]
call fcn.00408923
pop ecx
pop ecx
mov ecx, dword [ebp - 0x60]
add ecx, 0xfffffff0
call fcn.00403af7
jmp 0x4085c4
lea ecx, [ebp - 0x5c]
call fcn.0042a5f3
lea ecx, [ebp - 0x5c]
test al, al
je 0x4085e2
call fcn.0042a615
mov eax, 0x8007000e
jmp 0x40891d
call fcn.0042a615
test edi, edi
jle 0x4085f7
and edi, 0xffff
or edi, 0x80070000
mov eax, edi
jmp 0x40891d
mov eax, 0x80070bc2
jmp 0x40891d
push esi
push edi
push str.DING::CUtils::DeleteFileW_993__:_failed_to_delete_file:__s___lu_
call fcn.00416f04
add esp, 0xc
cmp esi, 5
jne 0x4086fc
mov dword [ebp - 4], 8
mov ecx, dword [ebp - 0x60]
mov ebx, 0x1f01ff
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x30]
push eax
push 1
movsd dword es:[edi], dword [esi]
call fcn.0041c25e
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
pop ecx
movsd dword es:[edi], dword [esi]
pop ecx
lea eax, [ebp - 0x114]
push eax
movsd dword es:[edi], dword [esi]
call fcn.00406c26
pop ecx
push eax
lea eax, [ebp - 0x30]
push eax
mov byte [ebp - 4], 9
push dword [ebp - 0x60]
xor ecx, ecx
inc ecx
call fcn.0041c2e2
add esp, 0xc
lea ecx, [ebp - 0x114]
mov byte [ebp - 4], 8
call fcn.00406b81
mov dword [ebp - 0x70], ebx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x68], ebx
lea esi, [ebp - 0x70]
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, 0x498c88
lea edi, [ebp - 0x24]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x114]
push eax
movsd dword es:[edi], dword [esi]
call fcn.00406c05
pop ecx
push eax
lea eax, [ebp - 0x30]
push eax
mov byte [ebp - 4], 0xa
push dword [ebp - 0x60]
xor ecx, ecx
inc ecx
call fcn.0041c2e2
add esp, 0xc
lea ecx, [ebp - 0x114]
call fcn.00406b81
or dword [ebp - 4], 0xffffffff
mov esi, dword [ebp - 0x64]
push dword [ebp - 0x60]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x4087b4
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x40891b
cmp eax, 3
je 0x40891b
cmp esi, 5
je 0x408733
cmp eax, 5
jne 0x4087b4
push 1
push dword [ebp - 0x60]
call fcn.00408923
pop ecx
pop ecx
lea ecx, [ebp - 0x94]
call fcn.0042a635
mov dword [ebp - 4], 0xc
mov byte [ebp - 4], 0xd
push dword [ebp - 0x60]
lea ecx, [ebp - 0x60]
call fcn.0040533e
lea esi, [ebp - 0x60]
mov byte [ebp - 4], 0xe
call fcn.00409edf
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
push 0xffffffffffffffff
mov ecx, esi
call fcn.0040a796
push 1
push dword [ebp - 0x60]
call fcn.00408923
pop ecx
pop ecx
mov ecx, dword [ebp - 0x60]
add ecx, 0xfffffff0
call fcn.00403af7
lea ecx, [ebp - 0x94]
call fcn.0042a5f3
lea ecx, [ebp - 0x94]
test al, al
jne 0x4085d3
call fcn.0042a615
mov esi, dword [ebp - 0x64]
test esi, esi
jle 0x4087c4
and esi, 0xffff
or esi, 0x80070000
mov eax, esi
jmp 0x40891d
xor eax, eax
call fcn.0045d543
ret