Function at 0x4805f0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x30
lea eax, [esp]
push esi
mov esi, ecx
mov ecx, dword [esp + 0x38]
push eax
push ecx
push DrawStatusTextA
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
jne 0x4808f5
mov ecx, dword [esp + 4]
lea edx, [esp + 8]
push ebx
mov ebx, dword [esp + 0x40]
push edx
push eax
lea eax, [esp + 0x24]
push eax
push 0
push ebx
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4808db
mov edx, dword [esp + 0xc]
push ebp
push edi
lea ebp, [edx + 3]
shr ebp, 2
lea edi, [ebp*4]
push edi
call fcn.004bd49b
mov edx, eax
mov ecx, edi
mov dword [esp + 0x48], edx
mov edi, edx
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
add esp, 4
and ecx, 3
lea edx, [esp + 0x24]
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x44]
lea eax, [esp + 0x14]
push eax
mov eax, dword [esp + 0x14]
push ecx
push edx
push 0
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4808cc
mov ecx, dword [esi + 0x9c]
shl ecx, 1
push ecx
call fcn.004bd49b
mov edx, dword [esi + 0x1c]
add esp, 4
mov ebx, eax
mov dword [esp + 0x48], 0
push 0
push 0
push 0x418
push edx
mov dword [esp + 0x30], ebx
call dword [sym.imp.USER32.dll_SendMessageA]
mov edi, eax
dec edi
test eax, eax
je 0x48071d
push edi
mov ecx, esi
call fcn.004c65ab
test ax, ax
je 0x480704
xor ecx, ecx
test ebp, ebp
jle 0x4806f1
mov edx, dword [esp + 0x44]
cmp word [edx], ax
je 0x4806f1
inc ecx
add edx, 4
cmp ecx, ebp
jl 0x4806e4
cmp ecx, ebp
jne 0x480704
mov ecx, dword [esp + 0x48]
mov word [ebx], ax
inc ecx
add ebx, 2
mov dword [esp + 0x48], ecx
mov ecx, dword [esi + 0x1c]
push 0
push edi
push 0x416
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
mov edx, edi
dec edi
test edx, edx
jne 0x4806cd
xor ebx, ebx
test ebp, ebp
jle 0x48082e
mov eax, dword [esp + 0x44]
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x18], eax
mov bp, word [eax]
mov eax, dword [eax]
shr eax, 0x10
je 0x480814
xor edi, edi
cmp bp, di
je 0x4807d6
mov ecx, esi
call fcn.00480360
test eax, eax
jle 0x480785
mov eax, ebp
and eax, 0xffff
xor ebp, ebp
mov dword [esp + 0x28], eax
jmp 0x48076a
mov eax, dword [esp + 0x28]
mov ecx, dword [esi + 0xbc]
cmp dword [ecx + ebp + 4], eax
je 0x480785
mov ecx, esi
inc edi
add ebp, 0x64
call fcn.00480360
cmp edi, eax
jl 0x480766
mov ecx, esi
call fcn.00480360
cmp edi, eax
jge 0x480814
mov edx, dword [esi + 0xbc]
lea eax, [edi + edi*4]
lea edi, [eax + eax*4]
mov eax, dword [esi + 0x1c]
shl edi, 2
add edx, edi
push edx
push ebx
push 0x415
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [esi + 0xc4]
test eax, eax
je 0x4807d3
mov ecx, dword [esi + 0xbc]
lea edx, [ecx + edi + 0x14]
mov ecx, esi
push edx
push ebx
call fcn.004c6ead
inc ebx
jmp 0x480814
mov edx, dword [esi + 0x1c]
xor eax, eax
mov dword [esp + 0x38], eax
lea ecx, [esp + 0x2c]
mov dword [esp + 0x3c], eax
mov eax, ebx
push ecx
push eax
push 0x415
push edx
mov dword [esp + 0x3c], edi
mov dword [esp + 0x40], edi
mov byte [esp + 0x44], 0
mov byte [esp + 0x45], 1
mov byte [esp + 0x46], 0
mov byte [esp + 0x47], 0
inc ebx
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
add eax, 4
dec ecx
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
jne 0x480733
mov eax, dword [esp + 0x48]
test eax, eax
jle 0x4808bf
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x48], ecx
mov ecx, esi
xor edi, edi
call fcn.00480360
test eax, eax
jle 0x48087b
xor ebp, ebp
mov ecx, dword [esp + 0x48]
mov edx, dword [esi + 0xbc]
xor eax, eax
mov ax, word [ecx]
mov ecx, dword [edx + ebp + 4]
cmp ecx, eax
je 0x48087b
mov ecx, esi
inc edi
add ebp, 0x64
call fcn.00480360
cmp edi, eax
jl 0x480855
mov ecx, esi
call fcn.00480360
cmp edi, eax
jge 0x4808a9
lea eax, [edi + edi*4]
mov ecx, ebx
inc ebx
lea edx, [eax + eax*4]
mov eax, dword [esi + 0xbc]
lea edx, [eax + edx*4]
mov eax, dword [esi + 0x1c]
push edx
push ecx
push 0x415
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x1c]
add ecx, 2
dec eax
mov dword [esp + 0x48], ecx
mov dword [esp + 0x1c], eax
jne 0x480846
mov ecx, dword [esp + 0x20]
push ecx
call fcn.004bd4c4
add esp, 4
mov edx, dword [esp + 0x44]
push edx
call fcn.004bd4c4
add esp, 4
pop edi
pop ebp
mov eax, dword [esp + 8]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, esi
call fcn.00481480
mov ecx, esi
call fcn.004817a0
pop ebx
pop esi
add esp, 0x30
ret 8