Function at 0x40527e
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, 0x488
mov eax, dword [0x42d0b4]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, ecx
mov dword [ebp - 0x47c], eax
push esi
mov esi, ebx
xor ecx, ecx
push edi
mov dword [ebp - 0x478], ecx
lea edi, [esi + 2]
mov ax, word [esi]
add esi, 2
cmp ax, cx
jne 0x4052ae
sub esi, edi
sar esi, 1
lea eax, [esi + 2]
cmp eax, edx
ja 0x405317
mov ecx, ebx
xor edi, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x4052cb
mov esi, dword [ebp - 0x47c]
sub ecx, edx
sar ecx, 1
push ebx
lea eax, [ecx - 2]
mov dword [ebp - 0x488], eax
mov dword [esi], eax
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x41920d
test al, 0x10
jne 0x419225
xor eax, eax
inc eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00416ad0
leave
ret 4
xor eax, eax
jmp 0x405306
push edi
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
push eax
jmp 0x419219
push edi
push esi
call fcn.00407834
pop ecx
pop ecx
jmp 0x405317
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x41922a
sub ecx, edx
sar ecx, 1
push 0x5c
pop eax
push 0x2a
cmp word [ebx + ecx*2 - 2], ax
jne 0x41924a
mov edx, edi
pop eax
jmp 0x419252
xor edx, edx
mov word [ebx + ecx*2 + 4], dx
pop edx
mov word [ebx + ecx*2], ax
lea eax, [ebp - 0x474]
push eax
push ebx
mov word [ebx + ecx*2 + 2], dx
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_FindFirstFileW]
mov dword [ebp - 0x480], eax
cmp eax, 0xffffffff
jne 0x41929b
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
push 0xffffffffffffffff
mov esi, eax
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_FindClose]
cmp esi, 2
je 0x405303
cmp esi, 0x12
je 0x405303
jmp 0x419217
xor edi, edi
inc edi
mov ecx, 0x402424
lea eax, [ebp - 0x448]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4192cf
test dx, dx
je 0x4192cb
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4192cf
add eax, 4
add ecx, 4
test dx, dx
jne 0x4192a9
xor eax, eax
jmp 0x4192d4
sbb eax, eax
or eax, 1
test eax, eax
je 0x419442
mov ecx, 0x402500
lea eax, [ebp - 0x448]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x41930d
test dx, dx
je 0x419309
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x41930d
add eax, 4
add ecx, 4
test dx, dx
jne 0x4192e7
xor eax, eax
jmp 0x419312
sbb eax, eax
or eax, 1
test eax, eax
je 0x419442
lea ecx, [ebp - 0x448]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0x478]
jne 0x419323
sub ecx, edx
sar ecx, 1
je 0x419442
test byte [ebp - 0x474], 0x10
jne 0x419438
mov eax, 0x104
mov byte [ebp - 0x18], 1
push eax
xor esi, esi
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x224]
mov dword [ebp - 0x1c], esi
push esi
push eax
call sub.msvcrt.dll_memset
xor eax, eax
lea ecx, [ebp - 0x224]
add esp, 0xc
cmp byte [ebp - 0x18], al
sete al
dec eax
and eax, 0x7ee3
add eax, 0x104
push eax
call fcn.0040e330
test eax, eax
js 0x419477
push ebx
lea ecx, [ebp - 0x224]
call fcn.0040a586
mov edx, dword [ebp - 0x1c]
mov ecx, edx
test edx, edx
jne 0x4193ad
lea ecx, [ebp - 0x224]
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0x478]
jne 0x4193b0
sub ecx, esi
sar ecx, 1
test edx, edx
jne 0x4193cd
lea edx, [ebp - 0x224]
xor eax, eax
mov word [edx + ecx*2 - 2], ax
lea eax, [ebp - 0x448]
push eax
lea ecx, [ebp - 0x224]
call fcn.004122ac
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
jne 0x4193f3
lea ecx, [ebp - 0x224]
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x484]
push eax
call fcn.0040527e
test eax, eax
je 0x419461
mov esi, dword [ebp - 0x47c]
mov ecx, dword [ebp - 0x488]
add ecx, dword [ebp - 0x484]
mov eax, dword [esi]
cmp eax, ecx
jg 0x419420
mov eax, ecx
mov dword [esi], eax
xor ecx, ecx
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x1c], ecx
test eax, eax
je 0x419442
push eax
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
jmp 0x419442
mov eax, dword [esi]
cmp eax, ecx
jg 0x419440
mov eax, ecx
mov dword [esi], eax
lea eax, [ebp - 0x474]
push eax
push dword [ebp - 0x480]
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_FindNextFileW]
mov edi, eax
test edi, edi
jne 0x41929e
jmp 0x419491
mov eax, dword [ebp - 0x1c]
xor ebx, ebx
mov dword [ebp - 0x1c], ebx
test eax, eax
je 0x419493
push eax
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
jmp 0x419493
push 8
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_SetLastError]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x1c], esi
test eax, eax
je 0x419491
push eax
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
xor ebx, ebx
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
push dword [ebp - 0x480]
mov esi, eax
call dword [sym.imp.api_ms_win_core_file_l1_1_0.dll_FindClose]
test edi, edi
jne 0x405317
cmp esi, 0x12
je 0x405303
push ebx
jmp 0x419218