Function at 0x140003940
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x80
mov rax, qword [0x14001f020]
xor rax, rsp
mov qword [rsp + 0x70], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], 1
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
xor r14d, r14d
mov edi, 7
mov qword [rcx + 0x18], rdi
mov dword [rsp + 0x20], 1
mov qword [rcx + 0x10], r14
mov word [rcx], r14w
xor r8d, r8d
xor edx, edx
lea rcx, str.DOTNET_RUNTIME_ID
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ebp, eax
test eax, eax
je 0x1400039e7
mov eax, 2
mul rbp
mov rcx, 0xffffffffffffffff
cmovo rax, rcx
mov rcx, rax
call fcn.14000fe8c
mov rsi, rax
mov r8d, ebp
mov rdx, rax
lea rcx, str.DOTNET_RUNTIME_ID
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x140003b98
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xcb
je 0x140003a16
test eax, eax
jle 0x140003a00
movzx eax, ax
or eax, 0x80070000
mov r8d, eax
lea rdx, str.DOTNET_RUNTIME_ID
lea rcx, str.Failed_to_read_environment_variable___s___HRESULT:_0x_X
call fcn.140001f30
lea rcx, [rsp + 0x50]
call fcn.14000bc30
mov rsi, rax
cmp rbx, rax
je 0x140003a89
mov rdx, qword [rbx + 0x18]
cmp rdx, 8
jb 0x140003a63
mov rcx, qword [rbx]
lea rdx, [rdx*2 + 2]
cmp rdx, 0x1000
jb 0x140003a5e
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140003ac2
mov rcx, r8
call fcn.14000fbc0
mov qword [rbx + 0x10], r14
mov qword [rbx + 0x18], rdi
mov word [rbx], r14w
movups xmm0, xmmword [rsi]
movups xmmword [rbx], xmm0
movups xmm1, xmmword [rsi + 0x10]
movups xmmword [rbx + 0x10], xmm1
mov qword [rsi + 0x10], r14
mov qword [rsi + 0x18], rdi
mov word [rsi], r14w
mov rdx, qword [rsp + 0x68]
cmp rdx, 8
jb 0x140003ace
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140003ac9
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140003ac9
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000fbc0
cmp qword [rbx + 0x10], 0
jne 0x140003b71
mov dword [rsp + 0x3c], r14d
mov qword [rsp + 0x40], 5
mov qword [rsp + 0x48], rdi
movsd xmm0, qword [str.win10]
movsd qword [rsp + 0x30], xmm0
movzx eax, word [0x140018fa0]
mov word [rsp + 0x38], ax
mov word [rsp + 0x3a], r14w
mov dword [rsp + 0x20], 3
lea rax, [rsp + 0x30]
cmp rbx, rax
je 0x140003b6a
mov rdx, qword [rbx + 0x18]
cmp rdx, 8
jb 0x140003b59
mov rcx, qword [rbx]
lea rdx, [rdx*2 + 2]
cmp rdx, 0x1000
jb 0x140003b54
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140003b91
mov rcx, r8
call fcn.14000fbc0
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rbx], xmm0
movups xmm1, xmmword [rsp + 0x40]
movups xmmword [rbx + 0x10], xmm1
cmp qword [rbx + 0x10], 0
je 0x140003bac
lea rdx, [0x14001904c]
mov rcx, rbx
call fcn.140004c30
mov rdx, qword [0x140018c48]
mov rcx, rbx
call fcn.140004c30
jmp 0x140003bac
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
mov rdx, rsi
mov rcx, rbx
call fcn.140004bb0
mov rcx, rsi
call fcn.14000fbc0
nop
mov rax, rbx
mov rcx, qword [rsp + 0x70]
xor rcx, rsp
call fcn.14000fba0
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret