Function at 0x485690
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0xc
mov edi, dword [esp + 0x24]
mov ebx, dword [esp + 0x20]
lea ebp, [esp + 8]
push ebp
push 0
push 0
push 2
push edi
push 0
push ebx
call dword [sym.imp.ADVAPI32.dll_RegGetValueW]
test eax, eax
je 0x485721
cmp dword [esp + 0x2c], 0
je 0x4858d5
test edi, edi
mov ebp, str._default_
cmovne ebp, edi
push ebp
call sym._wcslen
add esp, 4
test eax, eax
je 0x4857b4
mov esi, eax
sub esp, 0x20
xorps xmm0, xmm0
movups xmmword [esp + 0x10], xmm0
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebp
mov dword [esp + 4], 0
mov dword [esp], 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov dword [esp + 4], eax
inc eax
mov dword [esp], eax
jne 0x4857f7
mov edi, dword [0x5052b0]
jmp 0x485805
push dword [esp + 8]
call sym._malloc
add esp, 4
mov esi, eax
push ebp
push eax
push 0
push 2
push edi
push 0
push ebx
call dword [sym.imp.ADVAPI32.dll_RegGetValueW]
test eax, eax
sete bl
je 0x4857d2
cmp dword [esp + 0x2c], 0
je 0x4858c6
test edi, edi
mov ebp, str._default_
cmovne ebp, edi
push ebp
call sym._wcslen
add esp, 4
test eax, eax
je 0x48584e
sub esp, 0x20
xorps xmm0, xmm0
movups xmmword [esp + 0x10], xmm0
mov dword [esp + 0x20], eax
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebp
mov dword [esp + 4], 0
mov dword [esp], 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov ecx, eax
inc eax
mov dword [esp + 4], eax
jne 0x485874
mov edi, dword [0x5052b0]
jmp 0x485886
push dword [0x5052b0]
push str.RegGetValueW__s__NULL__RRF_RT_REG_SZ__failed
push dword [esp + 0x34]
call dbg.ffStrbufAppendF
add esp, 0xc
xor ebx, ebx
jmp 0x4858d7
mov edi, dword [esp + 0x28]
test esi, esi
je 0x485867
push esi
call sym._wcslen
add esp, 4
push esi
push eax
push edi
call dbg.ffStrbufSetNWS
add esp, 0xc
jmp 0x4858ca
push eax
call sym._malloc
add esp, 4
mov edi, eax
mov byte [eax], 0
push 0
push 0
mov ebx, dword [esp + 0xc]
push ebx
push edi
push esi
push ebp
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov byte [edi + ebx], 0
push edi
push str.RegGetValueW__s__NULL__RRF_RT_REG_SZ__failed
push dword [esp + 0x34]
call dbg.ffStrbufAppendF
add esp, 0xc
cmp dword [esp], 0
je 0x4858d5
push edi
call sym._free
add esp, 4
xor ebx, ebx
jmp 0x4858d7
push dword [0x5052b0]
push str.RegGetValueW__s__result__RRF_RT_REG_SZ__failed
push dword [esp + 0x34]
call dbg.ffStrbufAppendF
add esp, 0xc
jmp 0x4858c6
cmp dword [edi], 0
je 0x4858e1
mov eax, dword [edi + 8]
mov byte [eax], 0
jmp 0x4858e9
push eax
mov edi, ecx
call sym._malloc
mov ecx, edi
add esp, 4
mov edi, eax
mov byte [eax], 0
mov eax, dword [esp]
push 0
push 0
push ecx
push edi
push eax
push ebp
push 0
push 0xfde9
mov ebp, ecx
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov byte [edi + ebp], 0
push edi
push str.RegGetValueW__s__result__RRF_RT_REG_SZ__failed
push dword [esp + 0x34]
call dbg.ffStrbufAppendF
add esp, 0xc
cmp dword [esp + 4], 0
je 0x4858c6
push edi
call sym._free
add esp, 4
test esi, esi
je 0x4858d5
push esi
call sym._free
add esp, 4
jmp 0x4858d7
xor ebx, ebx
mov eax, ebx
add esp, 0xc
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [0x5052b0]
mov dword [edi + 8], eax
mov dword [edi + 4], 0
mov bl, 1
jmp 0x4858d7