Function at 0x1400563a0
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
mov rax, rsp
push rdi
sub rsp, 0x2b0
mov qword [rsp + 0x30], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
mov rax, qword [0x140099938]
xor rax, rsp
mov qword [rsp + 0x2a0], rax
mov rdi, rcx
lea r8, [0x1400840f0]
lea rdx, str.CUninstLanguageSelector::IsInstalledScannerDriver
mov ecx, 5
call fcn.140009480
xor esi, esi
lea ebp, [rsi + 7]
mov qword [rsp + 0x80], rbp
mov qword [rsp + 0x78], rsi
mov word [rsp + 0x68], si
lea rbx, [0x140077480]
mov rcx, rbx
call fcn.14005b1c0
mov r8, rax
mov rdx, rbx
lea rcx, [rsp + 0x60]
call fcn.140002280
nop
mov qword [rsp + 0x58], rbp
mov qword [rsp + 0x50], rsi
mov word [rsp + 0x40], si
mov rcx, rbx
call fcn.14005b1c0
mov r8, rax
mov rdx, rbx
lea rcx, [rsp + 0x38]
call fcn.140002280
nop
lea rdx, str.___NAME_CISDS_DS___
mov rcx, qword [rdi + 0x480]
call fcn.14005429c
mov rbx, rax
mov rcx, rax
call fcn.14005b1c0
mov r8, rax
mov rdx, rbx
lea rcx, [rsp + 0x38]
call fcn.140002280
cmp qword [rsp + 0x50], rsi
je 0x1400564ae
lea rcx, str.___NAME_CISDS_DS___
call fcn.14005b1c0
mov qword [rsp + 0x20], rax
lea r9, str.___NAME_CISDS_DS___
mov r8, qword [rsp + 0x50]
xor edx, edx
lea rcx, [rsp + 0x38]
call fcn.140002d6c
cmp eax, esi
jne 0x1400564ce
lea rcx, str.CISDS.DS
call fcn.14005b1c0
mov r8, rax
lea rdx, str.CISDS.DS
lea rcx, [rsp + 0x38]
call fcn.140002280
xor edx, edx
mov r8d, 0x20a
lea rcx, [rsp + 0x90]
call fcn.14005bb90
mov edx, 0x105
lea rcx, [rsp + 0x90]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
cmp eax, esi
jne 0x140056537
cmp qword [rsp + 0x58], 8
jb 0x14005650c
mov rcx, qword [rsp + 0x40]
call fcn.14005ab0c
mov qword [rsp + 0x58], rbp
mov qword [rsp + 0x50], rsi
mov word [rsp + 0x40], si
cmp qword [rsp + 0x80], 8
jb 0x140056530
mov rcx, qword [rsp + 0x68]
call fcn.14005ab0c
xor eax, eax
jmp 0x140056644
lea rcx, [rsp + 0x90]
call fcn.14005b1c0
mov r8, rax
lea rdx, [rsp + 0x90]
lea rcx, [rsp + 0x60]
call fcn.140002280
lea rdx, str.Twain_32
lea rcx, [rsp + 0x60]
call fcn.140058a34
mov rdx, qword [rdi + 0x478]
lea rcx, [rsp + 0x60]
call fcn.140058a34
lea rdx, [rsp + 0x40]
cmp qword [rsp + 0x58], 8
cmovae rdx, qword [rsp + 0x40]
lea rcx, [rsp + 0x60]
call fcn.140058a34
lea rbx, [rsp + 0x68]
cmp qword [rsp + 0x80], 8
cmovae rbx, qword [rsp + 0x68]
mov r9, rbx
lea r8, str.pFileName
lea rdx, str.CUninstLanguageSelector::IsInstalledScannerDriver
mov edi, 4
mov ecx, edi
call fcn.1400099b4
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, esi
lea r8d, [rdi - 3]
cmp eax, 0xffffffff
cmovne ebx, r8d
mov r9d, ebx
lea r8, str.bFound
lea rdx, str.CUninstLanguageSelector::IsInstalledScannerDriver
mov ecx, edi
call fcn.140009a34
lea r8, [0x140084110]
lea rdx, str.CUninstLanguageSelector::IsInstalledScannerDriver
lea ecx, [rdi + 1]
call fcn.140009480
nop
cmp qword [rsp + 0x58], 8
jb 0x14005661e
mov rcx, qword [rsp + 0x40]
call fcn.14005ab0c
mov qword [rsp + 0x58], rbp
mov qword [rsp + 0x50], rsi
mov word [rsp + 0x40], si
cmp qword [rsp + 0x80], 8
jb 0x140056642
mov rcx, qword [rsp + 0x68]
call fcn.14005ab0c
mov eax, ebx
mov rcx, qword [rsp + 0x2a0]
xor rcx, rsp
call fcn.14005bad0
lea r11, [rsp + 0x2b0]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret