Function at 0x1004819
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
push esi
push edi
mov dword [ebp - 0xc], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
je 0x1004a10
cmp dword [ebp + 0xc], ebx
je 0x1004a10
cmp dword [ebp + 0x10], ebx
je 0x1004a10
cmp dword [ebp + 0x14], ebx
je 0x1004a10
mov esi, dword [ebp + 0x18]
cmp esi, ebx
je 0x1004a10
lea eax, [ebp - 4]
push eax
push ebx
push ebx
push ebx
push dword [ebp + 0x10]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
cmp edi, ebx
je 0x10048a9
cmp edi, 2
jne 0x1004a13
push ebx
push dword [ebp + 0x10]
call fcn.01009813
test eax, eax
jne 0x1004a13
push ebx
push ebx
push 0x1f6
call fcn.0100b4a7
push eax
call fcn.01009813
lea eax, [eax + eax + 2]
jmp 0x10048ac
mov eax, dword [ebp - 4]
mov ecx, eax
and ecx, 1
add eax, ecx
mov dword [ebp - 4], eax
add eax, 2
push eax
call fcn.010099e1
cmp eax, ebx
mov dword [ebp - 8], eax
jne 0x10048cd
push 0xe
jmp 0x1004a12
push eax
call fcn.01009a84
cmp eax, ebx
mov ecx, dword [ebp - 8]
je 0x10048e0
mov byte [ecx], bl
inc ecx
dec eax
jne 0x10048da
lea eax, [ebp - 4]
push eax
push dword [ebp - 8]
lea eax, [ebp - 0xc]
push eax
push 0xffff
push dword [ebp + 0x10]
push ebx
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegGetValueW]
mov edi, eax
cmp edi, ebx
je 0x100493e
cmp edi, 2
jne 0x1004a13
push ebx
push dword [ebp + 0x10]
call fcn.01009813
test eax, eax
jne 0x1004a13
mov eax, dword [ebp - 4]
shr eax, 1
push eax
push ebx
push 0x1f6
mov dword [ebp - 0xc], 1
call fcn.0100b4a7
push eax
push dword [ebp - 8]
call fcn.01009ee4
cmp dword [esi + 8], ebx
mov edi, dword [ebp + 0x14]
jne 0x1004977
test byte [edi + 0x4c], 4
je 0x1004977
push edi
push dword [ebp - 4]
push dword [ebp - 0xc]
push dword [ebp - 8]
call fcn.01003f67
cmp eax, 1
jne 0x1004963
inc dword [esi + 0x10]
cmp eax, ebx
jne 0x1004977
push 0x490
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1004a0c
xor eax, eax
inc eax
cmp dword [esi + 0xc], eax
jne 0x100498f
cmp dword [edi + 0x44], ebx
jne 0x100498c
cmp dword [edi + 0x54], ebx
jne 0x100498c
inc dword [esi + 0x10]
mov dword [esi + 0xc], ebx
cmp dword [esi], eax
jne 0x10049b0
push dword [ebp + 0xc]
push 0x1001830
push eax
push eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x20
push eax
call fcn.0100b19f
add esp, 0x14
mov dword [esi], ebx
cmp dword [edi + 0x44], ebx
jne 0x10049ba
cmp dword [edi + 0x54], ebx
je 0x10049bd
inc dword [esi + 0x10]
xor eax, eax
push 9
pop ecx
lea edi, [ebp - 0x30]
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 8]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 4]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 0x14]
cmp dword [eax + 0x24], 1
lea ecx, [eax + 0x30]
mov dword [ebp - 0x14], 0x1001824
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x18], 4
mov dword [ebp - 0x10], ecx
jne 0x1004a03
or dword [ebp - 0x1c], 0x20
lea eax, [ebp - 0x30]
push eax
call fcn.0100215d
xor edi, edi
jmp 0x1004a19
push 0x57
pop edi
push edi
call fcn.01002093
lea eax, [ebp - 8]
push eax
call fcn.01009f4b
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 0x14