Function at 0x140049e80
Capabilities:
Enumerate files on windows

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5b8]
sub rsp, 0x680
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov qword [rax + 0x20], rbx
mov rax, qword [0x14007edf8]
xor rax, rsp
mov qword [rbp + 0x570], rax
mov r15, r8
mov rdi, rdx
mov rsi, rcx
cmp qword [rdx + 0x18], 8
jb 0x140049ecf
mov rcx, qword [rdx]
jmp 0x140049ed2
mov rcx, rdx
lea r8, [rsp + 0x48]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
xor r12d, r12d
test eax, eax
je 0x14004a1fa
cmp dword [rsp + 0x48], 0xffffffff
je 0x14004a1fa
test byte [rsp + 0x48], 0x10
je 0x14004a1fa
mov r14, qword [rsi + 8]
mov rbx, qword [rsi]
lea r13d, [r12 + 1]
jmp 0x140049f20
xor r8d, r8d
mov dl, r13b
mov rcx, rbx
call fcn.140004d54
add rbx, 0x20
cmp rbx, r14
jne 0x140049f0e
mov rax, qword [rsi]
mov qword [rsi + 8], rax
mov ebx, 7
mov qword [rbp - 0x78], rbx
mov qword [rbp - 0x80], r12
mov word [rsp + 0x70], r12w
lea rax, [rsp + 0x70]
or r14, 0xffffffffffffffff
cmp rax, rdi
je 0x140049f60
mov r9, r14
xor r8d, r8d
mov rdx, rdi
lea rcx, [rsp + 0x70]
call fcn.140005154
mov qword [rsp + 0x40], rbx
mov qword [rsp + 0x38], r12
mov word [rsp + 0x28], r12w
mov r8, r13
lea rdx, [0x140077c54]
lea rcx, [rsp + 0x28]
call fcn.14000528c
nop
mov r8b, r13b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.140003ebc
test al, al
sete bl
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x28]
call fcn.140004d54
test bl, bl
je 0x140049ffd
mov qword [rsp + 0x40], 7
mov qword [rsp + 0x38], r12
mov word [rsp + 0x28], r12w
mov r8, r13
lea rdx, [0x140077c54]
lea rcx, [rsp + 0x28]
call fcn.14000528c
nop
mov r9, r14
xor r8d, r8d
lea rdx, [rsp + 0x28]
lea rcx, [rsp + 0x70]
call fcn.140004dc4
nop
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x28]
call fcn.140004d54
mov r9, r14
xor r8d, r8d
mov rdx, r15
lea rcx, [rsp + 0x70]
call fcn.140004dc4
lea rcx, [rsp + 0x70]
cmp qword [rbp - 0x78], 8
cmovae rcx, qword [rsp + 0x70]
lea rdx, [rbp - 0x70]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov r14, rax
or r15, 0xffffffffffffffff
cmp rax, r15
jne 0x14004a087
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [rax - 2]
cmp ecx, r13d
jbe 0x14004a072
lea r9, str.directory_search_failed
mov r8d, eax
lea edx, [r15 + 0x10]
lea rcx, [rbp + 0x1e0]
call fcn.140036938
lea rdx, [0x14008f3c8]
lea rcx, [rbp + 0x1e0]
call sub.VCRUNTIME140.dll__CxxThrowException
nop
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x70]
call fcn.140004d54
jmp 0x14004a229
lea rdx, [0x14007b538]
lea rcx, [rbp - 0x44]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x14004a1d7
lea rdx, [0x140082030]
lea rcx, [rbp - 0x44]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x14004a1d7
test byte [rbp - 0x70], 0x10
je 0x14004a1d7
mov qword [rsp + 0x40], 7
mov qword [rsp + 0x38], r12
mov word [rsp + 0x28], r12w
mov r9, r15
xor r8d, r8d
mov rdx, rdi
lea rcx, [rsp + 0x28]
call fcn.140005154
nop
mov qword [rsp + 0x60], 7
mov qword [rsp + 0x58], r12
mov word [rsp + 0x48], r12w
mov r8, r13
lea rdx, [0x140077c54]
lea rcx, [rsp + 0x48]
call fcn.14000528c
nop
mov r8b, r13b
lea rdx, [rsp + 0x48]
lea rcx, [rsp + 0x28]
call fcn.140003ebc
test al, al
sete bl
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x48]
call fcn.140004d54
test bl, bl
je 0x14004a18e
mov qword [rsp + 0x60], 7
mov qword [rsp + 0x58], r12
mov word [rsp + 0x48], r12w
mov r8, r13
lea rdx, [0x140077c54]
lea rcx, [rsp + 0x48]
call fcn.14000528c
nop
mov r9, r15
xor r8d, r8d
lea rdx, [rsp + 0x48]
lea rcx, [rsp + 0x28]
call fcn.140004dc4
nop
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x48]
call fcn.140004d54
cmp word [rbp - 0x44], r12w
jne 0x14004a19a
mov r8, r12
jmp 0x14004a1ab
lea rax, [rbp - 0x44]
mov r8, r15
inc r8
cmp word [rax + r8*2], r12w
jne 0x14004a1a1
lea rdx, [rbp - 0x44]
lea rcx, [rsp + 0x28]
call fcn.140004eec
lea rdx, [rsp + 0x28]
mov rcx, rsi
call fcn.1400390f0
nop
xor r8d, r8d
mov dl, r13b
lea rcx, [rsp + 0x28]
call fcn.140004d54
lea rdx, [rbp - 0x70]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x14004a087
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x14004a072
mov r9, rdi
lea r8, str.GetDirectories:_search_path__s_does_not_exist
mov edx, 0x22
lea rcx, [rbp + 0x1e0]
call fcn.14004939c
lea rdx, [0x14008f3c8]
lea rcx, [rbp + 0x1e0]
call sub.VCRUNTIME140.dll__CxxThrowException
int3
mov rcx, qword [rbp + 0x570]
xor rcx, rsp
call fcn.14003a6d0
mov rbx, qword [rsp + 0x6d8]
add rsp, 0x680
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret