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

Disassembly:
push rbx
push rbp
push rsi
push r12
push r13
push r14
push r15
sub rsp, 0x1a0
mov rax, qword [0x140028008]
xor rax, rsp
mov qword [rsp + 0x180], rax
mov rsi, 0xffffffffffffffff
mov qword [rsp + 0x20], r9
mov rbp, rsi
mov qword [rsp + 0x30], rcx
mov r12, r8
mov r15, rdx
mov r14, rcx
xor r13d, r13d
inc rbp
cmp byte [rcx + rbp], r13b
jne 0x140017ce5
mov rcx, rbp
add rcx, 3
cmovb rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rbx, rax
test rax, rax
je 0x140017f3c
mov r8, rbp
mov qword [rsp + 0x198], rdi
mov rdx, r14
mov rcx, rbx
call sub.VCRUNTIME140.dll_memcpy
lea rdx, [rsp + 0x40]
mov word [rbx + rbp], 0x2a5c
mov rcx, rbx
mov byte [rbx + rbp + 2], r13b
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov qword [rsp + 0x28], rax
mov rdi, rax
cmp rax, rsi
jne 0x140017d69
mov ecx, 2
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov r8, r14
lea rdx, str.Cannot_open_directory__s_n
mov rcx, rax
call fcn.140015200
jmp 0x140017f32
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
nop dword [rax]
nop word [rax + rax]
lea rcx, [rsp + 0x6c]
mov rax, rsi
nop dword [rax + rax]
inc rax
cmp byte [rcx + rax], 0
jne 0x140017d90
movsxd rbx, eax
lea rcx, [rbx + rbp]
add rcx, 2
cmovb rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rsi, rax
test rax, rax
je 0x140017f29
mov r8, rbp
mov rdx, r14
mov rcx, rax
call sub.VCRUNTIME140.dll_memcpy
lea rcx, [rbp + 1]
mov byte [rsi + rbp], 0x5c
add rcx, rsi
lea rdx, [rsp + 0x6c]
mov r8, rbx
call sub.VCRUNTIME140.dll_memcpy
lea r14, [rbp + 1]
add r14, rbx
mov byte [r14 + rsi], 0
mov eax, dword [rsp + 0x40]
test al, 0x10
je 0x140017e5b
movzx edx, byte [rsp + 0x6c]
cmp dl, byte [0x140023404]
movzx ecx, byte [rsp + 0x6d]
jne 0x140017e1f
cmp cl, byte [0x140023405]
jne 0x140017e1f
movzx eax, byte [rsp + 0x6e]
cmp al, byte [0x140023406]
je 0x140017ef8
cmp dl, byte [0x140023408]
jne 0x140017e33
cmp cl, byte [0x140023409]
je 0x140017ef8
mov r9, qword [rsp + 0x20]
mov r8, r12
mov rdx, r15
mov rcx, rsi
call fcn.140017ca0
movsxd rcx, eax
add r13, rcx
cmp qword [r15], 0
je 0x140017f20
jmp 0x140017eef
test eax, 0x8a0
je 0x140017eef
mov rax, qword [rsp + 0x20]
mov rdi, qword [r15]
mov rbx, qword [rax]
mov rax, qword [r12]
add rax, rdi
add rax, r14
cmp rax, rbx
jb 0x140017ebc
sub rbx, rdi
mov rcx, rdi
add rbx, 0x2000
mov rdx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
test rax, rax
jne 0x140017ea6
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor eax, eax
mov qword [r15], rax
add rbx, rax
mov rax, qword [rsp + 0x20]
mov qword [rax], rbx
mov rdi, qword [r15]
test rdi, rdi
je 0x140017f1b
mov rdx, qword [r12]
lea rcx, [rdx + rdi]
lea rax, [rcx + r14]
cmp rax, rbx
jae 0x140017eea
sub rbx, rdx
mov rdx, rsi
sub rbx, rdi
mov r8, rbx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
lea rax, [r14 + 1]
add qword [r12], rax
inc r13
mov rdi, qword [rsp + 0x28]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rdx, [rsp + 0x40]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x140017f5f
mov r14, qword [rsp + 0x30]
mov rsi, 0xffffffffffffffff
jmp 0x140017d80
mov rdi, qword [rsp + 0x28]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
mov rdi, qword [rsp + 0x198]
mov rcx, qword [rsp + 0x180]
xor rcx, rsp
call fcn.140020560
add rsp, 0x1a0
pop r15
pop r14
pop r13
pop r12
pop rsi
pop rbp
pop rbx
ret
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindClose]
cmp r13, 0x7fffffff
jb 0x140017f8b
mov r8d, 0x223
lea rdx, str.c:_b_abs_fcz738m_9xcrootlz4_c_1670944697368workprogramsutil.h
lea rcx, str.nbFiles___INT_MAX
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__wassert]
mov eax, r13d
jmp 0x140017f34