Function at 0x140165af0
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
mov dword [rsp + 0x18], r8d
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rsi
push rdi
sub rsp, 0x638
mov rax, qword [0x1402da2b0]
xor rax, rsp
mov qword [rsp + 0x620], rax
mov qword [rsp + 0x28], 0
lea rax, [rsp + 0xa0]
mov rdi, rax
xor eax, eax
mov ecx, 0x140
rep stosb byte [rdi], al
cmp dword [rsp + 0x660], 0
je 0x140165db0
lea r9, [rsp + 0x90]
lea r8, [rsp + 0x2f0]
mov edx, 0x104
mov rcx, qword [rsp + 0x650]
call qword [sym.imp.KERNEL32.dll_GetFullPathNameA]
test eax, eax
jne 0x140165b73
xor eax, eax
jmp 0x140165ec1
mov rax, qword [rsp + 0x90]
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x400]
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x78], rax
mov rax, qword [rsp + 0x58]
movzx eax, byte [rax]
mov byte [rsp + 0x20], al
mov rax, qword [rsp + 0x40]
movzx ecx, byte [rsp + 0x20]
mov byte [rax], cl
mov rax, qword [rsp + 0x58]
inc rax
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x40]
inc rax
mov qword [rsp + 0x40], rax
cmp byte [rsp + 0x20], 0
jne 0x140165b97
mov rax, qword [rsp + 0x90]
mov ecx, dword [0x1402a5144]
mov dword [rax], ecx
mov dword [rsp + 0xa0], reloc.WS2_32.dll_recv
lea rdx, [rsp + 0xa0]
lea rcx, [rsp + 0x2f0]
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0xffffffffffffffff
je 0x140165da5
mov r8d, 1
lea rdx, [0x1402a5134]
lea rcx, [rsp + 0xcc]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncmp]
test eax, eax
je 0x140165c50
mov r8d, 2
lea rdx, [0x1402a5174]
lea rcx, [rsp + 0xcc]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncmp]
test eax, eax
jne 0x140165c55
jmp 0x140165d8a
mov eax, dword [rsp + 0xa0]
and eax, 0x10
test eax, eax
je 0x140165d8a
lea r9, [rsp + 0x90]
lea r8, [rsp + 0x1e0]
mov edx, 0x104
mov rcx, qword [rsp + 0x650]
call qword [sym.imp.KERNEL32.dll_GetFullPathNameA]
test eax, eax
jne 0x140165c95
xor eax, eax
jmp 0x140165ec1
lea rax, [rsp + 0xcc]
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0x90]
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x80], rax
mov rax, qword [rsp + 0x60]
movzx eax, byte [rax]
mov byte [rsp + 0x21], al
mov rax, qword [rsp + 0x48]
movzx ecx, byte [rsp + 0x21]
mov byte [rax], cl
mov rax, qword [rsp + 0x60]
inc rax
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0x48]
inc rax
mov qword [rsp + 0x48], rax
cmp byte [rsp + 0x21], 0
jne 0x140165cbc
lea rax, [rsp + 0x1e0]
mov qword [rsp + 0x30], rax
dec qword [rsp + 0x30]
inc qword [rsp + 0x30]
mov rax, qword [rsp + 0x30]
cmp byte [rax], 0
jne 0x140165d07
mov rax, qword [rsp + 0x30]
lea rcx, [0x1402a515c]
mov rdi, rax
mov rsi, rcx
mov ecx, 2
rep movsb byte [rdi], byte [rsi]
lea rax, [rsp + 0x1e0]
mov qword [rsp + 0x38], rax
dec qword [rsp + 0x38]
inc qword [rsp + 0x38]
mov rax, qword [rsp + 0x38]
cmp byte [rax], 0
jne 0x140165d41
mov rax, qword [rsp + 0x38]
lea rcx, [rsp + 0x400]
xor edx, edx
movzx edi, byte [rcx + rdx]
mov byte [rax + rdx], dil
inc rdx
test dil, dil
jne 0x140165d5f
mov r8d, 1
mov rdx, qword [rsp + 0x658]
lea rcx, [rsp + 0x1e0]
call fcn.140165af0
lea rdx, [rsp + 0xa0]
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x140165c12
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_FindClose]
lea rdx, [rsp + 0xa0]
mov rcx, qword [rsp + 0x650]
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0xffffffffffffffff
jne 0x140165ddd
mov eax, 1
jmp 0x140165ec1
mov eax, dword [rsp + 0xa0]
and eax, 0x10
test eax, eax
jne 0x140165e96
lea r9, [rsp + 0x90]
lea r8, [rsp + 0x510]
mov edx, 0x104
mov rcx, qword [rsp + 0x650]
call qword [sym.imp.KERNEL32.dll_GetFullPathNameA]
test eax, eax
jne 0x140165e1d
xor eax, eax
jmp 0x140165ec1
lea rax, [rsp + 0xcc]
mov qword [rsp + 0x68], rax
mov rax, qword [rsp + 0x90]
mov qword [rsp + 0x50], rax
mov rax, qword [rsp + 0x50]
mov qword [rsp + 0x88], rax
mov rax, qword [rsp + 0x68]
movzx eax, byte [rax]
mov byte [rsp + 0x22], al
mov rax, qword [rsp + 0x50]
movzx ecx, byte [rsp + 0x22]
mov byte [rax], cl
mov rax, qword [rsp + 0x68]
inc rax
mov qword [rsp + 0x68], rax
mov rax, qword [rsp + 0x50]
inc rax
mov qword [rsp + 0x50], rax
cmp byte [rsp + 0x22], 0
jne 0x140165e44
mov rax, qword [rsp + 0x658]
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0xcc]
call qword [rsp + reloc.WS2_32.dll_WSASetLastError]
lea rdx, [rsp + 0xa0]
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x140165ddd
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_FindClose]
mov eax, 1
mov rcx, qword [rsp + 0x620]
xor rcx, rsp
call fcn.140217b10
add rsp, 0x638
pop rdi
pop rsi
ret