Function at 0x140020d20
Capabilities:
Enumerate files on windows
Get common file path

Disassembly:
mov r11, rsp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x650
mov qword [rsp + 0x98], 0xfffffffffffffffe
mov qword [r11 + 0x18], rbx
mov rax, qword [0x1400d2478]
xor rax, rsp
mov qword [rsp + 0x640], rax
mov r13, rdx
mov r12, rcx
mov qword [r11 - 0x5b8], 7
xor r14d, r14d
mov qword [r11 - 0x5c0], r14
mov word [r11 - 0x5d0], r14w
lea r8d, [r14 + 0x1a]
lea rdx, str.IMInstaller::IM_RemoveInfs
lea rcx, [r11 - 0x5d8]
call fcn.140001870
nop
lea r9, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae r9, qword [rsp + 0xa8]
lea rax, str.Function_start
mov qword [rsp + 0x20], rax
mov r15d, 1
mov r8d, r15d
lea edx, [r14 + 0x32]
mov rcx, r12
call fcn.1400144a0
mov qword [rsp + 0xe8], 7
mov qword [rsp + 0xe0], r14
mov word [rsp + 0xd0], r14w
xor dil, dil
mov edx, 0x104
lea rcx, [rsp + 0x430]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
movzx ebx, dil
test eax, eax
cmovne ebx, r15d
lea rax, [0x1400ad318]
lea rdx, [rsp + 0x430]
test bl, bl
cmove rdx, rax
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
lea rcx, [rsp + 0xc8]
call fcn.140001870
test bl, bl
je 0x14002173d
mov qword [rsp + 0x110], 7
mov qword [rsp + 0x108], r14
mov word [rsp + 0xf8], r14w
mov qword [rsp + 0x1b0], 7
mov qword [rsp + 0x1a8], r14
mov word [rsp + 0x198], r14w
mov qword [rsp + 0x188], 7
mov qword [rsp + 0x180], r14
mov word [rsp + 0x170], r14w
mov rbx, qword [rsp + 0xe0]
test rbx, rbx
je 0x140020f6d
test rbx, rbx
je 0x140020f56
cmp rbx, 0xffffffffffffffff
jbe 0x140020ec2
or rcx, 0xffffffffffffffff
jmp 0x140020ec6
lea rcx, [rbx - 1]
lea rax, [rsp + 0xd0]
cmp qword [rsp + 0xe8], 8
cmovae rax, qword [rsp + 0xd0]
lea rdi, [rax + rcx*2]
nop word [rax + rax]
mov rcx, r15
lea rax, [0x1400ad338]
movzx edx, word [rdi]
nop dword [rax]
cmp word [rax], dx
je 0x140020f27
add rax, 2
sub rcx, 1
jne 0x140020f00
lea rcx, [rsp + 0xc8]
call fcn.1400016d0
cmp rdi, rax
je 0x140020f56
sub rdi, 2
jmp 0x140020ef0
lea rax, [rsp + 0xd0]
cmp qword [rsp + 0xe8], 8
cmovae rax, qword [rsp + 0xd0]
sub rdi, rax
sar rdi, 1
cmp rdi, 0xffffffffffffffff
je 0x140020f56
lea rax, [rdi + 1]
cmp rbx, rax
je 0x140020f6d
mov r8, r15
lea rdx, [0x1400ad338]
lea rcx, [rsp + 0xc8]
call fcn.14000a130
mov r8d, 4
lea rdx, str.inf_
lea rcx, [rsp + 0xc8]
call fcn.14000a130
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0xc8]
lea rcx, [rsp + 0x190]
call fcn.140001500
mov r8d, 8
lea rdx, str.oem.inf
lea rcx, [rsp + 0x190]
call fcn.14000a130
lea rcx, [rsp + 0x198]
cmp qword [rsp + 0x1b0], 8
cmovae rcx, qword [rsp + 0x198]
lea rdx, [rsp + 0x1e0]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14002115f
mov qword [rsp + 0x160], 7
mov qword [rsp + 0x158], r14
mov word [rsp + 0x148], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0xc8]
lea rcx, [rsp + 0x140]
call fcn.140001500
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x20c]
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
lea rdx, [rsp + 0x20c]
lea rcx, [rsp + 0x140]
call fcn.14000a130
mov dword [rsp + 0x40], r14d
lea rdx, [rsp + 0x148]
cmp qword [rsp + 0x160], 8
cmovae rdx, qword [rsp + 0x148]
lea r9, [rsp + 0x40]
mov r8, r13
mov rcx, r12
call fcn.140022eb0
test eax, eax
je 0x1400210b5
cmp dword [rsp + 0x40], 0
je 0x1400210b5
lea rdx, [rsp + 0x148]
cmp qword [rsp + 0x160], 8
cmovae rdx, qword [rsp + 0x148]
mov rcx, r12
call fcn.140023340
nop
cmp qword [rsp + 0x160], 8
jb 0x1400210cd
mov rcx, qword [rsp + 0x148]
call fcn.140065920
mov qword [rsp + 0x160], 7
mov qword [rsp + 0x158], r14
mov word [rsp + 0x148], r14w
lea rdx, [rsp + 0x1e0]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x140020ff2
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
je 0x140021154
lea r9, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae r9, qword [rsp + 0xa8]
lea rcx, str.FindNextFile
mov qword [rsp + 0x30], rcx
mov dword [rsp + 0x28], eax
lea rax, str.Error___i__return_by_function___s_
mov qword [rsp + 0x20], rax
mov r8d, r15d
mov edx, reloc.Cabinet.dll_FDICreate
mov rcx, r12
call fcn.1400144a0
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x1400211ae
lea rdi, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae rdi, qword [rsp + 0xa8]
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.FindFirstFile
mov qword [rsp + 0x30], rcx
mov dword [rsp + 0x28], eax
lea rax, str.Error___i__return_by_function___s_
mov qword [rsp + 0x20], rax
mov r9, rdi
mov r8d, r15d
mov edx, reloc.Cabinet.dll_FDICreate
mov rcx, r12
call fcn.1400144a0
xor dil, dil
mov edx, 0x104
lea rcx, [rsp + 0x430]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
movzx ebx, dil
test eax, eax
cmovne ebx, r15d
lea rdx, [rsp + 0x430]
test bl, bl
lea rax, [0x1400ad318]
cmove rdx, rax
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
lea rcx, [rsp + 0xf0]
call fcn.140001870
test bl, bl
je 0x140021424
mov rbx, qword [rsp + 0x108]
test rbx, rbx
je 0x1400212dd
test rbx, rbx
je 0x1400212c6
cmp rbx, 0xffffffffffffffff
jbe 0x140021231
or rcx, 0xffffffffffffffff
jmp 0x140021235
lea rcx, [rbx - 1]
lea rax, [rsp + 0xf8]
cmp qword [rsp + 0x110], 8
cmovae rax, qword [rsp + 0xf8]
lea rdi, [rax + rcx*2]
nop word [rax + rax]
mov rcx, r15
lea rax, [0x1400ad338]
movzx edx, word [rdi]
nop dword [rax]
cmp word [rax], dx
je 0x140021297
add rax, 2
sub rcx, 1
jne 0x140021270
lea rcx, [rsp + 0xf0]
call fcn.1400016d0
cmp rdi, rax
je 0x1400212c6
sub rdi, 2
jmp 0x140021260
lea rax, [rsp + 0xf8]
cmp qword [rsp + 0x110], 8
cmovae rax, qword [rsp + 0xf8]
sub rdi, rax
sar rdi, 1
cmp rdi, 0xffffffffffffffff
je 0x1400212c6
lea rax, [rdi + 1]
cmp rbx, rax
je 0x1400212dd
mov r8, r15
lea rdx, [0x1400ad338]
lea rcx, [rsp + 0xf0]
call fcn.14000a130
mov r8d, 8
lea rdx, str.catroot_
lea rcx, [rsp + 0xf0]
call fcn.14000a130
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, r13
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
mov rdx, r13
lea rcx, [rsp + 0x168]
call fcn.140001870
mov r9, r15
xor r8d, r8d
lea rdx, [0x1400ad340]
lea rcx, [rsp + 0x168]
call fcn.1400021c0
cmp rax, 0xffffffffffffffff
je 0x140021373
mov rcx, qword [rsp + 0x180]
cmp rax, rcx
ja 0x14002135d
or r8, 0xffffffffffffffff
mov rdx, rax
lea rcx, [rsp + 0x168]
call fcn.1400019e0
jmp 0x140021373
xor r8d, r8d
sub rax, rcx
mov rdx, rax
lea rcx, [rsp + 0x168]
call fcn.1400022f0
mov r8d, 4
lea rdx, str..cat
lea rcx, [rsp + 0x168]
call fcn.14000a130
lea rdx, [rsp + 0x118]
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x138], 7
mov qword [rsp + 0x130], r14
mov word [rsp + 0x120], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x168]
lea rcx, [rsp + 0x118]
call fcn.140001500
nop
mov qword [rsp + 0x68], 7
mov qword [rsp + 0x60], r14
mov word [rsp + 0x50], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0xf0]
lea rcx, [rsp + 0x48]
call fcn.140001500
nop
mov dword [rsp + 0x28], r14d
mov dword [rsp + 0x20], r14d
lea r9, [rsp + 0x118]
lea r8, [rsp + 0x48]
mov edx, r15d
mov rcx, r12
call fcn.14002cc40
mov qword [rsp + 0x1d8], 7
mov qword [rsp + 0x1d0], r14
mov word [rsp + 0x1c0], r14w
xor dil, dil
mov edx, 0x104
lea rcx, [rsp + 0x430]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
movzx ebx, dil
test eax, eax
cmovne ebx, r15d
lea rdx, [rsp + 0x430]
test bl, bl
lea rax, [0x1400ad318]
cmove rdx, rax
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
lea rcx, [rsp + 0x1b8]
call fcn.140001870
test bl, bl
je 0x140021667
mov qword [rsp + 0x138], 7
mov qword [rsp + 0x130], r14
mov word [rsp + 0x120], r14w
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, r13
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
mov rdx, r13
lea rcx, [rsp + 0x118]
call fcn.140001870
nop
mov r9, r15
xor r8d, r8d
lea rdx, [0x1400ad340]
lea rcx, [rsp + 0x118]
call fcn.1400021c0
cmp rax, 0xffffffffffffffff
je 0x140021538
mov rcx, qword [rsp + 0x130]
cmp rax, rcx
ja 0x140021522
or r8, 0xffffffffffffffff
mov rdx, rax
lea rcx, [rsp + 0x118]
call fcn.1400019e0
jmp 0x140021538
xor r8d, r8d
sub rax, rcx
mov rdx, rax
lea rcx, [rsp + 0x118]
call fcn.1400022f0
mov r8, r15
lea rdx, [0x1400ad33c]
lea rcx, [rsp + 0x118]
call fcn.14000a130
mov r8d, 0xa
lea rdx, str.DRVSTORE_
lea rcx, [rsp + 0x1b8]
call fcn.14000a130
lea rdx, [rsp + 0x48]
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x68], 7
mov qword [rsp + 0x60], r14
mov word [rsp + 0x50], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x118]
lea rcx, [rsp + 0x48]
call fcn.140001500
nop
mov qword [rsp + 0x90], 7
mov qword [rsp + 0x88], r14
mov word [rsp + 0x78], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x1b8]
lea rcx, [rsp + 0x70]
call fcn.140001500
nop
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], r14d
lea r9, [rsp + 0x48]
lea r8, [rsp + 0x70]
mov edx, r15d
mov rcx, r12
call fcn.14002cc40
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x118]
lea rcx, [rsp + 0x1b8]
call fcn.140001720
mov qword [rsp + 0x90], 7
mov qword [rsp + 0x88], r14
mov word [rsp + 0x78], r14w
or r9, 0xffffffffffffffff
xor r8d, r8d
lea rdx, [rsp + 0x1b8]
lea rcx, [rsp + 0x70]
call fcn.140001500
lea rcx, [rsp + 0x70]
call fcn.14002d860
nop
cmp qword [rsp + 0x138], 8
jb 0x140021667
mov rcx, qword [rsp + 0x120]
call fcn.140065920
nop
cmp qword [rsp + 0x1d8], 8
jb 0x14002167f
mov rcx, qword [rsp + 0x1c0]
call fcn.140065920
mov qword [rsp + 0x1d8], 7
mov qword [rsp + 0x1d0], r14
mov word [rsp + 0x1c0], r14w
cmp qword [rsp + 0x188], 8
jb 0x1400216b4
mov rcx, qword [rsp + 0x170]
call fcn.140065920
mov qword [rsp + 0x188], 7
mov qword [rsp + 0x180], r14
mov word [rsp + 0x170], r14w
cmp qword [rsp + 0x1b0], 8
jb 0x1400216e9
mov rcx, qword [rsp + 0x198]
call fcn.140065920
mov qword [rsp + 0x1b0], 7
mov qword [rsp + 0x1a8], r14
mov word [rsp + 0x198], r14w
cmp qword [rsp + 0x110], 8
jb 0x14002171e
mov rcx, qword [rsp + 0xf8]
call fcn.140065920
mov qword [rsp + 0x110], 7
mov qword [rsp + 0x108], r14
mov word [rsp + 0xf8], r14w
jmp 0x140021785
lea r9, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae r9, qword [rsp + 0xa8]
lea rax, str.Dir_GetWindowsDirectory
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], r14
lea rax, str.Error___i__return_by_function___s_
mov qword [rsp + 0x20], rax
mov r8d, r15d
mov edx, reloc.Cabinet.dll_FDICreate
mov rcx, r12
call fcn.1400144a0
nop
cmp qword [rsp + 0xe8], 8
jb 0x14002179d
mov rcx, qword [rsp + 0xd0]
call fcn.140065920
mov qword [rsp + 0xe8], 7
mov qword [rsp + 0xe0], r14
mov word [rsp + 0xd0], r14w
lea r9, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae r9, qword [rsp + 0xa8]
mov dword [rsp + 0x28], r15d
lea rax, str.Return_code__0x_x_
mov qword [rsp + 0x20], rax
mov r8d, r15d
mov edx, 0x28
mov rcx, r12
call fcn.1400144a0
lea r9, [rsp + 0xa8]
cmp qword [rsp + 0xc0], 8
cmovae r9, qword [rsp + 0xa8]
lea rcx, str.Function_end
mov qword [rsp + 0x20], rcx
mov r8d, r15d
mov edx, 0x32
mov rcx, r12
call fcn.1400144a0
nop
cmp qword [rsp + 0xc0], 8
jb 0x140021849
mov rcx, qword [rsp + 0xa8]
call fcn.140065920
mov eax, r15d
jmp 0x14002184c
mov eax, r15d
mov rcx, qword [rsp + 0x640]
xor rcx, rsp
call fcn.140064b70
mov rbx, qword [rsp + 0x690]
add rsp, 0x650
pop r15
pop r14
pop r13
pop r12
pop rdi
ret