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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x42c
mov eax, dword [0x107fa78]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
push esi
push eax
push dword [0x107fde4]
mov dword [ebp - 0x41c], ecx
mov ecx, dword [ebp + 0x14]
push 0x100bd00
lea eax, [ebp - 0x20c]
xor esi, esi
push 0x103
push eax
mov dword [ebp - 0x428], ecx
mov dword [ebp - 0x420], esi
mov dword [ebp - 0x42c], esi
call fcn.01034d76
add esp, 0x14
lea eax, [ebp - 0x420]
push eax
push 0x20019
push esi
lea eax, [ebp - 0x20c]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1071bd3
push ebx
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp - 0x424]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x418]
push eax
push esi
push 0x1004e6c
push dword [ebp - 0x420]
mov dword [ebp - 0x418], 1
mov dword [ebp - 0x424], 0x208
call edi
test eax, eax
mov ebx, 0x104
jne 0x1071abf
cmp dword [ebp - 0x418], 1
je 0x1071a33
cmp dword [ebp - 0x418], 2
jne 0x1071abf
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, si
jne 0x1071a3c
sub eax, edx
sar eax, 1
cmp eax, 5
jbe 0x1071abf
cmp dword [ebp - 0x418], 2
jne 0x1071a91
push ebx
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1071bc5
lea eax, [ebp - 0x414]
push eax
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01034c79
test eax, eax
jl 0x1071bc5
push 1
push ebx
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call fcn.010686d6
test eax, eax
jl 0x1071abf
lea eax, [ebp - 0x414]
push eax
call fcn.01056f43
test eax, eax
je 0x1071bc5
mov esi, dword [ebp + 0x10]
lea eax, [ebp - 0x424]
push eax
push dword [ebp - 0x41c]
lea eax, [ebp - 0x418]
push eax
push 0
push 0x100eb4c
push dword [ebp - 0x420]
mov dword [ebp - 0x424], esi
call edi
test eax, eax
je 0x1071af6
push 0x101176c
jmp 0x1071b47
cmp dword [ebp - 0x418], 2
jne 0x1071b39
push ebx
lea eax, [ebp - 0x414]
push eax
push dword [ebp - 0x41c]
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1071b32
lea eax, [ebp - 0x414]
push eax
mov eax, esi
shr eax, 1
push eax
push dword [ebp - 0x41c]
call fcn.01034c79
test eax, eax
jge 0x1071b55
push 0x1011768
jmp 0x1071b47
cmp dword [ebp - 0x418], 1
je 0x1071b55
push 0x1011764
shr esi, 1
push esi
push dword [ebp - 0x41c]
call fcn.01034c79
mov esi, dword [ebp + 0x18]
lea eax, [ebp - 0x424]
push eax
push dword [ebp - 0x428]
lea eax, [ebp - 0x418]
push eax
push 0
push 0
push dword [ebp - 0x420]
mov dword [ebp - 0x424], esi
call edi
test eax, eax
jne 0x1071ba7
cmp dword [ebp - 0x418], 1
jne 0x1071ba7
mov eax, dword [ebp - 0x428]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x1071b94
sub eax, edx
sar eax, 1
cmp eax, 2
jae 0x1071bbb
shr esi, 1
push 0x1001e8c
dec esi
push esi
push dword [ebp - 0x428]
call fcn.01034c79
mov dword [ebp - 0x42c], 1
push dword [ebp - 0x420]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop ebx
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x42c]
xor ecx, ebp
pop esi
call fcn.01047417
leave
ret 0x14