Function at 0x140002810
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
sub rsp, 0x120
mov ebx, edx
mov r8d, 0x100
xor edx, edx
mov rdi, rcx
call fcn.140021acb
test ebx, ebx
jne 0x1400028ff
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x100
call fcn.140021acb
mov r9, qword [0x140036ce8]
test r9, r9
je 0x14000286f
mov rax, 0xffffffffffffffff
nop dword [rax]
inc rax
cmp byte [r9 + rax], 0
jne 0x140002860
test rax, rax
jne 0x14000288e
mov rbx, qword [0x140036d20]
cmp word [rbx + 0x1e0], 3
jne 0x140002889
mov rbx, qword [rbx + 0x1e8]
jmp 0x14000288b
xor ebx, ebx
mov r9, rbx
lea r8, [0x140029100]
mov edx, 0x100
lea rcx, [rsp + 0x20]
call fcn.140001bb0
xor r8d, r8d
lea rcx, [rsp + 0x20]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov ebx, eax
test eax, eax
je 0x140002ae2
lea ecx, [rax + 1]
cmp ecx, 0x100
jae 0x140002ae2
xor edx, edx
mov r8d, 0x100
mov rcx, rdi
call fcn.140021acb
mov r8d, ebx
lea rcx, [rsp + 0x20]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov rbx, qword [rsp + 0x140]
add rsp, 0x120
pop rdi
ret
mov qword [rsp + 0x130], rsi
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
xor ebx, ebx
lea rcx, str.kernel32
mov rsi, rax
mov dword [rsp + 0x138], ebx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov rcx, rax
lea rdx, str.IsWow64Process
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x140002950
lea rdx, [rsp + 0x138]
mov rcx, rsi
call rax
test eax, eax
je 0x140002a13
cmp dword [rsp + 0x138], ebx
je 0x140002a13
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x100
call fcn.140021acb
mov rcx, qword [0x140036cd8]
test rcx, rcx
je 0x140002993
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rcx + rax], bl
jne 0x140002982
test rax, rax
jne 0x140002ada
mov rax, qword [0x140036d20]
cmp word [rax + 0x1d0], 3
jne 0x1400029ab
mov rbx, qword [rax + 0x1d8]
mov r9, rbx
lea r8, [0x140029100]
mov edx, 0x100
lea rcx, [rsp + 0x20]
call fcn.140001bb0
xor r8d, r8d
lea rcx, [rsp + 0x20]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov ebx, eax
test eax, eax
je 0x140002ada
lea ecx, [rax + 1]
cmp ecx, 0x100
jae 0x140002ada
xor edx, edx
mov r8d, 0x100
mov rcx, rdi
call fcn.140021acb
mov r8d, ebx
lea rcx, [rsp + 0x20]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
jmp 0x140002ada
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x100
call fcn.140021acb
mov rcx, qword [0x140036cd8]
test rcx, rcx
je 0x140002a45
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rcx + rax], bl
jne 0x140002a38
test rax, rax
jne 0x140002ab8
mov rax, qword [0x140036d20]
cmp word [rax + 0x1d0], 3
jne 0x140002a5d
mov rbx, qword [rax + 0x1d8]
mov r9, rbx
lea r8, [0x140029100]
mov edx, 0x100
lea rcx, [rsp + 0x20]
call fcn.140001bb0
xor r8d, r8d
lea rcx, [rsp + 0x20]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov ebx, eax
test eax, eax
je 0x140002ab8
lea ecx, [rax + 1]
cmp ecx, 0x100
jae 0x140002ab8
xor edx, edx
mov r8d, 0x100
mov rcx, rdi
call fcn.140021acb
mov r8d, ebx
lea rcx, [rsp + 0x20]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
lea rdx, str.syswow64
mov rcx, rdi
call qword [sym.imp.VCRUNTIME140.dll_strstr]
test rax, rax
je 0x140002ada
movabs rcx, 0x32336d6574737973
mov qword [rax], rcx
mov rsi, qword [rsp + 0x130]
mov rbx, qword [rsp + 0x140]
add rsp, 0x120
pop rdi
ret