Function at 0x46d9f0
Capabilities:
Query environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x4a8
mov rsi, rcx
lea rcx, [rsp + 0xa8]
call fcn.00451fe0
mov r15, qword [rsp + 0xb0]
test r15, r15
je 0x46db78
mov qword [rsp + 0x30], rsi
mov rcx, qword [rsp + 0xa8]
mov rax, qword [rsp + 0xb8]
mov qword [rsp + 0x50], rcx
mov qword [rsp + 0x78], rcx
mov qword [rsp + 0x80], r15
mov qword [rsp + 0x88], rax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x40], 2
mov qword [rsp + 0x48], 0
mov r8d, 0x200
mov eax, 2
mov qword [rsp + 0x20], rax
xor edi, edi
xor r14d, r14d
xor esi, esi
cmp r8, 0x201
jae 0x46dac0
jmp 0x46daa2
mov r15, rbx
jae 0x46dbc5
cmp r8, 0x201
jae 0x46dac0
lea rbp, [rsp + 0xa8]
mov r12d, 0x200
mov r13, r8
jmp 0x46db0b
sub r8, rsi
sub r14, rsi
cmp r14, r8
jae 0x46dae7
lea rcx, [rsp + 0x38]
mov rdx, rsi
call fcn.00452480
mov rdi, qword [rsp + 0x38]
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x20], rax
mov eax, 0xffffffff
cmp rdi, rax
mov esi, 0xffffffff
cmovb rsi, rdi
mov qword [rsp + 0x48], rsi
mov r14, rdi
mov rbp, qword [rsp + 0x20]
mov r12, rsi
mov r13, rsi
xor ecx, ecx
call sub.KERNEL32.dll_SetLastError
mov rbx, r15
mov rcx, r15
mov rdx, rbp
mov r8d, r13d
call sub.KERNEL32.dll_GetEnvironmentVariableW
mov r15d, eax
test eax, eax
jne 0x46db37
call sub.KERNEL32.dll_GetLastError
test eax, eax
jne 0x46dc04
mov r8d, r15d
cmp r13, r8
jne 0x46da90
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x7a
jne 0x46dcc4
mov r15, rbx
add r13, r13
mov eax, 0xffffffff
cmp r13, rax
cmovae r13, rax
mov r8, r13
cmp r8, 0x201
jb 0x46daa2
jmp 0x46dac0
mov rbx, qword [rsp + 0xa8]
mov eax, ebx
and eax, 3
cmp eax, 1
jne 0x46dbbc
lea rdi, [rbx - 1]
mov rcx, qword [rbx - 1]
mov rax, qword [rbx + 7]
call qword [rax]
mov rax, qword [rbx + 7]
cmp qword [rax + 8], 0
je 0x46dbaf
mov rdx, qword [rax + 0x10]
mov rcx, qword [rdi]
call fcn.004244e0
mov edx, 8
mov rcx, rdi
call fcn.004244e0
mov byte [rsi + 0x18], 2
jmp 0x46dcaf
cmp r12, r8
jb 0x46dcde
lea rcx, [rsp + 0x58]
mov rdx, rbp
call fcn.00453480
mov r15, qword [rsp + 0x58]
movups xmm0, xmmword [rsp + 0x60]
movaps xmmword [rsp + 0x90], xmm0
movzx ebp, byte [rsp + 0x70]
mov eax, dword [rsp + 0x71]
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x74]
mov dword [rsp + 0x2b], eax
jmp 0x46dc17
call sub.KERNEL32.dll_GetLastError
mov r15d, eax
shl r15, 0x20
or r15, 2
mov bpl, 2
mov rsi, qword [rsp + 0x30]
test rdi, rdi
je 0x46dc30
mov edx, 2
mov rcx, qword [rsp + 0x20]
call fcn.004244e0
cmp bpl, 2
jne 0x46dc79
mov byte [rsi + 0x18], 2
mov eax, r15d
and eax, 3
cmp eax, 1
jne 0x46dc9a
lea rdi, [r15 - 1]
mov rcx, qword [r15 - 1]
mov rax, qword [r15 + 7]
call qword [rax]
mov rax, qword [r15 + 7]
cmp qword [rax + 8], 0
je 0x46dc6a
mov rdx, qword [rax + 0x10]
mov rcx, qword [rdi]
call fcn.004244e0
mov edx, 8
mov rcx, rdi
call fcn.004244e0
jmp 0x46dc9a
movaps xmm0, xmmword [rsp + 0x90]
movups xmmword [rsi + 8], xmm0
mov eax, dword [rsp + 0x28]
mov ecx, dword [rsp + 0x2b]
mov dword [rsi + 0x19], eax
mov dword [rsi + 0x1c], ecx
mov qword [rsi], r15
mov byte [rsi + 0x18], bpl
cmp qword [rsp + 0x50], 0
je 0x46dcaf
mov edx, 2
mov rcx, rbx
call fcn.004244e0
nop
add rsp, 0x4a8
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
lea rcx, str.internal_error:_entered_unreachable_code
lea r8, str.library_std_src_syswindowsmod.rs
mov edx, 0x28
call fcn.00428f60
jmp 0x46dcf3
lea rax, str.library_std_src_syswindowsmod.rs
mov rcx, r8
mov rdx, r12
mov r8, rax
call fcn.00428b90
ud2