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

Disassembly:
sub esp, 0x4d4
push ebx
push ebp
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x2dd]
mov byte [esp + 0x2dc], 0
rep stosd dword es:[edi], eax
mov ecx, 0x40
lea edi, [esp + 0x3e1]
mov byte [esp + 0x3e0], al
mov ebp, dword [esp + 0x4e8]
rep stosd dword es:[edi], eax
mov ecx, 0x40
lea edi, [esp + 0x1d9]
mov byte [esp + 0x1d8], al
mov byte [esp + 0x14], al
rep stosd dword es:[edi], eax
mov ecx, 0x20
lea edi, [esp + 0x15]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x4f4]
mov edi, dword [sym.imp.MSVCRT.dll__snprintf]
push ebp
push 0x4193ac
mov ecx, dword [eax]
lea edx, [esp + 0x2e4]
push 0x101
push edx
mov dword [esp + 0x20], ecx
call edi
mov eax, dword [esp + 0x4fc]
add esp, 0x10
lea ecx, [esp + 0x3e0]
push eax
push ebp
push 0x41939c
push 0x101
push ecx
call edi
add esp, 0x14
lea edx, [esp + 0x98]
lea eax, [esp + 0x3e0]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4021b2
lea ecx, [esp + 0xc4]
lea edx, [esp + 0x2dc]
push ecx
push edx
push 0x41939c
lea eax, [esp + 0x1e4]
push 0x101
push eax
call edi
lea ecx, [esp + 0x1ec]
push ecx
call fcn.00404d60
add esp, 0x18
cmp eax, 2
jne 0x402194
mov ecx, 0x20
xor eax, eax
lea edi, [esp + 0x14]
lea edx, [esp + 0x14]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0xac]
push edx
stosb byte es:[edi], al
mov eax, dword [esp + 0xb4]
push eax
push ecx
call fcn.00404da0
mov esi, dword [esp + 0x4fc]
add esp, 0xc
lea eax, [esp + 0x14]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x402181
test cl, cl
je 0x40217d
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x402181
add eax, 2
add esi, 2
test cl, cl
jne 0x40215d
xor eax, eax
jmp 0x402186
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jle 0x40218e
inc dword [esp + 0x10]
mov edi, dword [sym.imp.MSVCRT.dll__snprintf]
lea eax, [esp + 0x98]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4020ee
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
push ebp
push 0x4193ac
lea ecx, [esp + 0x2e4]
push 0x101
push ecx
call edi
add esp, 0x10
lea edx, [esp + 0x3e0]
push ebp
push str._s.
push 0x101
push edx
call edi
add esp, 0x10
lea eax, [esp + 0x98]
lea ecx, [esp + 0x3e0]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x402347
lea edx, [esp + 0xc4]
lea eax, [esp + 0x2dc]
push edx
push eax
push 0x41939c
lea ecx, [esp + 0x1e4]
push 0x101
push ecx
call edi
lea edx, [esp + 0x1ec]
push edx
call fcn.00404d60
add esp, 0x18
cmp eax, 1
jne 0x402311
mov esi, 0x419398
lea eax, [esp + 0xc4]
mov dl, byte [eax]
mov bl, byte [esi]
mov cl, dl
cmp dl, bl
jne 0x402274
test cl, cl
je 0x402270
mov dl, byte [eax + 1]
mov bl, byte [esi + 1]
mov cl, dl
cmp dl, bl
jne 0x402274
add eax, 2
add esi, 2
test cl, cl
jne 0x40224c
xor eax, eax
jmp 0x402279
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x402311
mov esi, 0x419394
lea eax, [esp + 0xc4]
mov dl, byte [eax]
mov bl, byte [esi]
mov cl, dl
cmp dl, bl
jne 0x4022b5
test cl, cl
je 0x4022b1
mov dl, byte [eax + 1]
mov bl, byte [esi + 1]
mov cl, dl
cmp dl, bl
jne 0x4022b5
add eax, 2
add esi, 2
test cl, cl
jne 0x40228d
xor eax, eax
jmp 0x4022ba
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x402311
mov ecx, 0x20
xor eax, eax
lea edi, [esp + 0x14]
mov edx, dword [esp + 0xac]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0xb0]
stosb byte es:[edi], al
lea eax, [esp + 0x14]
push eax
push ecx
push edx
call fcn.00404da0
mov ecx, dword [esp + 0x4fc]
mov edx, dword [esp + 0x4f8]
lea eax, [esp + 0x1c]
push eax
push ecx
lea eax, [esp + 0x1ec]
push edx
push eax
call fcn.00402020
mov edi, dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x1c
lea ecx, [esp + 0x98]
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x402203
push ebp
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [esp + 0x4f4]
mov edx, dword [esp + 0x10]
pop edi
pop esi
pop ebp
mov dword [eax], edx
pop ebx
add esp, 0x4d4
ret
mov edx, dword [esp + 0x4f4]
mov ecx, dword [esp + 0x10]
pop edi
pop esi
pop ebp
mov dword [edx], ecx
pop ebx
add esp, 0x4d4
ret