Function at 0x140049f90
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rcx
push rbx
push rdi
sub rsp, 0x108
mov r8b, 1
xor edx, edx
mov rdi, rcx
call fcn.140028870
mov rbx, rax
test rax, rax
jne 0x140049fbd
add rsp, 0x108
pop rdi
pop rbx
ret
cmp byte [rax + 0x23], 0
jne 0x140049fc7
mov rbx, qword [rax + 0x10]
movzx r10d, byte [rdi + 1]
mov qword [rsp + 0xf0], r12
cmp r10b, 1
jbe 0x14004a00c
mov rax, qword [rdi + 8]
mov rdx, qword [rax + 0x38]
test rdx, rdx
je 0x14004a00c
mov rdx, qword [rdx]
mov r8b, reloc.OLEAUT32.dll_SafeArrayGetElement
mov rcx, rbx
call fcn.140001280
mov r12, qword [rsp + 0xf0]
mov eax, 1
add rsp, 0x108
pop rdi
pop rbx
ret
mov qword [rsp + 0x100], rbp
mov qword [rsp + 0xe0], r14
xor r14d, r14d
mov qword [rsp + 0xd8], r15
cmp r10b, 2
jb 0x14004a11f
mov rcx, qword [rdi + 8]
mov rax, qword [rcx + 0x30]
test rax, rax
je 0x14004a11f
cmp qword [rax], r14
je 0x14004a11f
mov r8, qword [rcx + 0x30]
lea rbp, [rcx + 0x20]
mov r15, qword [r8 + 8]
movzx ecx, byte [r15 + 0x23]
test cl, cl
jne 0x14004a06a
mov rax, qword [r15 + 0x10]
movzx edx, byte [rax + 0x23]
jmp 0x14004a06d
movzx edx, cl
cmp dl, 3
jne 0x14004a0a5
movzx eax, byte [rbx + 0x23]
cmp al, 2
jne 0x14004a088
mov r12d, 1
mov eax, r12d
jmp 0x14004a5fb
test al, al
jne 0x14004a090
mov rbx, qword [rbx + 0x10]
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call fcn.14008eab0
mov r12d, eax
jmp 0x14004a5fb
test cl, cl
jne 0x14004a0b4
mov rax, qword [r15 + 0x10]
movzx r9d, byte [rax + 0x21]
jmp 0x14004a0b9
movzx r9d, byte [r15 + 0x21]
test r9b, 1
je 0x14004a0cf
mov rdx, r15
mov rcx, rbx
call fcn.14008ee50
jmp 0x14004a5fb
cmp qword [r8 + 0x18], r14
jne 0x14004a122
movzx eax, word [rbp + 2]
cmp word [r8 + 0x12], ax
jne 0x14004a122
cmp dl, 1
jne 0x14004a118
mov rax, qword [0x140100a58]
cmp byte [rax + 0x134], r14b
je 0x14004a108
test cl, cl
jne 0x14004a0ff
mov rax, qword [r15 + 0x10]
jmp 0x14004a102
mov rax, r15
test byte [rax + 0x21], 8
je 0x14004a118
mov rdx, r15
mov rcx, rbx
call fcn.14008e830
jmp 0x14004a5fb
mov qword [rsp + 0x38], r15
jmp 0x14004a12a
mov rbp, r14
mov qword [rsp + 0x38], r14
mov r15, r14
xor r9b, r9b
mov qword [rsp + 0xf8], rsi
xor r8b, r8b
mov byte [rsp + 0x130], r9b
mov byte [rsp + 0x128], r8b
mov r12d, 1
test rbp, rbp
je 0x14004a21b
movzx eax, byte [rbx + 0x23]
test al, al
jne 0x14004a167
mov rax, qword [rbx + 0x10]
movzx eax, byte [rax + 0x23]
cmp al, 2
je 0x14004a21b
mov rcx, qword [rbp + 0x10]
mov rdx, qword [rcx]
test rdx, rdx
je 0x14004a21b
nop
mov rax, qword [rcx + 8]
test r8b, r8b
je 0x14004a1db
cmp byte [rax + 0x23], r14b
jne 0x14004a193
mov rax, qword [rax + 0x10]
cmp rax, rbx
jne 0x14004a208
xor r8b, r8b
mov byte [rsp + 0x128], r8b
test r9b, r9b
je 0x14004a21b
test r8b, r8b
jne 0x14004a21b
xor r9d, r9d
or r8, 0xffffffffffffffff
xor edx, edx
mov rcx, rdi
call fcn.14006c300
cmp eax, r12d
jne 0x14004a467
mov edx, r12d
mov rcx, rdi
call fcn.140028590
lea rsi, [rax + 1]
jmp 0x14004a404
cmp byte [rax + 0x23], r14b
jne 0x14004a1e5
mov rax, qword [rax + 0x10]
cmp rax, rbx
jne 0x14004a208
movzx r9d, r12b
mov byte [rsp + 0x130], r12b
cmp rdx, qword [rbp + 8]
jne 0x14004a1ad
movzx r8d, r12b
mov byte [rsp + 0x128], r12b
mov rdx, qword [rcx + 0x18]
add rcx, 0x18
test rdx, rdx
jne 0x14004a180
jmp 0x14004a1a3
cmp r10b, 2
jb 0x14004a5d8
mov qword [rsp + 0xe8], r13
test r15, r15
je 0x14004a317
movzx ecx, byte [r15 + 0x23]
test ecx, ecx
je 0x14004a300
sub ecx, r12d
je 0x14004a293
sub ecx, r12d
je 0x14004a26c
cmp ecx, r12d
je 0x14004a30e
mov rdx, qword [r15 + 0x28]
xor ecx, ecx
call qword [r15 + reloc.OLEAUT32.dll_SafeArrayGetElement]
mov r14, rax
lea rsi, [rax + 1]
jmp 0x14004a3fc
xor edx, edx
lea rcx, [0x140107f00]
call fcn.1400050a0
mov r13d, 0xffffffff
cmp rax, r13
cmove rax, r14
mov r14, rax
lea rsi, [rax + 1]
jmp 0x14004a3fc
mov rcx, r15
call fcn.140001320
cmp dword [0x140105b28], r14d
jne 0x14004a2e7
cmp qword [r15 + 0x10], r14
jne 0x14004a2e7
mov rcx, qword [r15 + 0x28]
lea rdx, [rsp + 0x138]
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x14004a2d7
mov qword [0x140109880], r14
lea r14d, [rax - 1]
lea rsi, [r14 + 1]
jmp 0x14004a3fc
mov qword [0x140109880], r15
lea rsi, [r14 + 1]
jmp 0x14004a3fc
mov r14, qword [r15 + 0x10]
shr r14, 1
lea rsi, [r14 + 1]
jmp 0x14004a3fc
mov rcx, qword [r15 + 0x10]
xor edx, edx
call fcn.14008f570
mov r14, rax
lea rsi, [r14 + 1]
jmp 0x14004a3fc
mov rax, qword [rdi + 8]
movzx esi, word [rax + 0x22]
inc esi
test rbp, rbp
je 0x14004a3fc
mov rbp, qword [rbp + 0x10]
cmp qword [rbp], r14
je 0x14004a3fc
mov r13d, 0xffffffff
nop
mov rdi, qword [rbp + 8]
movzx eax, word [rbp + 0x12]
sub rsi, rax
movzx ecx, byte [rdi + 0x23]
test ecx, ecx
je 0x14004a3e0
sub ecx, r12d
je 0x14004a388
sub ecx, r12d
je 0x14004a371
cmp ecx, r12d
je 0x14004a3ca
mov rdx, qword [rdi + 0x28]
xor ecx, ecx
call qword [rdi + reloc.OLEAUT32.dll_SafeArrayGetElement]
jmp 0x14004a3eb
xor edx, edx
lea rcx, [0x140107f00]
call fcn.1400050a0
cmp rax, r13
cmove rax, r14
jmp 0x14004a3eb
mov rcx, rdi
call fcn.140001320
cmp dword [0x140105b28], r14d
jne 0x14004a3cf
cmp qword [rdi + 0x10], r14
jne 0x14004a3cf
mov rcx, qword [rdi + 0x28]
lea rdx, [rsp + 0x138]
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x14004a3c3
mov qword [0x140109880], r14
dec eax
jmp 0x14004a3eb
mov qword [0x140109880], rdi
mov rax, r14
jmp 0x14004a3eb
mov rax, qword [rdi + 0x10]
shr rax, 1
jmp 0x14004a3eb
mov rcx, qword [rdi + 0x10]
xor edx, edx
call fcn.14008f570
add rbp, 0x18
add rsi, rax
cmp qword [rbp], r14
jne 0x14004a340
mov r13, qword [rsp + 0xe8]
cmp rsi, 2
jb 0x14004a5d8
movzx edi, byte [rsp + 0x128]
test dil, dil
je 0x14004a46e
cmp byte [rbx + 0x23], 0
jne 0x14004a427
mov rax, qword [rbx + 0x10]
jmp 0x14004a42a
mov rax, rbx
cmp byte [rax + 0x23], 2
jne 0x14004a438
mov eax, dword [0x140107f28]
jmp 0x14004a43c
mov rax, qword [rax + 0x18]
mov rbp, qword [rsp + 0x120]
shr rax, 1
cmp rsi, rax
jbe 0x14004a526
lea r9, [rsp + 0x30]
mov r8, rsi
xor edx, edx
mov rcx, rbp
call fcn.14006c300
cmp eax, r12d
je 0x14004a476
xor eax, eax
jmp 0x14004a5f3
mov rbp, qword [rsp + 0x120]
cmp byte [rsp + 0x130], 0
je 0x14004a526
mov rdx, qword [0x140107158]
xor r9d, r9d
or r8, 0xffffffffffffffff
mov byte [rsp + 0x20], r12b
mov rcx, rbx
call fcn.14008f120
test eax, eax
je 0x14004a467
mov rax, qword [0x140100a58]
cmp byte [rax + 0x134], 0
je 0x14004a5d3
xor r8d, r8d
mov edx, r12d
mov rcx, rbx
call fcn.140001450
mov rdi, rax
cmp word [rax], 0
je 0x14004a5d3
mov rcx, rbx
call fcn.140017e10
mov rdx, rax
mov rcx, rdi
call fcn.1400178f0
mov rdx, rax
mov rcx, rbx
call fcn.140017dc0
cmp byte [rbx + 0x23], 0
jne 0x14004a4fa
mov rbx, qword [rbx + 0x10]
cmp byte [rbx + 0x23], 2
jne 0x14004a5cf
cmp qword [0x140107f18], 0
je 0x14004a5cf
lea rcx, [0x140107f00]
call fcn.140005440
mov eax, r12d
jmp 0x14004a5f3
test dil, dil
jne 0x14004a54a
lea r8, [rsi - 1]
mov byte [rsp + 0x20], r12b
xor r9d, r9d
xor edx, edx
mov rcx, rbx
call fcn.14008f120
cmp eax, r12d
jne 0x14004a467
xor r8d, r8d
mov edx, r12d
mov rcx, rbx
call fcn.140001450
mov r9, r15
mov r8d, r12d
mov rdx, rax
mov rcx, rbp
mov rdi, rax
call fcn.14006cca0
mov rdx, rax
test rax, rax
je 0x14004a467
mov rax, qword [0x140100a58]
sub rdx, rdi
sar rdx, 1
dec rdx
cmp byte [rax + 0x134], 0
je 0x14004a59c
mov rcx, rdi
call fcn.1400178f0
mov rdx, rax
mov rcx, rbx
call fcn.140017dc0
cmp byte [rbx + 0x23], 0
jne 0x14004a5ae
mov rbx, qword [rbx + 0x10]
cmp byte [rbx + 0x23], 2
jne 0x14004a5cf
cmp qword [0x140107f18], 0
je 0x14004a5cf
lea rcx, [0x140107f00]
call fcn.140005440
mov r12d, eax
jmp 0x14004a5f3
and byte [rbx + 0x21], 0x86
mov eax, r12d
jmp 0x14004a5f3
xor r9d, r9d
mov byte [rsp + 0x20], r12b
or r8, 0xffffffffffffffff
lea rdx, [0x1400cef3c]
mov rcx, rbx
call fcn.14008f120
mov rsi, qword [rsp + 0xf8]
mov rbp, qword [rsp + 0x100]
mov r14, qword [rsp + 0xe0]
mov r15, qword [rsp + 0xd8]
mov r12, qword [rsp + 0xf0]
add rsp, 0x108
pop rdi
pop rbx
ret