Function at 0x18040cfe
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x284
mov eax, dword [0x180f51f0]
xor eax, esp
mov dword [esp + 0x280], eax
movzx ecx, byte [0x180fb8f9]
mov eax, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
neg ecx
sbb ecx, ecx
mov ebx, 0x180fbba0
and ecx, ebx
push 4
mov dword [esp + 0x14], eax
pop esi
je 0x18040d6a
push esi
push esi
mov dword [esp + 0x1c], ecx
call fcn.18001d8a
push dword [ebp + 0xc]
mov dword [esp + 0x1c], eax
push dword [edi]
lea eax, [esp + 0x1c]
push str._FindDirectoryPackagesInfo___s___d_
push eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
call fcn.18001000
add esp, 0x10
and dword [esp + 0x38], 0
push 0x24c
lea eax, [esp + 0x40]
push 0
push eax
call fcn.1809d820
add esp, 0xc
push 0x180c2d58
mov eax, edi
lea ecx, [esp + 0x38]
call fcn.18002e5e
mov eax, dword [eax]
pop ecx
lea ecx, [esp + 0x38]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x34]
add eax, 0xfffffff0
call fcn.18004250
cmp dword [esp + 0xc], 0xffffffff
jne 0x18040e10
call fcn.1800fc86
movzx ecx, byte [0x180fb8f9]
neg ecx
sbb ecx, ecx
and ecx, ebx
mov edi, eax
je 0x18040df9
push esi
push esi
mov dword [esp + 0x1c], ecx
call fcn.18001d8a
push edi
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x18]
push str._FindDirectoryPackagesInfo_failed__0x_x_
push eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], esi
call fcn.18001000
add esp, 0xc
mov eax, edi
mov ecx, dword [esp + 0x28c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1809ccb5
mov esp, ebp
pop ebp
ret
xor ebx, ebx
mov eax, dword [ebp + 0xc]
sub eax, 0
je 0x18040eb1
dec eax
je 0x18040e54
dec eax
jne 0x18040f0f
cmp dword [esp + 0x38], 0x80
je 0x18040e3d
test byte [esp + 0x38], 0x10
jne 0x18040f0f
push dword [esp + 0x10]
lea eax, [esp + 0x3c]
push edi
call fcn.18040c00
pop ecx
pop ecx
mov ebx, eax
jmp 0x18040f0f
test byte [esp + 0x38], 0x10
je 0x18040f0f
lea eax, [esp + 0x38]
call fcn.18040bc0
test al, al
jne 0x18040f0f
lea eax, [esp + 0x64]
push eax
lea eax, [esp + 0x34]
call fcn.18003fba
lea eax, [esp + 0x30]
push eax
mov eax, edi
lea ebx, [esp + 0x30]
call fcn.1800bc24
mov eax, dword [esp + 0x34]
pop ecx
add eax, 0xfffffff0
call fcn.18004250
push dword [esp + 0x10]
mov eax, ebx
push 2
push eax
call fcn.18040cfe
mov ebx, eax
mov eax, dword [esp + 0x38]
jmp 0x18040f04
test byte [esp + 0x38], 0x10
je 0x18040f0f
lea eax, [esp + 0x38]
call fcn.18040bc0
test al, al
jne 0x18040f0f
lea eax, [esp + 0x64]
push eax
lea eax, [esp + 0x28]
call fcn.18003fba
lea eax, [esp + 0x24]
push eax
mov eax, edi
lea ebx, [esp + 0x2c]
call fcn.1800bc24
mov eax, dword [esp + 0x28]
pop ecx
add eax, 0xfffffff0
call fcn.18004250
push dword [esp + 0x10]
mov eax, ebx
push 1
push eax
call fcn.18040cfe
mov ebx, eax
mov eax, dword [esp + 0x34]
add esp, 0xc
add eax, 0xfffffff0
call fcn.18004250
test ebx, ebx
jl 0x18040f2e
lea eax, [esp + 0x38]
push eax
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x18040e12
xor esi, esi
jmp 0x18040f6d
movzx ecx, byte [0x180fb8f9]
neg ecx
sbb ecx, ecx
and ecx, 0x180fbba0
je 0x18040f6b
push esi
push esi
mov dword [esp + 0x1c], ecx
call fcn.18001d8a
push ebx
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x18]
push str._FindDirectoryPackagesInfo_failed__0x_x_
push eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], esi
call fcn.18001000
add esp, 0xc
mov esi, ebx
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, esi
jmp 0x18040dfb