Function at 0x14000857c
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x380]
sub rsp, 0x480
mov rax, qword [0x140016010]
xor rax, rsp
mov qword [rbp + 0x370], rax
mov rsi, rdx
mov byte [rsp + 0x31], r9b
mov r14d, 0xa
mov rdi, r8
mov edx, r14d
mov rbx, rcx
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
mov r12, rax
mov rcx, rbx
xor eax, eax
test r12, r12
jne 0x1400085e5
call fcn.14000e208
mov qword [rsi], rax
xor al, al
jmp 0x1400088de
mov r8, rdi
mov word [r12], ax
mov dl, 0xff
call fcn.14000ec7c
mov qword [rsi], rax
mov word [r12], r14w
add r12, 2
mov rax, qword [rsi]
cmp rax, rbx
jne 0x140008613
mov rcx, rbx
call fcn.14000e208
mov qword [rsi], rax
mov r8, rdi
mov qword [rsp + 0x40], rax
mov dl, 0xff
mov rcx, r12
call fcn.14000ec7c
lea rcx, [rsp + 0x40]
mov qword [rsp + 0x38], rax
mov r13, rax
call fcn.140007b68
xor edi, edi
test rax, rax
je 0x1400088ce
mov rcx, rax
mov byte [rsp + 0x30], dil
mov ebx, 0x3c
call fcn.14000e208
mov r15, rax
cmp word [rax], di
jne 0x1400087b7
lea r9, [0x140012dc8]
mov qword [rsp + 0x48], rdi
mov r8d, 0x103
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x48]
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll__wgetenv_s]
test eax, eax
jne 0x14000868d
cmp qword [rsp + 0x48], rdi
jne 0x1400086a4
lea r8, [0x140012dd0]
mov edx, 0x103
lea rcx, [rsp + 0x50]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
lea r9, [rbp + 0x160]
xor r8d, r8d
lea rdx, [0x140012dd4]
mov r14, rdi
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
je 0x1400086f9
lea r8, [rbp + 0x160]
mov edx, 0x103
lea rcx, [rsp + 0x50]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov r8d, 0x20
lea rdx, [0x140012fe8]
lea rcx, [rsp + 0x50]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__wfsopen]
mov r14, rax
test r14, r14
jne 0x140008713
mov ecx, dword [0x140026c20]
lea r8, [rsp + 0x50]
mov edx, 0x41e
call fcn.140003e48
mov edx, 0x20
lea rcx, [rsp + 0x50]
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
test rax, rax
je 0x140008792
mov edx, 0x22
lea rcx, [rsp + 0x50]
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
test rax, rax
jne 0x140008792
lea rcx, [rsp + 0x50]
or rdi, 0xffffffffffffffff
inc rdi
cmp word [rcx + rdi*2], ax
jne 0x140008746
lea rbx, [rdi + rdi]
mov r8, rbx
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x52]
call sub.VCRUNTIME140.dll_memmove
mov eax, 0x22
lea rdi, [rdi*2 + 4]
mov word [rsp + 0x50], ax
mov word [rsp + rbx + 0x52], ax
cmp rdi, 0x206
jae 0x140008908
xor eax, eax
mov word [rsp + rdi + 0x50], ax
push rax
xor edi, edi
lea rdx, [rsp + 0x50]
mov rcx, rsi
call fcn.140008030
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rcx, [rsp + 0x50]
call fcn.14000e208
mov r15, rax
jmp 0x140008819
lea rdx, [0x140012fe8]
mov rcx, r15
call fcn.1400102bc
mov r14, rax
test rax, rax
jne 0x1400087e3
mov ecx, dword [0x140026c20]
mov r8, r15
mov edx, 0x41e
call fcn.140003e48
jmp 0x140008819
mov rcx, qword [rsi]
mov edx, ebx
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
lea rcx, [rax + 2]
cmp word [rcx], bx
jne 0x1400087e6
lea rdx, [rax + 4]
or r8, 0xffffffffffffffff
inc r8
cmp word [rdx + r8*2], di
jne 0x1400087ff
lea r8, [r8*2 + 2]
mov rcx, rax
call sub.VCRUNTIME140.dll_memmove
mov rax, qword [rsi]
lea r8, [rsp + 0x38]
mov r9b, byte [rsp + 0x31]
mov rdx, r15
mov qword [rsp + 0x40], rax
mov rcx, r14
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
call fcn.140008180
mov rbx, qword [rsp + 0x38]
mov edx, 0xa
mov rcx, rbx
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
test rax, rax
je 0x14000885e
add rax, 2
jmp 0x14000886f
or rax, 0xffffffffffffffff
inc rax
cmp word [rbx + rax*2], di
jne 0x140008862
lea rax, [rbx + rax*2]
mov rcx, r14
mov qword [rsp + 0x38], rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
cmp byte [rsp + 0x30], dil
jne 0x1400088b6
call fcn.14000e19c
mov rcx, r15
mov rbx, rax
call fcn.14000e208
mov qword [rbx + 8], rax
lea rdx, [0x140037e88]
mov rcx, qword [0x140037e88]
jmp 0x1400088ae
mov rdx, rcx
mov rcx, qword [rcx]
test rcx, rcx
jne 0x1400088a8
mov qword [rdx], rbx
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rcx, [rsp + 0x40]
call fcn.140007b68
jmp 0x140008639
cmp r13, r12
je 0x1400088dc
mov rcx, r13
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov al, 1
mov rcx, qword [rbp + 0x370]
xor rcx, rsp
call fcn.1400106c0
mov rbx, qword [rsp + 0x4d8]
add rsp, 0x480
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.1400107e8
int3