Function at 0x406910
Capabilities:
Enumerate files on windows

Disassembly:
sub esp, 0x54c
push ebx
mov ebx, dword [esp + 0x55c]
push ebp
mov ebp, dword [esp + 0x564]
push esi
mov esi, dword [esp + 0x55c]
push edi
xor edi, edi
push esi
lea eax, [esp + 0x360]
push 0x463728
mov dword [ebp], edi
push eax
mov dword [esp + 0x20], edi
mov dword [ebx], edi
call fcn.0043ce53
add esp, 0xc
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x35c]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [esp + 0x18], eax
jne 0x406985
push esi
call fcn.00406db0
add esp, 4
mov eax, 0x7d6
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54c
ret
lea eax, [esp + 0x48]
push 0x4628c0
push eax
call fcn.00404630
add esp, 8
test al, al
jne 0x406b26
lea ecx, [esp + 0x48]
push 0x4628c4
push ecx
call fcn.00404630
add esp, 8
test al, al
jne 0x406b26
mov edx, dword [esp + 0x564]
lea eax, [esp + 0x48]
push edx
push eax
call fcn.00404770
add esp, 8
test al, al
je 0x406b26
mov eax, dword [esp + 0x570]
cmp eax, 3
jne 0x406a02
lea ecx, [esp + 0x48]
push 0x4628c0
push ecx
call fcn.00404fd0
lea edx, [esp + 0x50]
add esp, 8
cmp eax, edx
je 0x406b26
jmp 0x406a06
test eax, eax
je 0x406a76
lea eax, [esp + 0x48]
lea ecx, [esp + 0x15c]
push eax
push esi
push 0x4617d8
push ecx
call fcn.0043ce53
lea edx, [esp + 0x23]
lea eax, [esp + 0x16c]
push edx
push eax
call fcn.00403f40
mov esi, eax
add esp, 0x18
test esi, esi
jne 0x406b4a
mov al, byte [esp + 0x13]
test al, al
je 0x406a76
lea ecx, [esp + 0x15c]
push ecx
call fcn.00406030
mov ecx, dword [esp + 0x574]
add esp, 4
dec ecx
je 0x406a6d
dec ecx
jne 0x406a76
cmp eax, 2
jne 0x406b26
jmp 0x406a76
cmp eax, 1
jne 0x406b26
cmp dword [ebp], edi
jl 0x406ab0
mov edx, dword [0x4632c8]
push 0x1055
lea eax, [edi*4 + 0xc8]
push edx
push 1
push eax
mov eax, dword [ebx]
push eax
call sym.report_nls.exe_gen__mem_realloc
add esp, 0x14
cmp eax, 0x3e8
jbe 0x406b6b
add edi, 0x32
mov dword [ebx], eax
mov dword [esp + 0x14], edi
lea ecx, [esp + 0x48]
test ecx, ecx
je 0x406ac8
lea edi, [esp + 0x48]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
jmp 0x406aca
xor ecx, ecx
mov edx, dword [0x4632c8]
push 0x1056
push edx
inc ecx
push 1
push ecx
call sym.report_nls.exe_gen__mem_malloc
mov ecx, dword [ebp]
mov edx, dword [ebx]
add esp, 0x10
mov dword [edx + ecx*4], eax
mov eax, dword [ebp]
mov ecx, dword [ebx]
mov edx, dword [ecx + eax*4]
test edx, edx
je 0x406bac
lea edi, [esp + 0x48]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebp]
mov edi, dword [esp + 0x14]
inc eax
mov dword [ebp], eax
mov esi, dword [esp + 0x18]
lea ecx, [esp + 0x1c]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x406bd2
mov esi, dword [esp + 0x560]
jmp 0x406985
mov edx, dword [0x4632c8]
push 0x1040
push edx
call fcn.00408cf0
add esp, 8
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54c
ret
mov eax, dword [0x4632c8]
push 0x1055
push eax
push 0x46167c
call fcn.00408c10
mov ecx, dword [ebp]
mov edx, dword [ebx]
push ecx
push edx
call fcn.00404ca0
add esp, 0x14
mov dword [ebx], 0
mov dword [ebp], 0
mov eax, 0x7e3
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54c
ret
mov eax, dword [0x4632c8]
push 0x1059
push eax
push 0x46370c
call fcn.00408c10
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54c
ret
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [ebx]
test eax, eax
je 0x406c44
mov ecx, dword [ebp]
test ecx, ecx
jle 0x406c44
mov edx, dword [0x4632c8]
push 0x1061
push edx
push 1
shl ecx, 2
push ecx
push eax
call sym.report_nls.exe_gen__mem_realloc
add esp, 0x14
mov dword [ebx], eax
test eax, eax
jne 0x406c30
mov edx, dword [0x4632c8]
push 0x1062
push edx
push 0x4636fc
call fcn.00408c10
add esp, 0xc
mov eax, 0x7e3
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54c
ret
mov ecx, dword [ebp]
push 0x406c60
push 4
push ecx
push eax
call fcn.0043deb5
add esp, 0x10
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x54c
ret