Function at 0x4590af
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
mov eax, dword [0x4b5870]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 0x14]
push 0x4a7f5c
mov dword [ebp - 0x48], eax
call fcn.00406100
pop ecx
push eax
push 0
push 0x4a7f5c
mov ecx, ebx
call fcn.00407b00
mov dword [ebp - 0x44], eax
cmp eax, 0xffffffff
jne 0x4590fa
xor eax, eax
jmp 0x4592e9
and dword [ebp - 0xc], 0
xor ecx, ecx
push eax
push ecx
mov word [ebp - 0x1c], cx
lea ecx, [ebp - 0x1c]
push ebx
mov dword [ebp - 8], 7
call fcn.00403730
and dword [ebp - 0x24], 0
lea ecx, [ebp - 0x34]
xor eax, eax
mov dword [ebp - 0x20], 7
mov word [ebp - 0x34], ax
mov eax, dword [ebp - 0x44]
push 0xffffffffffffffff
inc eax
push eax
push ebx
call fcn.00403730
and dword [ebp - 0x3c], 0
lea eax, [ebp - 0x1c]
push 8
pop ebx
cmp dword [ebp - 8], ebx
push str.HKEY_CLASSES_ROOT
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x459218
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKCR
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x459218
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKEY_CURRENT_USER
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x459211
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKCU
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x459211
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKEY_LOCAL_MACHINE
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x45920a
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKLM
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
je 0x45920a
cmp dword [ebp - 8], ebx
lea eax, [ebp - 0x1c]
push str.HKEY_USERS
cmovae eax, dword [ebp - 0x1c]
push eax
call fcn.00472a84
pop ecx
pop ecx
test eax, eax
jne 0x459245
mov ecx, VariantInit
jmp 0x45921d
mov ecx, reloc.OLEAUT32.dll_SysReAllocString
jmp 0x45921d
mov ecx, SysReAllocStringLen
jmp 0x45921d
mov ecx, SysReAllocStringLen
cmp dword [ebp - 0x24], 0
jne 0x459228
mov dword [ebp - 0x3c], ecx
jmp 0x459241
cmp dword [ebp - 0x20], ebx
lea edx, [ebp - 0x3c]
lea eax, [ebp - 0x34]
cmovae eax, dword [ebp - 0x34]
push edx
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
mov ecx, dword [ebp - 0x3c]
test ecx, ecx
jne 0x45924c
xor ebx, ebx
jmp 0x4592cf
xor edx, edx
mov dword [ebp - 0x40], 1
mov ebx, edx
mov dword [ebp - 0x38], edx
cmp dword [esi + 0x10], edx
jne 0x459263
mov esi, edx
jmp 0x45926b
cmp dword [esi + 0x14], 8
jb 0x45926b
mov esi, dword [esi]
lea eax, [ebp - 0x38]
push eax
push edx
lea eax, [ebp - 0x40]
push eax
push edx
push esi
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x4592cf
push eax
mov eax, dword [ebp - 0x38]
mov ecx, edi
add eax, 0x10
push eax
call fcn.0040f590
add dword [ebp - 0x38], 2
cmp dword [edi + 0x14], 0x10
jb 0x45929e
mov eax, dword [edi]
jmp 0x4592a0
mov eax, edi
lea ecx, [ebp - 0x38]
push ecx
push eax
lea eax, [ebp - 0x40]
push eax
push 0
push esi
push dword [ebp - 0x3c]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x4592cf
push eax
push dword [ebp - 0x38]
mov ecx, edi
call fcn.0040f590
mov ecx, dword [ebp - 0x48]
xor ebx, ebx
mov eax, dword [ebp - 0x40]
inc ebx
mov dword [ecx], eax
push 0
push 1
lea ecx, [ebp - 0x34]
call fcn.00403940
push 0
push 1
lea ecx, [ebp - 0x1c]
call fcn.00403940
mov eax, ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0046f685
mov esp, ebp
pop ebp
ret