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

Disassembly:
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x308
mov rax, qword [0x18021dd90]
xor rax, rsp
mov qword [rsp + 0x2f0], rax
mov rbx, rcx
mov rcx, qword [rsp + 0x358]
mov eax, r8d
mov qword [rsp + 0x80], rcx
mov rcx, qword [rsp + 0x360]
mov dword [rsp + 0x40], eax
mov qword [rsp + 0x88], rcx
mov rcx, qword [rsp + 0x368]
mov rbp, r9
mov qword [rsp + 0x58], rcx
mov ecx, 0x2a
mov qword [rsp + 0x48], r9
mov word [rbx + rax*2], cx
lea ecx, [rax + 1]
xor eax, eax
mov esi, edx
mov edi, r8d
mov word [rbx + rcx*2], ax
call fcn.180127ee0
test eax, eax
jne 0x18012d27f
call fcn.180127e80
test eax, eax
jne 0x18012d27f
call fcn.180127f00
test eax, eax
je 0x18012d2b3
call fcn.18014e4e0
mov rax, qword [0x18023cc70]
test rax, rax
je 0x18012d2b3
mov rcx, qword [rsp + 0x58]
xor r9d, r9d
mov dword [rsp + 0x28], 2
mov qword [rsp + 0x20], rcx
lea edx, [r9 + 1]
mov rcx, rbx
mov r8, rbp
call rax
jmp 0x18012d2bf
mov rdx, rbp
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov qword [rsp + 0x70], rax
cmp rax, 0xffffffffffffffff
jne 0x18012d2d4
mov eax, 1
jmp 0x18012d6f4
movsxd rax, dword [rsp + 0x40]
xor ecx, ecx
mov r9d, esi
sub r9d, eax
lea rdx, [rbp + 0x2c]
mov r8, rbp
dec r9d
add rax, rax
mov word [rbx + rdi*2], cx
mov qword [rsp + 0x78], rcx
mov qword [rsp + 0x90], rdx
mov qword [rsp + 0x60], rax
mov dword [rsp + 0x50], r9d
mov ebp, dword [r8]
xor eax, eax
or r10, 0xffffffffffffffff
mov rdi, rdx
mov rcx, r10
mov r11d, 0x7fff
repne scasw ax, word [rdi]
mov dword [rsp + 0x44], 1
not rcx
dec rcx
mov qword [rsp + 0x68], rcx
lea eax, [rcx + 2]
cmp r9d, eax
jae 0x18012d420
cmp esi, 0x104
jne 0x18012d34f
mov esi, 0x400
jmp 0x18012d368
cmp esi, 0x400
jne 0x18012d35e
mov esi, 0x1000
jmp 0x18012d368
cmp esi, 0x1000
cmove esi, r11d
mov ecx, esi
mov eax, 2
mul rcx
cmovo rax, r10
mov rcx, rax
call fcn.1800f8d24
mov qword [rsp + 0x78], rax
test rax, rax
je 0x18012d6c1
lea rdx, [0x1801a75f0]
mov r8d, 4
mov rcx, rbx
mov rdi, rax
call fcn.1800fb284
test eax, eax
je 0x18012d3c1
lea rdx, [0x1801a75f0]
mov r8d, 4
mov rcx, rdi
call fcn.1800f8dd0
add rdi, 8
mov r8d, dword [rsp + 0x40]
mov rdx, rbx
mov rcx, rdi
call fcn.1800f8dd0
mov r11, qword [rsp + 0x60]
mov r9, qword [rsp + 0x78]
mov r10d, dword [rsp + 0x40]
xor eax, eax
mov word [r11 + rdi], ax
cmp rdi, r9
je 0x18012d3fe
add r10d, 4
add r11, 8
mov qword [rsp + 0x60], r11
mov dword [rsp + 0x40], r10d
mov rdx, qword [rsp + 0x90]
mov r8, qword [rsp + 0x48]
mov rbx, r9
mov r9d, esi
sub r9d, r10d
dec r9d
or r10, 0xffffffffffffffff
mov dword [rsp + 0x50], r9d
test bpl, 0x10
je 0x18012d5e3
cmp word [rdx], 0x2e
jne 0x18012d450
movzx eax, word [r8 + 0x2e]
test ax, ax
je 0x18012d68f
cmp ax, 0x2e
jne 0x18012d450
cmp word [r8 + 0x30], 0
je 0x18012d68f
xor eax, eax
mov rdi, rbx
mov rcx, r10
repne scasw ax, word [rdi]
xor ecx, ecx
nop dword [rax]
movzx eax, word [rdx + rcx]
add rcx, 2
mov word [rdi + rcx - 4], ax
test ax, ax
jne 0x18012d460
mov eax, dword [rsp + 0x350]
test al, 0x10
je 0x18012d5d5
mov rax, qword [rsp + 0x58]
test rax, rax
je 0x18012d49a
mov rdx, rax
mov rcx, rbx
call fcn.18012abb0
test eax, eax
je 0x18012d4dc
mov rdx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x48]
mov r9, qword [rsp + 0x88]
add edx, dword [rsp + 0x40]
mov r8, rbp
mov rcx, rbx
call qword [rsp + 0x80]
mov edi, eax
test eax, eax
je 0x18012d6d8
cmp eax, 2
jne 0x18012d4e5
mov rax, qword [rsp + 0x60]
xor ecx, ecx
mov word [rax + rbx], cx
jmp 0x18012d698
mov edi, dword [rsp + 0x44]
mov rbp, qword [rsp + 0x48]
mov eax, dword [rsp + 0x350]
test al, 0x40
jne 0x18012d578
mov rcx, qword [rsp + 0x68]
mov edx, 0x5c
mov r8d, 0x24c
add ecx, dword [rsp + 0x40]
lea edi, [rcx + 1]
mov word [rbx + rcx*2], dx
xor ecx, ecx
mov word [rbx + rdi*2], cx
mov dword [rsp + 0xa0], ecx
lea rcx, [rsp + 0xa4]
xor edx, edx
call fcn.1800f8b90
mov rax, qword [rsp + 0x58]
lea r9, [rsp + 0xa0]
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x88]
mov r8d, edi
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x80]
mov edx, esi
mov qword [rsp + 0x28], rax
mov eax, dword [rsp + 0x350]
mov rcx, rbx
mov dword [rsp + 0x20], eax
call fcn.18012d1f0
mov edi, eax
mov eax, dword [rsp + 0x350]
test edi, edi
je 0x18012d6d8
test al, 0x20
je 0x18012d5bd
mov rax, qword [rsp + 0x58]
test rax, rax
je 0x18012d59d
mov rdx, rax
mov rcx, rbx
call fcn.18012abb0
test eax, eax
je 0x18012d5bd
mov rdx, qword [rsp + 0x68]
mov r9, qword [rsp + 0x88]
mov r8, rbp
add edx, dword [rsp + 0x40]
mov rcx, rbx
call qword [rsp + 0x80]
mov edi, eax
test edi, edi
je 0x18012d6d8
mov rax, qword [rsp + 0x60]
xor ecx, ecx
mov word [rax + rbx], cx
jmp 0x18012d698
mov edi, dword [rsp + 0x44]
mov rbp, qword [rsp + 0x48]
jmp 0x18012d4ec
test byte [rsp + 0x350], 0x80
jne 0x18012d68f
xor eax, eax
mov rdi, rbx
mov rcx, r10
repne scasw ax, word [rdi]
xor ecx, ecx
nop
movzx eax, word [rdx + rcx]
add rcx, 2
mov word [rdi + rcx - 4], ax
test ax, ax
jne 0x18012d600
mov rdi, qword [rsp + 0x58]
test rdi, rdi
je 0x18012d643
mov dx, 0x5c
mov rcx, rdi
call fcn.1800f9624
mov rcx, qword [rsp + 0x90]
mov rdx, rdi
test rax, rax
cmovne rcx, rbx
call fcn.18012abb0
test eax, eax
je 0x18012d679
mov rdx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x48]
mov r9, qword [rsp + 0x88]
add edx, dword [rsp + 0x40]
mov r8, rbp
mov rcx, rbx
call qword [rsp + 0x80]
mov edi, eax
test eax, eax
je 0x18012d6d8
mov rax, qword [rsp + 0x60]
xor ecx, ecx
mov word [rax + rbx], cx
jmp 0x18012d698
mov rax, qword [rsp + 0x60]
mov edi, dword [rsp + 0x44]
mov rbp, qword [rsp + 0x48]
xor ecx, ecx
mov word [rax + rbx], cx
jmp 0x18012d698
mov edi, dword [rsp + 0x44]
mov rbp, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x70]
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
je 0x18012d6d8
mov rdx, qword [rsp + 0x90]
mov r8, qword [rsp + 0x48]
mov r9d, dword [rsp + 0x50]
jmp 0x18012d309
mov ecx, 8
mov edi, eax
mov dword [0x18023c14c], 8
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x18012d6f2
call fcn.1800f8dc8
mov eax, edi
mov rcx, qword [rsp + 0x2f0]
xor rcx, rsp
call fcn.1800f98f0
add rsp, 0x308
pop rdi
pop rsi
pop rbp
pop rbx
ret