Function at 0x5821b0
Capabilities:
Check if file exists
Delete file
Enumerate files on windows
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5acca0
mov eax, dword fs:[0]
push eax
sub esp, 0xadc
mov eax, dword [0x6340c4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [0x63501c]
push 0x208
mov dword [ebp - 0xae8], eax
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.004c76f0
push 0x208
lea eax, [ebp - 0x628]
push 0
push eax
call fcn.004c76f0
push 0x208
lea eax, [ebp - 0x420]
push 0
push eax
call fcn.004c76f0
push 0x268
mov dword [ebp - 0xad8], 0
mov dword [ebp - 0xad4], 0
call fcn.00446660
mov esi, eax
lea edx, [ebp - 0xadc]
add esp, 0x28
mov dword [ebp - 0xadc], esi
mov ecx, esi
call fcn.00446a40
lea ecx, [esi + 4]
call fcn.00446a40
lea ecx, [esi + 8]
call fcn.00446a40
mov word [esi + 0xc], 0x101
mov dword [ebp - 0xad8], esi
push 0x104
lea eax, [ebp - 0x628]
mov dword [ebp - 4], 0
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x5822f9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x5822a8
movzx esi, si
or esi, 0x80070000
push 0
push 0
push esi
push str.GetModuleFileName
push 0x45
push 0x23b
push str.C:drone_src_srcCommonUtilityMinidump.cpp
push str.CExceptionHandlerEx::PruneMiniDumpFiles
call fcn.00573980
mov eax, dword [ebp - 0xad8]
add esp, 0x20
push dword [eax + 4]
lea eax, [ebp - 0xad8]
push eax
mov ecx, eax
call fcn.004afe80
push 0x268
push dword [ebp - 0xad8]
call fcn.00446620
mov eax, esi
jmp 0x5824e6
push 0x6803b0
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x58239a
test al, 0x10
je 0x58239a
lea eax, [ebp - 0xadc]
mov dword [ebp - 0xadc], 0
push eax
lea eax, [ebp - 0x420]
push eax
push 0x104
lea eax, [ebp - 0x628]
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov eax, dword [ebp - 0xadc]
test eax, eax
jne 0x582374
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x58235e
movzx esi, si
or esi, 0x80070000
push 0
push 0
push esi
push str.GetFullPathName
push 0x45
push 0x24b
jmp 0x5822b9
push 0x5e4ba4
push eax
push 0x6803b0
push str._s_s__s_______________.mdmp
lea eax, [ebp - 0x218]
push 0x104
push eax
call fcn.005850a0
add esp, 0x18
jmp 0x5823bf
push 0x5e4ba4
lea eax, [ebp - 0x628]
push eax
push str._s__s_______________.mdmp
lea eax, [ebp - 0x218]
push 0x104
push eax
call fcn.005850a0
add esp, 0x14
xor eax, eax
mov word [ebp - 0x420], ax
lea eax, [ebp - 0x878]
push eax
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x582414
mov eax, dword [ebp - 0xad8]
push dword [eax + 4]
lea eax, [ebp - 0xad8]
push eax
mov ecx, eax
call fcn.004afe80
push 0x268
push dword [ebp - 0xad8]
call fcn.00446620
mov eax, 1
jmp 0x5824e6
test byte [ebp - 0x878], 0x10
jne 0x582461
mov eax, dword [ebp - 0x874]
lea esi, [ebp - 0x878]
mov ecx, dword [ebp - 0x870]
lea edi, [ebp - 0xac8]
mov dword [ebp - 0xad0], eax
lea eax, [ebp - 0xad0]
mov dword [ebp - 0xacc], ecx
mov ecx, 0x94
push eax
rep movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0xae0]
push eax
lea ecx, [ebp - 0xad8]
call fcn.004afd40
lea eax, [ebp - 0x878]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x582414
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x582485
movzx eax, ax
or eax, 0x80070000
xor edi, edi
cmp eax, 0x80070012
push ebx
cmovne edi, eax
call dword [sym.imp.KERNEL32.dll_FindClose]
test edi, edi
jns 0x582505
push 0
push 0
push edi
push str.FindNextFile
push 0x45
push 0x284
push str.C:drone_src_srcCommonUtilityMinidump.cpp
push str.CExceptionHandlerEx::PruneMiniDumpFiles
call fcn.00573980
add esp, 0x20
mov eax, dword [ebp - 0xad8]
push dword [eax + 4]
lea eax, [ebp - 0xad8]
push eax
mov ecx, eax
call fcn.004afe80
push 0x268
push dword [ebp - 0xad8]
call fcn.00446620
mov eax, edi
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004c59c5
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0xae4]
mov dword [ebp - 0xae4], 0
push eax
lea eax, [ebp - 0x420]
push eax
push 0x104
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov eax, dword [ebp - 0xae4]
test eax, eax
jne 0x582564
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x58254e
movzx esi, si
or esi, 0x80070000
push 0
push 0
push esi
push str.GetFullPathName
push 0x45
push 0x292
jmp 0x5822b9
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x218]
push eax
call fcn.004d4367
mov ecx, dword [ebp - 0xae8]
mov ebx, 0x104
sub ebx, eax
add esp, 4
mov eax, dword [ebp - 0xad8]
mov esi, dword [eax]
cmp ecx, dword [ebp - 0xad4]
jae 0x5824c3
nop dword [eax]
cmp esi, eax
je 0x5824c3
mov ecx, dword [ebp - 0xae4]
lea edx, [esi + 0x44]
push ebx
call fcn.00585040
add esp, 4
lea eax, [ebp - 0x420]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x5825fe
lea eax, [ebp - 0x420]
push eax
push str.failed_to_delete__ls
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.DeleteFile
push 0x57
push 0x2a9
push str.C:drone_src_srcCommonUtilityMinidump.cpp
push str.CExceptionHandlerEx::PruneMiniDumpFiles
call fcn.00573980
add esp, 0x24
lea ecx, [ebp - 0xadc]
mov dword [ebp - 0xadc], esi
call fcn.00458b80
push esi
lea ecx, [ebp - 0xad8]
call fcn.00458be0
push 0x268
push eax
call fcn.00446620
mov eax, dword [ebp - 0xae8]
add esp, 8
mov esi, dword [ebp - 0xadc]
cmp eax, dword [ebp - 0xad4]
jae 0x5824bd
mov eax, dword [ebp - 0xad8]
jmp 0x5825a0