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

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x31
push 0
push 0
dec ecx
jne 0x510a20
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], edx
mov ebx, eax
mov eax, dword [ebp - 4]
call fcn.00404728
xor eax, eax
push ebp
push 0x510f8d
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x150]
push eax
lea eax, [ebp - 0x154]
mov ecx, 0x510fa4
mov edx, dword [ebp - 4]
call fcn.00404584
mov eax, dword [ebp - 0x154]
call fcn.00404738
push eax
call sub.kernel32.dll_FindFirstFileA_1
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
je 0x510a81
mov al, 1
jmp 0x510f49
xor eax, eax
jmp 0x510f49
mov eax, dword [0x53ad38]
mov eax, dword [eax]
cmp byte [eax + 0x338], 2
je 0x510f51
mov eax, dword [0x53ab08]
mov eax, dword [eax]
call fcn.00490870
lea eax, [ebp - 8]
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
mov eax, dword [ebp - 0x150]
cmp eax, 0x10
je 0x510af1
cmp eax, 2
je 0x510af1
cmp eax, 4
je 0x510af1
cmp eax, 0x80
je 0x510af1
cmp eax, 0x100
je 0x510af1
cmp eax, 0x12
je 0x510af1
cmp eax, 0x13
je 0x510af1
cmp eax, 0x20
jne 0x510b8d
push dword [ebp - 4]
push 0x510fb4
push dword [ebp - 8]
lea eax, [ebp - 0x158]
mov edx, 3
call fcn.004045f8
mov edx, dword [ebp - 0x158]
mov eax, dword [ebx + 0x308]
call fcn.004707c4
mov eax, dword [ebp - 8]
mov edx, 0x510fc0
call fcn.00404684
je 0x510b8d
mov eax, dword [ebp - 8]
mov edx, 0x510fcc
call fcn.00404684
je 0x510b8d
push dword [ebp - 4]
push 0x510fb4
push dword [ebp - 8]
lea eax, [ebp - 0x15c]
mov edx, 3
call fcn.004045f8
mov eax, dword [ebp - 0x15c]
call fcn.004092ac
test al, al
je 0x510b8d
push dword [ebp - 4]
push 0x510fb4
push dword [ebp - 8]
lea eax, [ebp - 0x160]
mov edx, 3
call fcn.004045f8
mov edx, dword [ebp - 0x160]
mov eax, ebx
call fcn.00510a18
mov eax, dword [ebx + 0x334]
mov eax, dword [eax + 0x22c]
call fcn.00450c38
mov edi, eax
dec edi
test edi, edi
jl 0x510f33
inc edi
xor esi, esi
mov eax, dword [0x53ab08]
mov eax, dword [eax]
call fcn.00490870
mov eax, dword [0x53ad38]
mov eax, dword [eax]
cmp byte [eax + 0x338], 2
je 0x510f33
mov eax, dword [ebx + 0x334]
mov eax, dword [eax + 0x22c]
mov edx, esi
call fcn.00450c68
call fcn.004505d0
test al, al
je 0x510f2b
mov eax, dword [ebx + 0x334]
mov eax, dword [eax + 0x22c]
mov edx, esi
call fcn.00450c68
mov edx, dword [eax + 0x24]
lea eax, [ebp - 0x10]
call fcn.00404310
mov edx, dword [ebp - 0x10]
mov eax, 0x510fd8
call fcn.0040487c
test eax, eax
jle 0x510de3
lea eax, [ebp - 0x164]
push eax
mov ecx, 2
mov edx, 1
mov eax, dword [ebp - 0x10]
call fcn.00404798
mov eax, dword [ebp - 0x164]
mov edx, 0x510fe4
call fcn.00404684
jne 0x510dbc
lea eax, [ebp - 0x10]
mov ecx, 1
mov edx, 1
call fcn.004047d8
lea edx, [ebp - 0x168]
mov eax, dword [ebp - 8]
call fcn.0040955c
mov edx, dword [ebp - 0x168]
mov eax, dword [ebp - 0x10]
call fcn.00404684
jne 0x510f2b
mov edx, dword [0x511574]
mov eax, 0xc
call fcn.00405174
mov edi, eax
mov eax, edi
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 4]
push 0x510fb4
lea eax, [ebp - 0x16c]
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 0x16c]
lea eax, [edi + 4]
mov edx, 3
call fcn.004045f8
mov eax, dword [ebp - 0x130]
mov dword [edi + 8], eax
mov eax, dword [0x53ad38]
mov eax, dword [eax]
mov eax, dword [eax + 0x330]
mov edx, edi
call fcn.0041c7c0
mov eax, dword [ebx + 0x32c]
mov eax, dword [eax + 0x22c]
call fcn.00450bdc
mov edi, eax
lea edx, [ebp - 0x170]
mov eax, dword [ebx + 0x33c]
call fcn.00408d94
mov edx, dword [ebp - 0x170]
mov eax, edi
call fcn.0045067c
mov dl, 1
mov eax, edi
call fcn.00450614
push dword [ebp - 4]
push 0x510fb4
lea eax, [ebp - 0x178]
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 0x178]
lea eax, [ebp - 0x174]
mov edx, 3
call fcn.004045f8
mov edx, dword [ebp - 0x174]
mov eax, dword [edi + 8]
mov ecx, dword [eax]
call dword [ecx + 0x38]
mov edx, dword [ebx + 0x33c]
dec edx
mov edi, dword [ebx + 0x32c]
mov eax, dword [edi + 0x22c]
call fcn.00450c68
mov edx, eax
mov eax, edi
call fcn.00454388
mov eax, dword [ebx + 0x32c]
call fcn.00454370
mov dl, 1
call fcn.004505ac
mov eax, dword [ebx + 0x32c]
mov edx, dword [eax]
call dword [edx + 0xc4]
inc dword [ebx + 0x33c]
jmp 0x510f33
lea edx, [ebp - 0x17c]
mov eax, dword [ebp - 8]
call fcn.0040955c
mov edx, dword [ebp - 0x17c]
mov eax, dword [ebp - 0x10]
call fcn.00404684
je 0x510f33
jmp 0x510f2b
mov eax, dword [ebp - 0x10]
mov edx, dword [ebp - 8]
call fcn.00404684
jne 0x510f2b
mov edx, dword [0x511574]
mov eax, 0xc
call fcn.00405174
mov edi, eax
mov eax, edi
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 4]
push 0x510fb4
lea eax, [ebp - 0x180]
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 0x180]
lea eax, [edi + 4]
mov edx, 3
call fcn.004045f8
mov eax, dword [ebp - 0x130]
mov dword [edi + 8], eax
mov eax, dword [0x53ad38]
mov eax, dword [eax]
mov eax, dword [eax + 0x330]
mov edx, edi
call fcn.0041c7c0
mov eax, dword [ebx + 0x32c]
mov eax, dword [eax + 0x22c]
call fcn.00450bdc
mov edi, eax
lea edx, [ebp - 0x184]
mov eax, dword [ebx + 0x33c]
call fcn.00408d94
mov edx, dword [ebp - 0x184]
mov eax, edi
call fcn.0045067c
mov dl, 1
mov eax, edi
call fcn.00450614
push dword [ebp - 4]
push 0x510fb4
lea eax, [ebp - 0x18c]
lea edx, [ebp - 0x124]
mov ecx, 0x104
call fcn.004044e8
push dword [ebp - 0x18c]
lea eax, [ebp - 0x188]
mov edx, 3
call fcn.004045f8
mov edx, dword [ebp - 0x188]
mov eax, dword [edi + 8]
mov ecx, dword [eax]
call dword [ecx + 0x38]
mov edx, dword [ebx + 0x33c]
dec edx
mov edi, dword [ebx + 0x32c]
mov eax, dword [edi + 0x22c]
call fcn.00450c68
mov edx, eax
mov eax, edi
call fcn.00454388
mov eax, dword [ebx + 0x32c]
call fcn.00454370
mov dl, 1
call fcn.004505ac
mov eax, dword [ebx + 0x32c]
mov edx, dword [eax]
call dword [edx + 0xc4]
inc dword [ebx + 0x33c]
jmp 0x510f33
inc esi
dec edi
jne 0x510bac
lea eax, [ebp - 0x150]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_FindNextFileA
cmp eax, 1
sbb eax, eax
inc eax
test al, al
jne 0x510a88
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_FindClose_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x510f94
lea eax, [ebp - 0x18c]
mov edx, 0xf
call fcn.0040429c
lea eax, [ebp - 0x10]
call fcn.00404278
lea eax, [ebp - 8]
mov edx, 2
call fcn.0040429c
ret