Function at 0x4a7190
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.0048b840
mov r15, qword [rsp + 0xb0]
test r15, r15
je 0x4a7318
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 0x4a7260
jmp 0x4a7242
mov r15, rbx
jae 0x4a7365
cmp r8, 0x201
jae 0x4a7260
lea rbp, [rsp + 0xa8]
mov r12d, 0x200
mov r13, r8
jmp 0x4a72ab
sub r8, rsi
sub r14, rsi
cmp r14, r8
jae 0x4a7287
lea rcx, [rsp + 0x38]
mov rdx, rsi
call fcn.0048bce0
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 0x4a72d7
call sub.KERNEL32.dll_GetLastError
test eax, eax
jne 0x4a73a4
mov r8d, r15d
cmp r13, r8
jne 0x4a7230
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x7a
jne 0x4a7464
mov r15, rbx
add r13, r13
mov eax, 0xffffffff
cmp r13, rax
cmovae r13, rax
mov r8, r13
cmp r8, 0x201
jb 0x4a7242
jmp 0x4a7260
mov rbx, qword [rsp + 0xa8]
mov eax, ebx
and eax, 3
cmp eax, 1
jne 0x4a735c
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 0x4a734f
mov rdx, qword [rax + 0x10]
mov rcx, qword [rdi]
call fcn.0040c7c0
mov edx, 8
mov rcx, rdi
call fcn.0040c7c0
mov byte [rsi + 0x18], 2
jmp 0x4a744f
cmp r12, r8
jb 0x4a747e
lea rcx, [rsp + 0x58]
mov rdx, rbp
call fcn.0048cc20
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 0x4a73b7
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 0x4a73d0
mov edx, 2
mov rcx, qword [rsp + 0x20]
call fcn.0040c7c0
cmp bpl, 2
jne 0x4a7419
mov byte [rsi + 0x18], 2
mov eax, r15d
and eax, 3
cmp eax, 1
jne 0x4a743a
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 0x4a740a
mov rdx, qword [rax + 0x10]
mov rcx, qword [rdi]
call fcn.0040c7c0
mov edx, 8
mov rcx, rdi
call fcn.0040c7c0
jmp 0x4a743a
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 0x4a744f
mov edx, 2
mov rcx, rbx
call fcn.0040c7c0
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.00411f40
jmp 0x4a7493
lea rax, str.library_std_src_syswindowsmod.rs
mov rcx, r8
mov rdx, r12
mov r8, rax
call fcn.00411b70
ud2