Function at 0x402047
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x35c
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
mov dword [ebp - 0x10], 1
je 0x4022bc
cmp dword [ebp + 0x10], ebx
je 0x4022bc
push dword [ebp + 0x10]
call fcn.0040ea36
cmp eax, ebx
pop ecx
je 0x402080
cmp byte [eax], 0x5c
jne 0x402080
mov byte [eax], bl
push esi
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push edi
push ebx
push ebx
push 0xb
push dword [ebp + 8]
call esi
push ebx
mov edi, 0x184
push ebx
push edi
push dword [ebp + 8]
call esi
push ebx
push ebx
push edi
push dword [ebp + 0xc]
call esi
push dword [ebp + 0x10]
call dword [sym.imp.USER32.dll_CharLowerA]
push dword [ebp + 0x10]
mov dword [ebp - 0x14], eax
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_SetWindowTextA]
push dword [ebp + 0x10]
lea eax, [ebp - 0x114]
push str._s.
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push 0x5c
push dword [ebp - 0x14]
call sub.CRTDLL.dll_strchr
mov edi, eax
pop ecx
cmp edi, ebx
pop ecx
je 0x4020f7
cmp dword [ebp - 0x10], ebx
je 0x4020ee
inc edi
mov al, byte [edi]
mov byte [edi], bl
mov byte [ebp - 1], al
jmp 0x402110
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0x10]
jne 0x402110
cmp dword [ebp - 0x10], ebx
je 0x402110
push 0x416024
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push dword [ebp - 0x14]
push ebx
push 0x180
push dword [ebp + 8]
call esi
mov dword [ebp - 0xc], eax
mov eax, edi
neg eax
movzx ecx, word [ebp - 0xc]
sbb eax, eax
add eax, 0xc
mov dword [ebp - 8], eax
movzx eax, ax
shl eax, 0x10
or eax, ecx
push eax
push dword [ebp - 0xc]
push 0x19a
push dword [ebp + 8]
call esi
cmp edi, ebx
je 0x402165
mov al, byte [ebp - 1]
mov byte [edi], al
xor eax, eax
cmp dword [ebp - 0x10], ebx
mov dword [ebp - 0x10], ebx
sete al
add edi, eax
mov dword [ebp - 0x14], edi
jmp 0x4020d6
mov eax, dword [ebp - 0xc]
push 0x41
inc eax
pop ecx
mov dword [ebp + 0x10], eax
mov ax, word [0x416020]
mov word [ebp - 0x21c], ax
xor eax, eax
lea edi, [ebp - 0x21a]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x35c]
push eax
lea eax, [ebp - 0x114]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x4021fa
test byte [ebp - 0x35c], 0x10
je 0x4021e1
cmp byte [ebp - 0x330], 0x2e
je 0x4021e1
lea eax, [ebp - 0x330]
push eax
lea eax, [ebp - 0x21c]
push str.__s_
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x21c]
push eax
push ebx
push 0x180
push dword [ebp + 0xc]
call esi
lea eax, [ebp - 0x35c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4021a1
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
push ebx
push ebx
push 0x18b
push dword [ebp + 0xc]
call esi
mov edi, eax
mov dword [ebp - 8], ebx
cmp edi, ebx
jbe 0x402266
lea eax, [ebp - 0x114]
push eax
push dword [ebp - 8]
push 0x189
push dword [ebp + 0xc]
call esi
cmp byte [ebp - 0x113], 0x2e
je 0x40225e
mov byte [ebp + eax - 0x115], bl
lea eax, [ebp - 0x113]
push eax
push ebx
push 0x180
push dword [ebp + 8]
call esi
movzx ecx, word [ebp + 0x10]
or ecx, 0xa0000
mov dword [ebp - 0xc], eax
push ecx
push eax
push 0x19a
push dword [ebp + 8]
call esi
inc dword [ebp - 8]
cmp dword [ebp - 8], edi
jb 0x40220f
mov edi, dword [ebp + 8]
push ebx
push 1
push 0xb
push edi
call esi
push 1
push ebx
push edi
call dword [sym.imp.USER32.dll_InvalidateRect]
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 1
push edi
call dword [sym.imp.USER32.dll_GetScrollRange]
cmp dword [ebp - 8], ebx
jne 0x402296
cmp dword [ebp - 0xc], ebx
je 0x4022ac
mov eax, dword [ebp + 0x10]
add eax, 0xfffffffe
cmp eax, ebx
jg 0x4022a2
xor eax, eax
push ebx
push eax
push 0x197
push edi
call esi
mov eax, dword [ebp + 0x10]
push ebx
dec eax
push eax
push 0x186
push edi
call esi
pop edi
pop esi
pop ebx
leave
ret