Function at 0x408855
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x16c
mov ebx, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov dword [esp], ebx
and edi, 4
call fcn.004087a1
mov dword [ebp - 0x160], eax
push ecx
test byte [ebp + 0xc], 8
je 0x40889c
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
push edx
sete al
movzx eax, al
add dword [0x42c3e8], eax
jmp 0x408aea
mov eax, dword [ebp + 0xc]
and eax, 1
mov dword [ebp - 0x15c], eax
je 0x4088c1
cmp dword [ebp - 0x160], 0
je 0x408ad0
test byte [ebp + 0xc], 2
je 0x408a7b
mov dword [esp + 4], ebx
mov dword [esp], 0x42bb40
call fcn.004080a0
cmp dword [ebp - 0x15c], 0
push eax
push eax
je 0x4088f4
mov dword [esp + 4], str..
mov dword [esp], 0x42bb40
call sub.KERNEL32.dll_lstrcatA
push eax
push eax
jmp 0x4088fd
mov dword [esp], ebx
call fcn.0040798b
push eax
cmp byte [ebx], 0
jne 0x40890b
cmp byte [0x42bb40], 0x5c
jne 0x40891d
mov dword [esp + 4], 0x40b4a0
mov dword [esp], ebx
call sub.KERNEL32.dll_lstrcatA
push eax
push eax
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push ecx
add eax, ebx
mov dword [ebp - 0x164], eax
lea eax, [ebp - 0x158]
mov dword [esp + 4], eax
mov dword [esp], 0x42bb40
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
push esi
push esi
mov esi, eax
cmp eax, 0xffffffff
je 0x408a5b
lea eax, [ebp - 0x12c]
mov dword [esp + 4], 0x3f
mov dword [esp], eax
call fcn.00407961
push edx
push edx
cmp byte [eax], 0
jne 0x40897e
mov dl, byte [ebp - 0x12c]
lea eax, [ebp - 0x12c]
jmp 0x408988
mov dl, byte [ebp - 0x28]
test dl, dl
je 0x408970
lea eax, [ebp - 0x28]
cmp dl, 0x2e
jne 0x4089a7
mov dl, byte [eax + 1]
test dl, dl
je 0x408a34
cmp dl, 0x2e
jne 0x4089a7
cmp byte [eax + 2], 0
je 0x408a34
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x164]
mov dword [esp], eax
call fcn.004080a0
push ecx
push ecx
test byte [ebp - 0x158], 0x10
je 0x4089e0
mov eax, dword [ebp + 0xc]
and eax, 3
cmp eax, 3
jne 0x408a34
mov eax, dword [ebp + 0xc]
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.00408855
jmp 0x408a32
mov dword [esp + 4], edi
mov dword [esp], ebx
call fcn.00407b3a
push edx
push edx
test eax, eax
jne 0x408a22
test edi, edi
je 0x408a1a
mov dword [esp + 4], ebx
mov dword [esp], 0xfffffff1
call fcn.00407088
push eax
push eax
mov dword [esp], ebx
mov dword [esp + 4], 0
call fcn.00408724
jmp 0x408a32
inc dword [0x42c3e8]
jmp 0x408a34
mov dword [esp + 4], ebx
mov dword [esp], 0xfffffff2
call fcn.00407088
push ecx
push ecx
lea eax, [ebp - 0x158]
mov dword [esp], esi
mov dword [esp + 4], eax
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
push edx
push edx
test eax, eax
jne 0x408953
mov dword [esp], esi
call dword [sym.imp.KERNEL32.dll_FindClose]
push ecx
cmp dword [ebp - 0x15c], 0
je 0x408aea
mov eax, dword [ebp - 0x164]
cmp dword [ebp - 0x160], 0
mov byte [eax - 1], 0
je 0x408ad0
mov dword [esp], ebx
call fcn.00408769
push edx
test eax, eax
je 0x408aea
mov dword [esp], ebx
call fcn.004080d4
mov eax, edi
push ecx
or eax, 1
mov dword [esp + 4], eax
mov dword [esp], ebx
call fcn.00407b3a
push esi
push esi
test eax, eax
jne 0x408ad8
test edi, edi
je 0x408ad0
mov dword [esp + 4], ebx
mov dword [esp], 0xfffffff1
call fcn.00407088
push edx
push edx
mov dword [esp], ebx
mov dword [esp + 4], 0
call fcn.00408724
jmp 0x408ae8
inc dword [0x42c3e8]
jmp 0x408aea
mov dword [esp + 4], ebx
mov dword [esp], 0xffffffe5
call fcn.00407088
push eax
push eax
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret 8