Function at 0x140001000
Capabilities:
Query environment variable
Set environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x88
movaps xmmword [rsp + 0x70], xmm6
mov qword [rsp + 0x58], rdx
mov ebp, ecx
mov rax, qword [0x140040010]
xor rax, rsp
mov qword [rsp + 0x68], rax
lea rcx, [0x14003a820]
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x1400010d5
mov esi, eax
mov ecx, eax
add rcx, rcx
call qword [sym.imp.mozglue.dll_moz_xmalloc]
mov rbx, rax
mov edi, esi
add edi, 0xffffffff
lea rcx, [0x14003a820]
mov rdx, rax
mov r8d, esi
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp edi, eax
jne 0x1400010c7
mov rcx, rbx
xor edx, edx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1400010c7
mov edi, eax
mov ecx, eax
add rcx, rcx
call qword [sym.imp.mozglue.dll_moz_xmalloc]
mov rsi, rax
mov rcx, rbx
mov rdx, rax
mov r8d, edi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1400010b9
lea rcx, [0x14003a820]
mov rdx, rsi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
test rsi, rsi
je 0x1400010c7
mov rcx, rsi
call qword [sym.imp.mozglue.dll_free]
test rbx, rbx
je 0x1400010d5
mov rcx, rbx
call qword [sym.imp.mozglue.dll_free]
lea rcx, [0x14003a9be]
call qword [sym.imp.KERNEL32.dll_SetDllDirectoryW]
lea eax, [rbp + 1]
cdqe
mov ecx, 8
mul rcx
mov rsi, 0xffffffffffffffff
cmovno rsi, rax
mov rcx, rsi
call qword [sym.imp.mozglue.dll_moz_xmalloc]
mov r14d, 0x7f
test rax, rax
je 0x1400012a0
mov rbx, rax
mov qword [rsp + 0x50], rsi
mov qword [rsp + 0x48], rbp
test ebp, ebp
jle 0x1400011a5
mov r15d, dword [rsp + 0x48]
xor r14d, r14d
mov r13, qword [sym.imp.mozglue.dll_moz_xmalloc]
xorps xmm6, xmm6
mov r12, qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov rax, qword [rsp + 0x58]
mov rsi, qword [rax + r14*8]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcslen]
mov rdi, rax
lea rcx, [rax + rax*2]
add rcx, 2
call r13
test rax, rax
je 0x14000124c
mov rbp, rax
lea rax, [rdi + rdi*2]
add eax, 1
movups xmmword [rsp + 0x30], xmm6
mov qword [rsp + 0x20], rbp
mov dword [rsp + 0x28], eax
mov ecx, 0xfde9
xor edx, edx
mov r8, rsi
mov r9d, edi
call r12
cdqe
mov byte [rbp + rax], 0
mov qword [rbx + r14*8], rbp
add r14, 1
cmp r15, r14
jne 0x140001140
mov rbp, qword [rsp + 0x48]
movsxd rsi, ebp
mov qword [rbx + rsi*8], 0
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.mozglue.dll_moz_xmalloc]
test rax, rax
je 0x14000125f
mov rdi, rax
test ebp, ebp
jle 0x1400011e2
mov r8d, ebp
shl r8, 3
mov rcx, rdi
mov rdx, rbx
call sub.VCRUNTIME140.dll_memcpy
mov qword [rsp + 0x60], 0
lea rcx, [rsp + 0x60]
call sub.xul.dll_XRE_GetBootstrap
cmp qword [rsp + 0x60], 0
jne 0x1400012c9
mov qword [rsp + 0x60], 0
mov r14d, 2
mov rcx, rbx
call qword [sym.imp.mozglue.dll_free]
test ebp, ebp
je 0x140001247
mov rbx, qword [sym.imp.mozglue.dll_free]
jmp 0x140001235
test rsi, rsi
je 0x140001247
mov rcx, qword [rdi + rsi*8 - 8]
add rsi, 0xffffffffffffffff
test rcx, rcx
je 0x140001230
call rbx
jmp 0x140001230
mov rcx, rdi
jmp 0x14000129a
mov eax, r14d
mov qword [rbx + rax*8], 0
mov r14d, 0x7f
jmp 0x1400012a0
test ebp, ebp
mov r14d, 0x7f
je 0x140001297
mov rdi, qword [sym.imp.mozglue.dll_free]
jmp 0x140001285
test rsi, rsi
je 0x140001297
mov rcx, qword [rbx + rsi*8 - 8]
add rsi, 0xffffffffffffffff
test rcx, rcx
je 0x140001280
call rdi
jmp 0x140001280
mov rcx, rbx
call qword [sym.imp.mozglue.dll_free]
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.140036e40
mov eax, r14d
movaps xmm6, xmmword [rsp + 0x70]
add rsp, 0x88
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov ecx, 1
call qword [sym.imp.mozglue.dll_void___cdecl_DllBlocklist_Initialize_unsigned_int_]
mov rcx, qword [rsp + 0x60]
mov edx, ebp
mov r8, rbx
call fcn.140001310
mov r14d, eax
mov rcx, qword [rsp + 0x60]
mov qword [rsp + 0x60], 0
test rcx, rcx
je 0x140001210
mov rax, qword [rcx]
call qword [rax + 8]
jmp 0x140001210