Function at 0x1401ff1f4
Capabilities:
Query environment variable

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0x100
mov qword [rsp + 0x38], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov rax, qword [0x14049e510]
xor rax, rsp
mov qword [rbp + 0x17], rax
mov rsi, rdx
mov rbx, rcx
lea rcx, [rsp + 0x40]
call fcn.14004cf4c
nop
xor edx, edx
mov r12d, edx
lea r9, [0x1404a31f8]
mov rdi, qword [0x1404a31f8]
mov r14, qword [reloc.OLEAUT32.dll_VariantInit]
cmp r14, 8
cmovae r9, rdi
lea rcx, [rsp + 0x40]
cmp qword [rsp + 0x58], 8
cmovae rcx, qword [rsp + 0x40]
mov r15, qword [0x1404a3208]
mov qword [rsp + 0x20], r15
mov r8, r12
mov rdx, qword [rsp + 0x50]
call fcn.1401cdb24
mov qword [rsp + 0x30], rax
cmp rax, 0xffffffffffffffff
je 0x1401ff5d1
lea r9, [0x1404a31f8]
cmp r14, 8
cmovae r9, rdi
lea rcx, [rsp + 0x40]
cmp qword [rsp + 0x58], 8
cmovae rcx, qword [rsp + 0x40]
lea rdi, [rax + 1]
mov qword [rsp + 0x20], r15
mov r8, rdi
mov rdx, qword [rsp + 0x50]
call fcn.1401cdb24
mov r12, rax
cmp rax, 0xffffffffffffffff
je 0x1401ff5d1
mov r13, rax
sub r13, qword [rsp + 0x30]
lea r9, [r13 - 1]
mov r8, rdi
lea rdx, [rbp - 0x59]
lea rcx, [rsp + 0x40]
call fcn.14005d1b4
nop
lea rcx, [rbp - 0x59]
cmp qword [rbp - 0x41], 8
cmovae rcx, qword [rbp - 0x59]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov r15d, eax
xor r14d, r14d
test eax, eax
je 0x1401ff51a
dec eax
mov r14d, eax
xor edx, edx
mov qword [rbp - 0x69], rdx
mov qword [rbp - 0x61], 7
mov word [rbp - 0x79], dx
cmp r14, 7
ja 0x1401ff35d
mov qword [rbp - 0x69], r14
test eax, eax
je 0x1401ff34e
movzx eax, dx
lea rdi, [rbp - 0x79]
mov ecx, r14d
rep stosw word [rdi], ax
mov word [rbp + r14*2 - 0x79], dx
mov r8, qword [rbp - 0x79]
jmp 0x1401ff3e2
mov rdi, r14
or rdi, 7
mov eax, 0xa
cmp rdi, rax
cmovb rdi, rax
lea rcx, [rdi + 1]
movabs rax, 0x7fffffffffffffff
cmp rcx, rax
ja 0x1401ff633
add rcx, rcx
cmp rcx, 0x1000
jb 0x1401ff3b6
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x1401ff62d
mov rcx, rax
call fcn.1402e0358
lea r8, [rax + 0x27]
and r8, 0xffffffffffffffe0
mov qword [r8 - 8], rax
jmp 0x1401ff3be
call fcn.1402e0358
mov r8, rax
mov qword [rbp - 0x69], r14
mov qword [rbp - 0x61], rdi
xor edx, edx
test r14, r14
je 0x1401ff3d9
movzx eax, dx
mov rdi, r8
mov rcx, r14
rep stosw word [rdi], ax
mov word [r8 + r14*2], dx
mov qword [rbp - 0x79], r8
lea rdx, [rbp - 0x79]
cmp qword [rbp - 0x61], 8
cmovae rdx, r8
lea rcx, [rbp - 0x59]
cmp qword [rbp - 0x41], 8
cmovae rcx, qword [rbp - 0x59]
mov r8d, r15d
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
xor r14d, r14d
test eax, eax
je 0x1401ff450
lea r9, [rbp - 0x79]
cmp qword [rbp - 0x61], 8
cmovae r9, qword [rbp - 0x79]
lea r8, [r13 + 1]
mov rax, qword [rbp - 0x69]
mov qword [rsp + 0x20], rax
mov rdx, qword [rsp + 0x30]
lea rcx, [rsp + 0x40]
call fcn.1401b27a8
nop
lea rcx, [rbp - 0x79]
call fcn.14004e0f0
nop
lea rcx, [rbp - 0x59]
call fcn.14004e0f0
jmp 0x1401ff23e
call fcn.14004d8a4
mov rdi, qword [rax + 8]
cmp dword [rdi], 3
jbe 0x1401ff4f2
lea rax, str.Failed_to_extract_environment_variable
mov qword [rbp - 0x19], rax
mov qword [rbp - 0x11], MsiGetActiveDatabase
cmp qword [rsi + 0x18], 8
jb 0x1401ff47f
mov rsi, qword [rsi]
lea rcx, [0x140344690]
mov rax, r14
test rsi, rsi
je 0x1401ff49f
mov rcx, rsi
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], r14w
jne 0x1401ff495
mov qword [rbp - 9], rcx
lea eax, [rax*2 + 2]
mov dword [rbp - 1], eax
mov dword [rbp + 3], r14d
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov dword [rsp + 0x30], eax
lea rax, [rsp + 0x30]
mov qword [rbp + 7], rax
mov qword [rbp + 0xf], 4
lea rax, [rbp - 0x39]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 5
xor r9d, r9d
xor r8d, r8d
lea rdx, [0x1403e0398]
mov rcx, rdi
call fcn.140001158
mov qword [rbx + 0x10], r14
mov qword [rbx + 0x18], 7
mov word [rbx], r14w
lea rcx, [rbp - 0x79]
call fcn.14004e0f0
nop
lea rcx, [rbp - 0x59]
call fcn.14004e0f0
jmp 0x1401ff5f9
call fcn.14004d8a4
mov rdi, qword [rax + 8]
cmp dword [rdi], 3
jbe 0x1401ff5bc
lea rax, str.Failed_to_find_environment_variable
mov qword [rbp - 0x19], rax
mov qword [rbp - 0x11], 0x24
cmp qword [rsi + 0x18], 8
jb 0x1401ff549
mov rsi, qword [rsi]
lea rcx, [0x140344690]
mov rax, r14
test rsi, rsi
je 0x1401ff569
mov rcx, rsi
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], r14w
jne 0x1401ff55f
mov qword [rbp - 9], rcx
lea eax, [rax*2 + 2]
mov dword [rbp - 1], eax
mov dword [rbp + 3], r14d
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
mov dword [rsp + 0x30], eax
lea rax, [rsp + 0x30]
mov qword [rbp + 7], rax
mov qword [rbp + 0xf], 4
lea rax, [rbp - 0x39]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 5
xor r9d, r9d
xor r8d, r8d
lea rdx, [0x1403e0398]
mov rcx, rdi
call fcn.140001158
mov qword [rbx + 0x10], r14
mov qword [rbx + 0x18], 7
mov word [rbx], r14w
jmp 0x1401ff50c
movups xmm0, xmmword [rsp + 0x40]
xor r13d, r13d
movups xmm1, xmmword [rsp + 0x50]
movups xmmword [rbx], xmm0
mov word [rsp + 0x40], r13w
mov qword [rsp + 0x58], 7
mov qword [rsp + 0x50], r13
movups xmmword [rbx + 0x10], xmm1
lea rcx, [rsp + 0x40]
call fcn.14004e0f0
mov rax, rbx
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.1402dfdb0
mov rbx, qword [rsp + 0x150]
add rsp, 0x100
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.14004d44c
nop
call fcn.14004d44c
int3