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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ce908
mov eax, dword fs:[0]
push eax
sub esp, 0x2ac
mov eax, dword [0x64a070]
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 ebx, edx
mov dword [ebp - 0x2b8], ebx
mov edi, ecx
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2b0], eax
xor eax, eax
push 0xffffffffffffffff
push eax
push edi
mov byte [ebp - 0x2a9], 1
mov dword [ebp - 0x2c], 7
mov dword [ebp - 0x30], 0
mov word [ebp - 0x40], ax
call fcn.00408f10
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x28]
push 1
xor eax, eax
mov dword [ebp - 0x14], 7
push 0x5f8f60
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
call fcn.00408a10
push ecx
lea edx, [ebp - 0x28]
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x40]
call fcn.0051de40
mov byte [ebp - 4], 0
add esp, 4
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x51f92e
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00409510
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x2a8]
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
mov dword [ebp - 0x44], 7
xor eax, eax
mov dword [ebp - 0x2b4], esi
push eax
push 0x5f8398
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x48], 0
mov word [ebp - 0x58], ax
call fcn.00408a10
mov byte [ebp - 4], 2
mov eax, 1
mov ecx, dword [ebx + 0x10]
cmp ecx, eax
cmovae ecx, eax
cmp dword [ebx + 0x14], 8
jb 0x51f98c
mov eax, dword [ebx]
jmp 0x51f98e
mov eax, ebx
push 1
push 0x5f17f8
push ecx
push eax
call fcn.0040ac30
add esp, 0x10
test eax, eax
je 0x51f9b2
push 1
push 0x5f17f8
lea ecx, [ebp - 0x58]
call fcn.00408a10
push 0xffffffffffffffff
push 0
push ebx
lea ecx, [ebp - 0x58]
call fcn.0040aa30
cmp esi, 0xffffffff
je 0x51fb34
mov esi, dword [sym.imp.KERNEL32.dll_lstrcmpW]
mov ebx, dword [ebp + 0xc]
push 0x5f17f8
lea eax, [ebp - 0x27c]
push eax
call esi
test eax, eax
je 0x51fb0d
push 0x5f8f68
lea eax, [ebp - 0x27c]
push eax
call esi
test eax, eax
je 0x51fb0d
lea eax, [ebp - 0x40]
cmp eax, edi
je 0x51fa10
push 0xffffffffffffffff
push 0
push edi
mov ecx, eax
call fcn.00408f10
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
cmp word [ebp - 0x27c], ax
je 0x51fa45
lea eax, [ebp - 0x27c]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x51fa36
sub eax, edx
sar eax, 1
push eax
lea eax, [ebp - 0x27c]
push eax
lea ecx, [ebp - 0x28]
call fcn.00408a10
push ecx
lea edx, [ebp - 0x28]
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x40]
call fcn.0051de40
mov byte [ebp - 4], 2
add esp, 4
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x51fa81
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00409510
test byte [ebp - 0x2a8], 0x10
je 0x51fab4
test bl, bl
je 0x51fb0d
mov edx, dword [ebp - 0x2b8]
lea ecx, [ebp - 0x40]
push 0
push ebx
push dword [ebp - 0x2b0]
call fcn.0051f870
add esp, 0xc
mov byte [ebp - 0x2a9], al
jmp 0x51fb0d
lea eax, [ebp - 0x27c]
push eax
lea ecx, [ebp - 0x28]
call fcn.00408810
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x48]
cmp eax, ecx
jbe 0x51faf4
lea edx, [ebp - 0x58]
sub eax, ecx
push edx
push ecx
push eax
lea ecx, [ebp - 0x28]
call fcn.0042b0d0
test eax, eax
jne 0x51faf4
mov ecx, dword [ebp - 0x2b0]
lea eax, [ebp - 0x40]
push eax
call fcn.0041e7d0
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x14]
cmp eax, 8
jb 0x51fb0d
inc eax
lea ecx, [ebp - 0x28]
push eax
push dword [ebp - 0x28]
call fcn.00409510
lea eax, [ebp - 0x2a8]
push eax
push dword [ebp - 0x2b4]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x51f9d1
push dword [ebp - 0x2b4]
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [ebp - 0x44]
cmp eax, 8
jb 0x51fb49
inc eax
lea ecx, [ebp - 0x58]
push eax
push dword [ebp - 0x58]
call fcn.00409510
xor eax, eax
mov dword [ebp - 0x44], 7
mov word [ebp - 0x58], ax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x48], 0
cmp eax, 8
jb 0x51fb72
inc eax
lea ecx, [ebp - 0x40]
push eax
push dword [ebp - 0x40]
call fcn.00409510
mov al, byte [ebp - 0x2a9]
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.0057608a
mov esp, ebp
pop ebp
ret