Function at 0x1400068e0
Capabilities:
Create directory
Get common file path
Query environment variable
Set environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
mov eax, 0x4028
call fcn.14000de6c
sub rsp, rax
mov rdi, rdx
mov rbx, rcx
test rdx, rdx
je 0x140006977
lea rcx, [0x1400193d8]
call fcn.1400067b0
mov rsi, rax
xor r14d, r14d
xor ecx, ecx
mov rdx, rdi
xor r8d, r8d
call fcn.140007a80
test rax, rax
je 0x140006b1a
mov r15, rax
lea rdx, [rsp + 0x20]
mov rcx, rax
mov r8d, 0x1000
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov ebp, eax
mov rcx, r15
call sub.msvcrt.dll_free
test ebp, ebp
je 0x140006b2b
lea rcx, [rsp + 0x20]
call fcn.140007e80
test eax, eax
je 0x140006b4f
lea rcx, [rsp + 0x20]
call qword [sym.imp.msvcrt.dll__wcsdup]
jmp 0x140006b62
xor esi, esi
lea r14, [rsp + 0x20]
mov ecx, 0x1000
mov rdx, r14
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
call sub.msvcrt.dll__getpid
lea r15, [rsp + 0x2020]
mov rcx, r15
mov r9d, eax
call fcn.140006c50
mov rcx, r14
mov rdx, r15
call qword [sym.imp.msvcrt.dll__wtempnam]
mov r14, rax
mov rcx, rax
call fcn.140007dc0
test eax, eax
je 0x140006aa8
mov rcx, r14
call sub.msvcrt.dll_free
lea rcx, [rsp + 0x20]
lea rdx, [rsp + 0x2020]
call qword [sym.imp.msvcrt.dll__wtempnam]
mov r14, rax
mov rcx, rax
call fcn.140007dc0
test eax, eax
je 0x140006aa8
mov rcx, r14
call sub.msvcrt.dll_free
lea rcx, [rsp + 0x20]
lea rdx, [rsp + 0x2020]
call qword [sym.imp.msvcrt.dll__wtempnam]
mov r14, rax
mov rcx, rax
call fcn.140007dc0
test eax, eax
je 0x140006aa8
mov rcx, r14
call sub.msvcrt.dll_free
lea rcx, [rsp + 0x20]
lea rdx, [rsp + 0x2020]
call qword [sym.imp.msvcrt.dll__wtempnam]
mov r14, rax
mov rcx, rax
call fcn.140007dc0
test eax, eax
je 0x140006aa8
mov rcx, r14
call sub.msvcrt.dll_free
lea rcx, [rsp + 0x20]
lea rdx, [rsp + 0x2020]
call qword [sym.imp.msvcrt.dll__wtempnam]
mov r14, rax
mov rcx, rax
call fcn.140007dc0
test eax, eax
je 0x140006aa8
mov rcx, r14
call sub.msvcrt.dll_free
test rdi, rdi
je 0x140006c29
lea rdx, [0x1400193d8]
xor r14d, r14d
xor ecx, ecx
xor r8d, r8d
call fcn.140007a80
mov rdi, rax
test rsi, rsi
jne 0x140006ae9
xor r14d, r14d
jmp 0x140006b37
mov r8d, 0x1000
mov rcx, rbx
mov rdx, r14
call fcn.140007830
mov rcx, r14
call sub.msvcrt.dll_free
mov r14d, 1
test rdi, rdi
je 0x140006c2c
lea rdx, [0x1400193d8]
xor ecx, ecx
xor r8d, r8d
call fcn.140007a80
mov rdi, rax
test rsi, rsi
je 0x140006b37
xor ecx, ecx
mov rdx, rsi
xor r8d, r8d
call fcn.140007a80
mov rbx, rax
mov rcx, rdi
mov rdx, rax
call qword [sym.imp.msvcrt.dll__wputenv_s]
mov rcx, rdi
call sub.msvcrt.dll_free
mov rcx, rbx
call sub.msvcrt.dll_free
mov rcx, rsi
jmp 0x140006b45
lea rcx, str.LOADER:_Failed_to_convert_runtime_tmpdir_to_a_wide_string._n
call fcn.1400021d0
jmp 0x140006c2c
lea rcx, str.LOADER:_Failed_to_expand_environment_variables_in_the_runtime_tmpdir._n
jmp 0x140006c24
mov rcx, rdi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, rdi
call sub.msvcrt.dll_free
jmp 0x140006c2c
lea rdx, [rsp + 0x20]
mov r8d, 0x1000
xor ecx, ecx
call qword [sym.imp.msvcrt.dll__wfullpath]
mov r14, rax
test rax, rax
je 0x140006c1d
lea rcx, [rsp + 0x2020]
mov r8d, 0x2000
xor edx, edx
call sub.msvcrt.dll_memset
mov rcx, r14
mov dx, 0x5c
call sub.msvcrt.dll_wcschr
test rax, rax
je 0x140006be7
mov r15, rax
lea r12, [rsp + 0x2020]
mov r13, qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
nop word cs:[rax + rax]
mov r8, r15
sub r8, r14
sar r8, 1
inc r8
mov rcx, r12
mov rdx, r14
call sub.msvcrt.dll_wcsncpy
mov rcx, r12
xor edx, edx
call r13
add r15, 2
mov rcx, r15
mov dx, 0x5c
call sub.msvcrt.dll_wcschr
mov r15, rax
test rax, rax
jne 0x140006bb0
mov rcx, r14
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea rcx, [0x1400193dc]
mov rdx, r14
call qword [sym.imp.msvcrt.dll__wputenv_s]
mov ebp, eax
mov rcx, r14
call sub.msvcrt.dll_free
test ebp, ebp
je 0x140006979
lea rcx, str.LOADER:_Failed_to_set_the_TMP_environment_variable._n
jmp 0x140006c24
lea rcx, str.LOADER:_Failed_to_obtain_the_absolute_path_of_the_runtime_tmpdir._n
call fcn.1400021d0
xor r14d, r14d
mov eax, r14d
add rsp, 0x4028
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret