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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x445926
mov eax, dword fs:[0]
push eax
sub esp, 0x568
mov eax, dword [0x460554]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov dword [ebp - 0x560], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x55c], eax
xor eax, eax
mov word [ebp - 0x31c], ax
call fcn.004153de
mov ecx, eax
test ecx, ecx
je 0x410923
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x530], eax
push str.TypeLib_
lea ecx, [ebp - 0x530]
mov dword [ebp - 4], 0
call fcn.004020d0
test al, al
jne 0x410574
push str.TypeLib_
lea ecx, [ebp - 0x530]
call fcn.00403230
mov dword [ebp - 4], 1
test edi, edi
jne 0x410583
xor ecx, ecx
jmp 0x41059f
mov ecx, edi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x410590
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x530]
call fcn.00402b00
mov esi, dword [ebp - 0x530]
lea eax, [ebp - 0x534]
push eax
push 0x20019
push 0
push esi
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x410637
push str.Wow6432NodeTypeLib_
lea ecx, [ebp - 0x530]
call fcn.00403230
test edi, edi
jne 0x4105e8
xor ecx, ecx
jmp 0x4105ff
mov ecx, edi
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4105f0
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x530]
call fcn.00402b00
mov esi, dword [ebp - 0x530]
lea eax, [ebp - 0x534]
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
push eax
push 0x20019
push 0
push esi
push SysReAllocString
call edi
test eax, eax
je 0x41063d
jmp 0x4108bd
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 0x570]
mov dword [ebp - 0x54c], 0x80
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x548]
mov dword [ebp - 0x548], 0x40
push eax
lea eax, [ebp - 0x114]
mov dword [ebp - 0x554], 0
push eax
push 0
push dword [ebp - 0x534]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
jne 0x4108b5
lea eax, [ebp - 0x538]
push eax
push 0x20019
push 0
lea eax, [ebp - 0x114]
push eax
push dword [ebp - 0x534]
call edi
test eax, eax
jne 0x41086e
mov dword [ebp - 0x550], eax
lea eax, [ebp - 0x568]
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x544]
mov dword [ebp - 0x544], 0x40
push eax
lea eax, [ebp - 0x94]
push eax
push 0
push dword [ebp - 0x538]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
jne 0x410866
nop dword [eax + eax]
lea eax, [ebp - 0x540]
push eax
push 0x20019
push 0
lea eax, [ebp - 0x94]
push eax
push dword [ebp - 0x538]
call edi
test eax, eax
jne 0x41081f
lea eax, [ebp - 0x53c]
push eax
push 0x20019
push 0
push str.win32
push dword [ebp - 0x540]
call edi
test eax, eax
je 0x410767
lea eax, [ebp - 0x53c]
push eax
push 0x20019
push 0
push str.win64
push dword [ebp - 0x540]
call edi
test eax, eax
jne 0x410817
lea eax, [ebp - 0x54c]
mov dword [ebp - 0x54c], 0x105
push eax
lea eax, [ebp - 0x31c]
push eax
lea eax, [ebp - 0x558]
push eax
push 0
push 0
push dword [ebp - 0x53c]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x41080f
mov eax, dword [ebp - 0x558]
cmp eax, 1
je 0x4107aa
cmp eax, 2
jne 0x41080f
cmp eax, 2
jne 0x4107e7
push 0x104
lea eax, [ebp - 0x52c]
push eax
lea eax, [ebp - 0x31c]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x4107e7
lea eax, [ebp - 0x52c]
push eax
lea eax, [ebp - 0x31c]
push 0x104
push eax
call fcn.00435a1f
add esp, 0xc
push dword [ebp - 0x55c]
lea eax, [ebp - 0x31c]
push eax
push dword [ebp - 0x560]
call fcn.00410930
mov edi, eax
test edi, edi
jg 0x4108f8
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
push dword [ebp - 0x53c]
call ebx
push dword [ebp - 0x540]
call ebx
mov eax, dword [ebp - 0x550]
lea ecx, [ebp - 0x568]
push ecx
push 0
push 0
push 0
lea ecx, [ebp - 0x544]
mov dword [ebp - 0x544], 0x40
push ecx
lea ecx, [ebp - 0x94]
inc eax
push ecx
push eax
push dword [ebp - 0x538]
mov dword [ebp - 0x550], eax
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x410700
push dword [ebp - 0x538]
call ebx
mov eax, dword [ebp - 0x554]
lea ecx, [ebp - 0x570]
push ecx
push 0
push 0
push 0
lea ecx, [ebp - 0x548]
mov dword [ebp - 0x548], 0x40
push ecx
lea ecx, [ebp - 0x114]
inc eax
push ecx
push eax
push dword [ebp - 0x534]
mov dword [ebp - 0x554], eax
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x410692
push dword [ebp - 0x534]
call ebx
or eax, 0xffffffff
add esi, 0xfffffff0
mov dword [ebp - 4], eax
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x4108d8
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0042c635
mov esp, ebp
pop ebp
ret 0xc
push dword [ebp - 0x53c]
call ebx
mov dword [ebp - 4], 0xffffffff
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x41091f
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, edi
jmp 0x4108da
push 0x80004005
call fcn.004025f0
int3