Function at 0x10029b9
Capabilities:
Check if file exists
Enumerate files on windows
Enumerate files recursively
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x26c
mov eax, dword [0x1005008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push edi
mov edi, dword [ebp + 8]
push eax
mov dword [ebp - 0x258], edi
mov dword [ebp - 0x260], eax
call esi
push edi
test eax, eax
jne 0x1002afe
xor ebx, ebx
mov dword [ebp - 0x268], ebx
call fcn.0100185c
mov esi, eax
mov dword [ebp - 0x260], esi
cmp esi, 0xffffffff
jne 0x1002a46
cmp byte [0x1005023], bl
je 0x1002a1f
cmp byte [0x1005021], bl
jne 0x1002a2e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
call fcn.010014b1
pop ecx
pop ecx
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
cmp byte [0x1005021], bl
setne al
jmp 0x1002de7
push edi
push 0xd
call fcn.01001417
pop ecx
pop ecx
push ebx
lea eax, [ebp - 0x26c]
push eax
push ebx
push ebx
push 2
lea eax, [ebp - 0x268]
push eax
push 0x9c040
push esi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x1002ac8
cmp byte [0x1005023], bl
je 0x1002a83
cmp byte [0x1005021], bl
jne 0x1002a8b
push 2
call fcn.01001417
pop ecx
cmp byte [0x1005023], bl
jne 0x1002abd
cmp byte [0x1005021], bl
jne 0x1002abd
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 1
jne 0x1002ab2
push edi
push 0x1a
call fcn.01001417
jmp 0x1002abb
call esi
push eax
push edi
call fcn.010014b1
pop ecx
pop ecx
push dword [ebp - 0x260]
jmp 0x1002a30
cmp byte [0x1005023], bl
jne 0x1002ad8
push 1
call fcn.01001417
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
add dword [0x1005588], 1
adc dword [0x100558c], ebx
add dword [0x1005db0], 1
adc dword [0x1005db4], ebx
jmp 0x1002de5
call esi
lea ebx, [edi + eax*2]
push edi
mov dword [ebp - 0x264], ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1002b31
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
call fcn.010014b1
pop ecx
xor eax, eax
cmp byte [0x1005021], al
pop ecx
jmp 0x1002a3e
push edi
test eax, 0x800
je 0x1002b3d
push 0xe
jmp 0x1002b3f
push 0xf
call fcn.01001417
add dword [0x1005588], 1
pop ecx
pop ecx
adc dword [0x100558c], 0
push dword [ebp - 0x260]
sub ebx, edi
sar ebx, 1
mov dword [ebp - 0x26c], ebx
call esi
add eax, ebx
mov edi, 0x104
cmp eax, edi
jge 0x1002cc1
push dword [ebp - 0x260]
push dword [ebp - 0x258]
call esi
mov ecx, edi
sub ecx, eax
push ecx
push dword [ebp - 0x264]
call sub.msvcrt.dll_wcscpy_s
add esp, 0xc
lea eax, [ebp - 0x254]
push eax
push dword [ebp - 0x258]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x25c], eax
cmp eax, 0xffffffff
je 0x1002cc1
push 0x100115c
lea eax, [ebp - 0x228]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x1002c9a
push 0x10011d8
lea eax, [ebp - 0x228]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x1002c9a
lea eax, [ebp - 0x228]
push eax
call esi
add eax, ebx
cmp eax, edi
jge 0x1002c9a
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x258]
call esi
mov ecx, edi
sub ecx, eax
push ecx
push dword [ebp - 0x264]
call sub.msvcrt.dll_wcscpy_s
add esp, 0xc
push dword [ebp - 0x258]
call fcn.0100185c
mov dword [ebp - 0x268], eax
cmp eax, 0xffffffff
jne 0x1002c79
cmp byte [0x1005023], 0
je 0x1002c49
cmp byte [0x1005021], 0
jne 0x1002c9a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp - 0x258]
call fcn.010014b1
cmp byte [0x1005021], 0
pop ecx
pop ecx
jne 0x1002c9a
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindClose]
xor al, al
jmp 0x1002de7
lea ecx, [ebp - 0x254]
push ecx
push eax
call fcn.01002894
push dword [ebp - 0x268]
test al, al
je 0x1002df8
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x254]
push eax
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x1002bb8
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp byte [0x1005020], 0
je 0x1002de5
push 0x10011d4
call esi
add eax, ebx
cmp eax, edi
jge 0x1002de5
push 0x10011d4
push dword [ebp - 0x258]
call esi
mov ecx, edi
sub ecx, eax
push ecx
push dword [ebp - 0x264]
call sub.msvcrt.dll_wcscpy_s
add esp, 0xc
lea eax, [ebp - 0x254]
push eax
push dword [ebp - 0x258]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x25c], eax
cmp eax, 0xffffffff
je 0x1002de5
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpW]
push 0x100115c
lea eax, [ebp - 0x228]
push eax
call ebx
test eax, eax
je 0x1002dbe
push 0x10011d8
lea eax, [ebp - 0x228]
push eax
call ebx
test eax, eax
je 0x1002dbe
test byte [ebp - 0x254], 0x10
je 0x1002dbe
push 0x10011d0
call esi
mov ebx, eax
lea eax, [ebp - 0x228]
push eax
call esi
add ebx, dword [ebp - 0x26c]
add eax, ebx
cmp eax, edi
jge 0x1002dbe
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x258]
call esi
mov ecx, edi
sub ecx, eax
push ecx
push dword [ebp - 0x264]
call sub.msvcrt.dll_wcscpy_s
push 0x10011d0
push edi
push dword [ebp - 0x258]
call sub.msvcrt.dll_wcscat_s
add esp, 0x18
push dword [ebp - 0x260]
push dword [ebp - 0x258]
call fcn.010029b9
test al, al
je 0x1002dfe
lea eax, [ebp - 0x254]
push eax
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x1002d21
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindClose]
mov al, 1
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.010036a9
leave
ret 8
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x25c]
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
cmp byte [0x1005021], al
jmp 0x1002a3e