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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x325c
call fcn.00548050
mov eax, dword [0x5c6fc4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov eax, ecx
lea esi, [ebp - 0x3008]
push edi
mov dword [ebp - 0x325c], eax
mov edx, eax
sub esi, eax
nop dword [eax]
movzx eax, word [edx]
lea edx, [edx + 2]
mov word [esi + edx - 2], ax
test ax, ax
jne 0x40f530
lea ecx, [ebp - 0x3008]
add ecx, 0xfffffffe
nop dword [eax]
mov ax, word [ecx + 2]
lea ecx, [ecx + 2]
test ax, ax
jne 0x40f550
mov eax, dword [0x5a89a0]
mov dword [ecx], eax
mov eax, dword [0x5a89a4]
mov dword [ecx + 4], eax
mov ax, word [0x5a89a8]
push 0x5c
push 0x5d0510
mov word [ecx + 8], ax
call fcn.005493c5
add esp, 8
test eax, eax
je 0x40f5a5
lea ecx, [eax + 2]
lea edx, [ebp - 0x1008]
sub edx, ecx
movzx eax, word [ecx]
lea ecx, [ecx + 2]
mov word [edx + ecx - 2], ax
test ax, ax
jne 0x40f593
jmp 0x40f5c7
xor ecx, ecx
nop word [eax + eax]
movzx eax, word [ecx + 0x5d0510]
lea ecx, [ecx + 2]
mov word [ebp + ecx - 0x100a], ax
test ax, ax
jne 0x40f5b0
lea eax, [ebp - 0x3258]
push eax
lea eax, [ebp - 0x3008]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40f771
lea eax, [ebp - 0x3258]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
je 0x40f76a
mov esi, 1
lea eax, [ebp - 0x322c]
xor edi, edi
push str._app.exe
push eax
call fcn.0054915a
add esp, 8
test eax, eax
je 0x40f636
lea eax, [ebp - 0x322c]
push str._app.exe
push eax
call fcn.0054915a
add esp, 8
cmp word [eax + 0x10], di
cmove edi, esi
lea ecx, [ebp - 0x1008]
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40f640
sub ecx, edx
sar ecx, 1
cmp ecx, 4
jbe 0x40f6dd
lea eax, [ebp - 0x322c]
push 0x5c
push eax
call fcn.005493c5
add esp, 8
mov esi, eax
lea eax, [ebp - 0x1008]
push eax
test esi, esi
je 0x40f6a8
push esi
call fcn.0054915a
add esp, 8
test eax, eax
je 0x40f6dd
lea ecx, [ebp - 0x1008]
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40f690
sub ecx, edx
sar ecx, 1
cmp word [esi + ecx*2 + 2], ax
jne 0x40f6dd
jmp 0x40f6e1
lea eax, [ebp - 0x322c]
push eax
call fcn.0054915a
add esp, 8
test eax, eax
je 0x40f6dd
lea ecx, [ebp - 0x1008]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40f6c4
sub ecx, edx
sar ecx, 1
cmp word [ebp + ecx*2 - 0x322a], ax
je 0x40f6e1
test edi, edi
je 0x40f74f
push 0x1000
lea eax, [ebp - 0x2008]
push 0
push eax
call fcn.0054a720
lea eax, [ebp - 0x322c]
push eax
push dword [ebp - 0x325c]
lea eax, [ebp - 0x2008]
push str._s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x1c
lea eax, [ebp - 0x2008]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40f74f
test al, 0x10
jne 0x40f74f
push 0x5cfc48
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea eax, [ebp - 0x2008]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0x5cfc48
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea eax, [ebp - 0x3258]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
mov esi, 1
test eax, eax
jne 0x40f601
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005478fb
mov esp, ebp
pop ebp
ret