Function at 0x408ba8
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe84
push ebx
push esi
push edi
mov ebx, dword [ebp + 0x18]
mov edi, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
mov byte [edi], 0
mov eax, dword [ebp + 0x14]
mov byte [eax], 0
cmp byte [esi + 4], 0
jne 0x408c1f
cmp byte [esi + 5], 0
je 0x408be2
mov edx, dword [esi + 0x3ef]
push edx
call sub.KERNEL32.dll_FindClose
mov byte [esi + 5], 0
cmp byte [esi + 7], 0
jne 0x408bef
xor eax, eax
jmp 0x408eb9
lea edx, [ebp - 0x148]
push edx
lea ecx, [esi + 7]
push ecx
call sub.KERNEL32.dll_FindFirstFileA
mov dword [esi + 0x3ef], eax
cmp dword [esi + 0x3ef], 0xffffffff
jne 0x408c15
xor eax, eax
jmp 0x408eb9
mov dl, 1
mov byte [esi + 5], dl
mov byte [esi + 4], dl
jmp 0x408c51
lea eax, [ebp - 0x148]
push eax
mov ecx, dword [esi + 0x3ef]
push ecx
call sub.KERNEL32.dll_FindNextFileA
test eax, eax
jne 0x408c51
mov eax, dword [esi + 0x3ef]
push eax
call sub.KERNEL32.dll_FindClose
xor edx, edx
mov byte [esi + 5], dl
mov byte [esi + 4], dl
xor eax, eax
jmp 0x408eb9
mov ecx, dword [ebp + 0x10]
lea eax, [ebp - 0x11c]
push ecx
push eax
push edi
call fcn.004989f4
add esp, 0xc
mov edx, dword [ebp + 0x10]
mov byte [edi + edx - 1], 0
test byte [ebp - 0x148], 2
je 0x408c7c
mov ecx, dword [ebp + 0x14]
mov byte [ecx], 1
test ebx, ebx
je 0x408eb7
mov word [ebx], 2
xor eax, eax
mov word [ebx + 2], 0
mov dword [ebx + 8], eax
xor edx, edx
mov dword [ebx + 0xc], edx
mov word [ebx + 0x10], 2
mov word [ebx + 6], 1
mov ecx, dword [ebp - 0x12c]
mov eax, ecx
neg ecx
add ecx, dword [ebp - 0x128]
mov dword [ebx + 0x12], ecx
mov word [ebx + 4], 0x8000
test byte [ebp - 0x148], 0x10
je 0x408ccd
mov word [ebx + 4], 0x4000
mov dword [ebx + 0x16], 0x12ceec50
mov dword [ebx + 0x1a], 0x12ceec50
mov dword [ebx + 0x1e], 0x12ceec50
lea edx, [ebp - 8]
push edx
lea ecx, [ebp - 0x134]
push ecx
call sub.KERNEL32.dll_FileTimeToLocalFileTime
test eax, eax
je 0x408d7f
lea eax, [ebp - 0x17c]
push eax
lea edx, [ebp - 8]
push edx
call sub.KERNEL32.dll_FileTimeToSystemTime
test eax, eax
je 0x408d7f
movzx ecx, word [ebp - 0x170]
mov dword [ebp - 0x16c], ecx
movzx eax, word [ebp - 0x172]
mov dword [ebp - 0x168], eax
movzx edx, word [ebp - 0x174]
mov dword [ebp - 0x164], edx
movzx ecx, word [ebp - 0x176]
mov dword [ebp - 0x160], ecx
movzx eax, word [ebp - 0x17a]
dec eax
mov dword [ebp - 0x15c], eax
movzx edx, word [ebp - 0x17c]
add edx, 0xfffff894
mov dword [ebp - 0x158], edx
lea ecx, [ebp - 0x16c]
push ecx
call fcn.004a9350
pop ecx
mov esi, eax
mov dword [ebx + 0x1a], esi
inc esi
jne 0x408d7f
mov dword [ebx + 0x1a], 0x12ceec50
lea eax, [ebp - 8]
push eax
lea edx, [ebp - 0x144]
push edx
call sub.KERNEL32.dll_FileTimeToLocalFileTime
test eax, eax
je 0x408e1b
lea ecx, [ebp - 0x17c]
push ecx
lea eax, [ebp - 8]
push eax
call sub.KERNEL32.dll_FileTimeToSystemTime
test eax, eax
je 0x408e1b
movzx edx, word [ebp - 0x170]
mov dword [ebp - 0x16c], edx
movzx ecx, word [ebp - 0x172]
mov dword [ebp - 0x168], ecx
movzx eax, word [ebp - 0x174]
mov dword [ebp - 0x164], eax
movzx edx, word [ebp - 0x176]
mov dword [ebp - 0x160], edx
movzx ecx, word [ebp - 0x17a]
dec ecx
mov dword [ebp - 0x15c], ecx
movzx eax, word [ebp - 0x17c]
add eax, 0xfffff894
mov dword [ebp - 0x158], eax
lea edx, [ebp - 0x16c]
push edx
call fcn.004a9350
pop ecx
mov esi, eax
mov dword [ebx + 0x1e], esi
inc esi
jne 0x408e1b
mov dword [ebx + 0x1e], 0x12ceec50
lea eax, [ebp - 8]
push eax
lea edx, [ebp - 0x13c]
push edx
call sub.KERNEL32.dll_FileTimeToLocalFileTime
test eax, eax
je 0x408eb7
lea ecx, [ebp - 0x17c]
push ecx
lea eax, [ebp - 8]
push eax
call sub.KERNEL32.dll_FileTimeToSystemTime
test eax, eax
je 0x408eb7
movzx edx, word [ebp - 0x170]
mov dword [ebp - 0x16c], edx
movzx ecx, word [ebp - 0x172]
mov dword [ebp - 0x168], ecx
movzx eax, word [ebp - 0x174]
mov dword [ebp - 0x164], eax
movzx edx, word [ebp - 0x176]
mov dword [ebp - 0x160], edx
movzx ecx, word [ebp - 0x17a]
dec ecx
mov dword [ebp - 0x15c], ecx
movzx eax, word [ebp - 0x17c]
add eax, 0xfffff894
mov dword [ebp - 0x158], eax
lea edx, [ebp - 0x16c]
push edx
call fcn.004a9350
pop ecx
mov esi, eax
mov dword [ebx + 0x16], esi
inc esi
jne 0x408eb7
mov dword [ebx + 0x16], 0x12ceec50
mov al, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret