Function at 0x14003a9b3
Capabilities:
Get common file path

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x78
xor r14d, r14d
mov qword [rsp + 0x48], r14
mov r15d, ecx
mov rbx, r8
mov r12, r9
mov qword [rsp + 0xc8], rdx
mov qword [rsp + 0x50], r14
mov qword [rsp + 0x58], r14
test r8, r8
jne 0x14003a9f2
xor ebx, ebx
jmp 0x14003ae22
mov rcx, qword [r8]
test rcx, rcx
je 0x14003a9eb
cmp qword [r8 + 0x10], 0
je 0x14003a9eb
cmp qword [r8 + 0x18], 0
je 0x14003a9eb
inc rcx
mov edx, 0x10
call sub.msvcrt.dll_calloc
mov rsi, rax
test rax, rax
je 0x14003a9eb
mov rbp, qword [0x1400b48b0]
mov rdi, rax
mov r13, rax
xor r14d, r14d
inc dword [rbp]
cmp r14, qword [rbx]
jae 0x14003aa60
mov rax, qword [rbx + 0x10]
add r13, 0x10
mov rcx, qword [rax + r14*8]
call fcn.14003a223
mov qword [r13 - 8], rax
mov rax, qword [rbx + 0x18]
mov rcx, qword [rax + r14*8]
inc r14
call fcn.14003a223
mov qword [r13 - 0x10], rax
jmp 0x14003aa30
lea rax, [0x14009ae36]
mov ecx, 0xc23
mov qword [r13 + 8], rax
call fcn.14001e311
mov rcx, rax
call fcn.14003a223
mov rcx, qword [0x1400b4240]
mov qword [r13], rax
test r15d, r15d
je 0x14003aa94
mov rcx, qword [0x1400b4250]
lea rax, [rsp + 0x48]
mov r9, qword [0x1400b4320]
mov r8d, 3
xor edx, edx
mov qword [rsp + 0x20], rax
call qword [sym.imp.ole32.dll_CoCreateInstance]
mov ecx, eax
test eax, eax
js 0x14003aac8
mov rcx, qword [rsp + 0x48]
test rcx, rcx
jne 0x14003aae7
mov ecx, 0xc0083de1
call qword [sym.imp.KERNEL32.DLL_SetLastError]
call fcn.140038579
lea rcx, str.CoCreateInstance_for_FileOpenDialog_failed:__s
mov rdx, rax
call fcn.1400380b9
jmp 0x14003ae05
mov eax, dword [rbx]
mov r8, rsi
lea edx, [rax + 1]
mov rax, qword [rcx]
call qword [rax + 0x20]
cmp qword [rsp + 0xc8], 0
jne 0x14003ab74
xor r8d, r8d
lea rcx, [rsp + 0x60]
lea r9, [rsp + 0x50]
xor edx, edx
movabs rax, 0x4565123f374de290
mov qword [rsp + 0x60], rax
movabs rax, 0x7b465e92c4396491
mov qword [rsp + 0x68], rax
call sub.SHELL32.dll_SHGetKnownFolderPath
test eax, eax
js 0x14003abc3
xor edx, edx
mov rcx, qword [rsp + 0x50]
lea r9, [rsp + 0x58]
mov r8, qword [0x1400b4340]
call qword [sym.imp.SHELL32.dll_SHCreateItemFromParsingName]
test eax, eax
js 0x14003ab67
mov rcx, qword [rsp + 0x48]
mov rdx, qword [rsp + 0x58]
mov rax, qword [rcx]
call qword [rax + 0x58]
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ole32.dll_CoTaskMemFree]
jmp 0x14003abc3
mov rcx, qword [rsp + 0xc8]
call fcn.14003a223
xor edx, edx
lea r9, [rsp + 0x58]
mov r8, qword [0x1400b4340]
mov qword [rsp + 0x50], rax
mov rcx, rax
call qword [sym.imp.SHELL32.dll_SHCreateItemFromParsingName]
test eax, eax
js 0x14003abb1
mov rcx, qword [rsp + 0x48]
mov rdx, qword [rsp + 0x58]
mov rax, qword [rcx]
call qword [rax + 0x60]
mov rcx, qword [rsp + 0x50]
xor r13d, r13d
call sub.msvcrt.dll_free
mov qword [rsp + 0x50], r13
mov rcx, qword [rbx + 8]
test rcx, rcx
jne 0x14003abd3
lea rcx, [0x14009ae35]
call fcn.14003a223
mov r14, rax
test rax, rax
je 0x14003abee
mov rcx, qword [rsp + 0x48]
mov rdx, r14
mov rax, qword [rcx]
call qword [rax + 0x78]
mov rax, qword [rbx + 0x10]
lea rcx, [0x14009ae35]
test rax, rax
je 0x14003ac01
mov rcx, qword [rax]
call fcn.14003a223
mov r15, rax
test rax, rax
je 0x14003ac1f
mov rcx, qword [rsp + 0x48]
mov rdx, r15
mov rax, qword [rcx]
call qword [rax + 0xb0]
mov rcx, qword [rsp + 0x48]
xor edx, edx
mov rax, qword [rcx]
mov rax, qword [rax + 0x28]
test r12, r12
je 0x14003ac36
mov edx, dword [r12]
call rax
mov rcx, qword [rsp + 0x48]
mov rdx, qword [0x1400b4b90]
mov rax, qword [rcx]
mov rdx, qword [rdx]
call qword [rax + 0x18]
mov r13d, eax
test r12, r12
je 0x14003ac63
mov rcx, qword [rsp + 0x48]
mov rdx, r12
mov rax, qword [rcx]
call qword [rax + 0x30]
mov rcx, r15
xor r12d, r12d
call sub.msvcrt.dll_free
mov rcx, r14
call sub.msvcrt.dll_free
cmp r12, qword [rbx]
jae 0x14003aca4
mov rcx, qword [rdi + 8]
inc r12
add rdi, 0x10
call sub.msvcrt.dll_free
xor r10d, r10d
mov rcx, qword [rdi - 0x10]
mov qword [rdi - 8], r10
call sub.msvcrt.dll_free
xor r11d, r11d
mov qword [rdi - 0x10], r11
jmp 0x14003ac76
mov rcx, qword [rdi]
call sub.msvcrt.dll_free
xor r9d, r9d
mov rcx, rsi
mov qword [rdi], r9
call sub.msvcrt.dll_free
test r13d, r13d
js 0x14003adde
mov rcx, qword [rsp + 0x48]
lea rdx, [rsp + 0x60]
mov rax, qword [rcx]
call qword [rax + 0xa0]
test eax, eax
js 0x14003ae03
mov rcx, qword [rsp + 0x60]
lea r8, [rsp + 0x50]
mov edx, 0x80058000
mov rax, qword [rcx]
call qword [rax + 0x28]
mov ecx, eax
test eax, eax
js 0x14003adb3
mov r12, qword [rsp + 0x50]
cmp word [r12], 0
jne 0x14003ad21
mov edx, 1
mov ecx, 1
call sub.msvcrt.dll_calloc
mov rbx, rax
jmp 0x14003ada6
xor edx, edx
xor ecx, ecx
xor r8d, r8d
mov r13, qword [sym.imp.KERNEL32.DLL_WideCharToMultiByte]
mov qword [rsp + 0x38], rdx
or r9d, 0xffffffff
mov qword [rsp + 0x30], rdx
xor edx, edx
mov dword [rsp + 0x28], ecx
mov ecx, 0xfde9
mov qword [rsp + 0x20], r8
mov r8, r12
call r13
mov edi, eax
cmp eax, 1
jle 0x14003ada4
movsxd rcx, eax
mov edx, 1
call sub.msvcrt.dll_calloc
mov rsi, rax
mov rbx, rax
test rax, rax
je 0x14003ada4
xor eax, eax
or r9d, 0xffffffff
xor edx, edx
mov dword [rsp + 0x28], edi
mov qword [rsp + 0x38], rax
mov r8, r12
mov ecx, 0xfde9
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x20], rsi
call r13
cmp edi, eax
je 0x14003ada6
mov rcx, rsi
call sub.msvcrt.dll_free
xor ebx, ebx
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ole32.dll_CoTaskMemFree]
jmp 0x14003adcf
call qword [sym.imp.KERNEL32.DLL_SetLastError]
xor ebx, ebx
call fcn.140038579
lea rcx, str.Unable_to_access_file_path:__s
mov rdx, rax
call fcn.1400380b9
mov rcx, qword [rsp + 0x60]
xor esi, esi
mov rax, qword [rcx]
call qword [rax + 0x10]
jmp 0x14003ae07
cmp r13w, 0x4c7
je 0x14003ae03
mov ecx, r13d
call qword [sym.imp.KERNEL32.DLL_SetLastError]
call fcn.140038579
lea rcx, str.Could_not_show_FileOpenDialog:__s
mov rdx, rax
call fcn.1400380b9
xor esi, esi
xor ebx, ebx
mov rcx, rsi
call sub.msvcrt.dll_free
mov rcx, qword [rsp + 0x48]
test rcx, rcx
je 0x14003ae1f
mov rax, qword [rcx]
call qword [rax + 0x10]
dec dword [rbp]
mov rax, rbx
add rsp, 0x78
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret