Function at 0x406850
Capabilities:
Check if file exists
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41ec00
mov eax, dword fs:[0]
push eax
sub esp, 0x2ac
mov eax, dword [0x42f034]
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 dword [ebp - 0x2b4], edx
mov dword [ebp - 0x2ac], ecx
mov edi, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 4], 0
push 0xffffffffffffffff
push eax
mov word [ebp - 0x40], ax
lea ecx, [ebp - 0x40]
lea eax, [ebp + 0x10]
mov dword [ebp - 0x2c], 7
push eax
mov dword [ebp - 0x30], 0
call fcn.00401640
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 1
call fcn.00404600
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
mov byte [ebp - 4], 0
mov esi, dword [sym.imp.MSVCR120.dll_void___cdecl_operator_delete_void__]
setne bl
cmp dword [ebp - 0x2c], 8
jb 0x4068f2
push dword [ebp - 0x40]
call esi
add esp, 4
test bl, bl
je 0x406b54
lea ecx, [ebp + 0x10]
call fcn.004047a0
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
push 0x24c
mov byte [ebp - 4], 2
push eax
mov dword [ebp - 0x2a8], eax
lea eax, [ebp - 0x2a4]
push eax
call sub.MSVCR120.dll_memset
add esp, 0xc
lea eax, [ebp + 0x10]
cmp dword [ebp + 0x24], 8
cmovae eax, dword [ebp + 0x10]
push eax
lea eax, [ebp - 0x58]
push 0x42884c
push eax
call fcn.00405e80
add esp, 0xc
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x2a8]
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
push ecx
cmovae eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x2b0], eax
cmp eax, 0xffffffff
jne 0x406981
xor bl, bl
jmp 0x406b10
mov ebx, dword [sym.imp.MSVCR120.dll__wcsicmp]
jmp 0x406990
lea eax, [ebp - 0x27c]
push 0x42885c
push eax
call ebx
add esp, 8
test eax, eax
je 0x406ae7
lea eax, [ebp - 0x27c]
push 0x428860
push eax
call ebx
add esp, 8
test eax, eax
je 0x406ae7
cmp dword [ebp + 0x24], 8
lea ecx, [ebp - 0x27c]
push ecx
lea eax, [ebp + 0x10]
cmovae eax, dword [ebp + 0x10]
push 0x428820
push eax
lea eax, [ebp - 0x40]
push str._s_s_s
push eax
call fcn.00405e80
mov ebx, eax
add esp, 0x14
lea eax, [ebp - 0x28]
cmp eax, ebx
je 0x406a1f
cmp dword [ebp - 0x14], 8
jb 0x406a02
push dword [ebp - 0x28]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x14], 7
push ebx
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
call fcn.00402950
cmp dword [ebp - 0x2c], 8
jb 0x406a2d
push dword [ebp - 0x40]
call esi
add esp, 4
test byte [ebp - 0x2a8], 0x10
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x40]
je 0x406aa2
cmp dword [ebp - 0x14], 8
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.00401ad0
mov ebx, dword [ebp - 0x2b4]
lea eax, [ebp - 0x40]
push eax
mov ecx, ebx
mov byte [ebp - 4], 4
call fcn.00404cc0
mov byte [ebp - 4], 3
cmp dword [ebp - 0x2c], 8
jb 0x406a71
push dword [ebp - 0x40]
call esi
add esp, 4
cmp byte [ebp + 0xc], 0
je 0x406ae1
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
sub esp, 0x18
mov ecx, esp
push eax
call fcn.00401ad0
mov ecx, dword [ebp - 0x2ac]
mov edx, ebx
push 1
push edi
call fcn.00406850
add esp, 0x20
jmp 0x406ae1
cmp dword [ebp - 0x14], 8
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.00401ad0
mov ecx, dword [ebp - 0x2ac]
lea eax, [ebp - 0x40]
push eax
mov byte [ebp - 4], 5
call fcn.00404cc0
mov byte [ebp - 4], 3
cmp dword [ebp - 0x2c], 8
jb 0x406ad5
push dword [ebp - 0x40]
call esi
add esp, 4
mov eax, dword [ebp - 0x288]
add dword [edi], eax
adc dword [edi + 4], 0
mov ebx, dword [sym.imp.MSVCR120.dll__wcsicmp]
lea eax, [ebp - 0x2a8]
push eax
push dword [ebp - 0x2b0]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x406990
push dword [ebp - 0x2b0]
call dword [sym.imp.KERNEL32.dll_FindClose]
mov bl, 1
cmp dword [ebp - 0x44], 8
jb 0x406b1e
push dword [ebp - 0x58]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x44], 7
cmp dword [ebp - 0x14], 8
mov dword [ebp - 0x48], 0
mov word [ebp - 0x58], ax
jb 0x406b40
push dword [ebp - 0x28]
call esi
add esp, 4
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
cmp dword [ebp + 0x24], 8
jb 0x406b62
push dword [ebp + 0x10]
call esi
add esp, 4
mov al, bl
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.0041d982
mov esp, ebp
pop ebp
ret