Function at 0x1004fa0d
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x624
mov eax, dword [0x1020f334]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, edx
mov dword [ebp - 0x624], eax
mov eax, esi
push edi
mov edi, ecx
and eax, 0x200
xor ecx, ecx
mov dword [ebp - 0x610], edi
or eax, ecx
je 0x1004fb6a
push ecx
lea eax, [ebp - 0x60c]
mov dword [ebp - 0x60c], ecx
xor edx, edx
mov ecx, 0x101b0620
push eax
inc edx
call fcn.1002c218
xor ecx, ecx
test eax, eax
jne 0x1004fb6a
lea eax, [ebp - 0x614]
mov dword [ebp - 0x61c], ecx
push eax
lea eax, [ebp - 0x404]
push eax
lea eax, [ebp - 0x620]
push eax
push ecx
lea eax, [ebp - 0x618]
push eax
lea eax, [ebp - 0x204]
push eax
push ecx
jmp 0x1004fb34
and dword [ebp - 0x608], 0
cmp dword [ebp - 0x620], 1
jne 0x1004fb01
mov edx, dword [ebp - 0x618]
test edx, edx
je 0x1004fb01
cmp dword [ebx], edx
jbe 0x1004fb01
push edx
push dword [edi]
lea ecx, [ebp - 0x204]
call fcn.100116a5
test al, al
je 0x1004fb01
mov edi, dword [ebp - 0x614]
lea edx, [ebp - 0x608]
mov eax, dword [ebx]
push dword [ebp - 0x624]
shr edi, 1
add eax, edi
lea ecx, [eax*2 - 2]
call fcn.100052b7
test eax, eax
jns 0x1004fc18
mov edi, dword [ebp - 0x610]
mov eax, dword [ebp - 0x61c]
lea ecx, [ebp - 0x614]
push ecx
lea ecx, [ebp - 0x404]
inc eax
push ecx
lea ecx, [ebp - 0x620]
mov dword [ebp - 0x61c], eax
push ecx
push 0
lea ecx, [ebp - 0x618]
push ecx
lea ecx, [ebp - 0x204]
push ecx
push eax
push dword [ebp - 0x60c]
mov dword [ebp - 0x618], 0x100
mov dword [ebp - 0x614], 0x200
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
je 0x1004fa9f
push dword [ebp - 0x60c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor ecx, ecx
and esi, 0x400
or esi, ecx
je 0x1004fc7e
push 0x100
lea edx, [ebp - 0x604]
mov ecx, 0x101b0ae0
call fcn.1002d36f
lea edi, [ebp - 0x604]
xor edx, edx
lea ecx, [edi + 2]
mov ax, word [edi]
add edi, 2
cmp ax, dx
jne 0x1004fb98
sub edi, ecx
mov dword [ebp - 0x608], edx
sar edi, 1
je 0x1004fc7e
mov ecx, dword [ebx]
lea edx, [ebp - 0x608]
push dword [ebp - 0x624]
add ecx, edi
add ecx, ecx
call fcn.100052b7
test eax, eax
js 0x1004fc7e
lea esi, [edi + edi]
push esi
lea eax, [ebp - 0x604]
push eax
push dword [ebp - 0x608]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx]
add eax, eax
push eax
mov eax, dword [ebp - 0x610]
push dword [eax]
mov eax, dword [ebp - 0x608]
add eax, esi
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [ebp - 0x610]
add esp, 0x18
mov eax, dword [ebp - 0x608]
mov dword [ecx], eax
add dword [ebx], edi
jmp 0x1004fc7a
mov edx, dword [ebx]
lea esi, [edi*2 - 2]
mov ecx, dword [ebp - 0x608]
lea eax, [ebp - 0x404]
add edx, edi
push esi
push eax
lea edx, [edx*2 - 2]
call fcn.100115df
mov edx, dword [ebx]
mov ecx, dword [ebp - 0x610]
add edx, edx
push edx
push dword [ecx]
mov ecx, dword [ebp - 0x608]
lea ecx, [ecx + esi]
call fcn.100115df
mov eax, dword [ebp - 0x610]
add esp, 0x10
mov ecx, dword [ebp - 0x608]
push dword [ebp - 0x60c]
mov dword [eax], ecx
lea ecx, [edi - 1]
add dword [ebx], ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, 1
jmp 0x1004fc80
xor al, al
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100042bb
mov esp, ebp
pop ebp
ret