Function at 0x10003e7f0
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x470
mov rax, qword [0x10004a110]
xor rax, rsp
mov qword [rsp + 0x460], rax
mov rsi, rcx
mov qword [rsp + 0x20], rcx
lea r9, [0x10001edf0]
lea rcx, [rsp + 0x40]
lea r8, [0x100022f98]
xor ebx, ebx
mov edx, 0x103
mov qword [rsp + 0x38], rbx
call fcn.10002e570
lea rdx, [rsp + 0x38]
mov r9d, 0x20019
mov qword [rsp + 0x20], rdx
lea rdx, [rsp + 0x40]
xor r8d, r8d
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x10003eb75
mov rcx, qword [rsp + 0x38]
lea rax, [rsp + 0x34]
lea ebp, [rbx + 1]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
lea r9, [rsp + 0x30]
lea rdx, [0x100022e48]
xor r8d, r8d
mov dword [rsp + 0x30], ebp
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x34], 0x208
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003e9b0
mov edx, dword [rsp + 0x30]
cmp edx, ebp
je 0x10003e8c8
cmp edx, 2
jne 0x10003e9b0
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x40]
repne scasw ax, word [rdi]
not rcx
sub rcx, rbp
cmp rcx, 5
jbe 0x10003e9b0
cmp edx, 2
jne 0x10003e960
mov edi, 0x104
lea rdx, [rsp + 0x250]
lea rcx, [rsp + 0x40]
mov r8d, edi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
cmp eax, ebx
je 0x10003eb6a
lea r8, [rsp + 0x250]
lea rax, [rsp + 0x40]
lea rcx, [rsp + 0x40]
sub r8, rax
mov edx, ebx
lea rax, [rdi + 0x7ffffefa]
cmp rax, rbx
je 0x10003e947
movzx eax, word [r8 + rcx]
cmp ax, bx
je 0x10003e947
mov word [rcx], ax
add rcx, 2
sub rdi, rbp
jne 0x10003e925
cmp rdi, rbx
jne 0x10003e955
sub rcx, 2
mov edx, 0x8007007a
cmp edx, ebx
mov word [rcx], bx
jl 0x10003eb6a
lea rax, [rsp + 0x40]
cmp rax, rbx
je 0x10003e981
lea rdx, [rsp + 0x250]
lea rcx, [rsp + 0x40]
mov r8d, ebp
call fcn.100045e8c
jmp 0x10003e986
mov eax, 0x80004003
cmp eax, ebx
jl 0x10003e9b0
lea rax, [rsp + 0x250]
cmp rax, rbx
je 0x10003e9a6
lea rcx, [rsp + 0x250]
call fcn.1000400f0
jmp 0x10003e9a8
mov eax, ebx
cmp eax, ebx
je 0x10003eb6a
lea rcx, [rsp + 0x34]
lea rax, [rsi + 0x3e8]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x28], rcx
mov rcx, qword [rsp + 0x38]
lea rdx, [0x100022fc0]
xor r8d, r8d
mov dword [rsp + 0x34], 0x14
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003eb6a
cmp dword [rsp + 0x30], ebp
jne 0x10003eb6a
lea rcx, [rsp + 0x34]
lea rax, [rsi + 0xc8]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x28], rcx
mov rcx, qword [rsp + 0x38]
lea rdx, [0x100022fe0]
xor r8d, r8d
mov dword [rsp + 0x34], 0x12c
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003eb6a
cmp dword [rsp + 0x30], ebp
jne 0x10003eb6a
mov rcx, qword [rsp + 0x38]
lea rax, [rsp + 0x34]
lea rdi, [rsi + 0x320]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x30]
lea rdx, [0x100001da8]
xor r8d, r8d
mov qword [rsp + 0x20], rdi
mov dword [rsp + 0x34], 0xc8
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003ea86
cmp dword [rsp + 0x30], ebp
je 0x10003eac2
lea rdx, [0x100001db4]
mov ecx, 0x64
sub rdx, rdi
lea rax, [rcx + 0x7fffff9a]
cmp rax, rbx
je 0x10003eab6
movzx eax, word [rdx + rdi]
cmp ax, bx
je 0x10003eab6
mov word [rdi], ax
add rdi, 2
sub rcx, rbp
jne 0x10003ea95
cmp rcx, rbx
jne 0x10003eabf
sub rdi, 2
mov word [rdi], bx
lea rcx, [rsp + 0x34]
lea rax, [rsi + 0x1f4]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x28], rcx
mov rcx, qword [rsp + 0x38]
lea rdx, [0x100023008]
xor r8d, r8d
mov dword [rsp + 0x34], 0x12c
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003eb6a
cmp dword [rsp + 0x30], ebp
jne 0x10003eb6a
mov rcx, qword [rsp + 0x38]
lea rax, [rsp + 0x34]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
lea rdx, [0x100023030]
xor r8d, r8d
mov dword [rsp + 0x34], 0x208
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x10003eb62
cmp dword [rsp + 0x30], ebp
jne 0x10003eb62
lea rdx, [0x1000204d8]
lea rcx, [rsp + 0x40]
call qword [sym.imp.msvcrt.dll__wcsicmp]
cmp eax, ebx
jne 0x10003eb62
mov dword [rsi + 0x3fc], ebx
jmp 0x10003eb68
mov dword [rsi + 0x3fc], ebp
mov ebx, ebp
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
mov rcx, qword [rsp + 0x460]
xor rcx, rsp
call fcn.1000475f0
lea r11, [rsp + 0x470]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret