Function at 0x402ab8
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x54c
mov dword [esp + 0xc], 9
mov dword [esp + 8], str.softwaremicrosoftwindows_ntcurrentversionperflib
mov dword [esp + 4], str._s_03x
lea esi, [esp + 0x140]
mov dword [esp], esi
call sub.USER32.dll_wsprintfA
lea eax, [esp + 0x30]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0x20019
mov dword [esp + 8], 0
mov dword [esp + 4], esi
mov dword [esp], 0x80000002
call sub.ADVAPI32.DLL_RegOpenKeyExA
sub esp, 0x14
test eax, eax
je 0x402b44
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sub.ADVAPI32.DLL_RegCloseKey
push eax
mov dword [esp], 0x80000004
call sub.ADVAPI32.DLL_RegCloseKey
push edx
mov eax, 1
add esp, 0x54c
pop ebx
pop esi
pop edi
pop ebp
ret
lea eax, [esp + 0x38]
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], 0
lea edx, [esp + 0x34]
mov dword [esp + 0xc], edx
mov dword [esp + 8], 0
mov dword [esp + 4], str.Counters
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sub.ADVAPI32.DLL_RegQueryValueExA
sub esp, 0x18
test eax, eax
jne 0x402b18
mov ebp, dword [esp + 0x38]
mov dword [esp], ebp
call sub.msvcrt.dll_malloc
mov ebx, eax
test eax, eax
je 0x402b18
xor eax, eax
mov edi, ebx
mov ecx, ebp
rep stosb byte es:[edi], al
lea ecx, [esp + 0x38]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], ebx
lea eax, [esp + 0x34]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.Counters
mov eax, dword [esp + 0x30]
mov dword [esp], eax
call sub.ADVAPI32.DLL_RegQueryValueExA
sub esp, 0x18
test eax, eax
jne 0x402ce0
cmp byte [ebx], 0
je 0x402f75
mov dword [esp + 0x24], ebx
mov dword [esp + 0x2c], 0
mov ebp, dword [sym.imp.msvcrt.dll___mb_cur_max]
mov dword [esp + 0x28], ebx
nop
mov dword [esp + 4], str.process
mov edx, dword [esp + 0x24]
mov dword [esp], edx
call sub.KERNEL32.dll_lstrcmpiA
sub esp, 8
test eax, eax
jne 0x402cf0
mov ebx, dword [esp + 0x24]
sub ebx, 2
jmp 0x402c31
mov dword [esp + 4], 4
mov dword [esp], eax
call sub.msvcrt.dll__isctype
test eax, eax
je 0x402c50
dec ebx
movsx eax, byte [ebx]
cmp dword [ebp], 1
jne 0x402c1c
mov ecx, dword [sym.imp.msvcrt.dll__pctype]
mov edx, dword [ecx]
mov ax, word [edx + eax*2]
and eax, 4
movzx eax, ax
test eax, eax
jne 0x402c30
inc ebx
mov dword [esp + 4], ebx
mov dword [esp], esi
call sub.KERNEL32.dll_lstrcpyA
sub esp, 8
mov edx, dword [esp + 0x24]
mov dword [esp], edx
call sub.KERNEL32.dll_lstrlenA
push ebx
mov ecx, dword [esp + 0x24]
lea ecx, [ecx + eax + 1]
mov dword [esp + 0x24], ecx
cmp byte [ecx], 0
je 0x402d68
mov edx, dword [esp + 0x24]
cmp dword [esp + 0x28], edx
jae 0x402bf4
mov edi, edx
sub edi, 2
mov ebx, dword [sym.imp.msvcrt.dll___mb_cur_max]
jmp 0x402cb9
mov dword [esp + 4], 4
mov dword [esp], eax
call sub.msvcrt.dll__isctype
test eax, eax
je 0x402bf4
dec edi
movsx eax, byte [edi]
cmp dword [ebx], 1
jne 0x402ca0
mov ecx, dword [sym.imp.msvcrt.dll__pctype]
mov edx, dword [ecx]
mov ax, word [edx + eax*2]
and eax, 4
movzx eax, ax
jmp 0x402cb0
test ebx, ebx
je 0x402b18
mov dword [esp], ebx
call sub.msvcrt.dll_free
jmp 0x402b18
mov dword [esp + 4], str.id_process
mov edx, dword [esp + 0x24]
mov dword [esp], edx
call sub.KERNEL32.dll_lstrcmpiA
sub esp, 8
test eax, eax
jne 0x402c60
mov edi, dword [esp + 0x24]
sub edi, 2
mov ebx, dword [sym.imp.msvcrt.dll___mb_cur_max]
jmp 0x402d35
mov dword [esp + 4], 4
mov dword [esp], eax
call sub.msvcrt.dll__isctype
test eax, eax
je 0x402d54
dec edi
movsx eax, byte [edi]
cmp dword [ebx], 1
jne 0x402d20
mov ecx, dword [sym.imp.msvcrt.dll__pctype]
mov edx, dword [ecx]
mov ax, word [edx + eax*2]
and eax, 4
movzx eax, ax
jmp 0x402d30
inc edi
mov dword [esp], edi
call sub.msvcrt.dll_atol
mov dword [esp + 0x2c], eax
jmp 0x402c60
mov ebx, dword [esp + 0x28]
mov dword [esp], ebx
call sub.msvcrt.dll_free
mov dword [esp + 0x38], 0xc800
mov dword [esp], 0xc800
call sub.msvcrt.dll_malloc
mov ebx, eax
test eax, eax
je 0x402b18
mov ecx, 0xc800
xor eax, eax
mov edi, ebx
rep stosb byte es:[edi], al
xor ebp, ebp
nop
lea eax, [esp + 0x38]
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], ebx
lea edx, [esp + 0x34]
mov dword [esp + 0xc], edx
mov dword [esp + 8], 0
mov dword [esp + 4], esi
mov dword [esp], 0x80000004
call sub.ADVAPI32.DLL_RegQueryValueExA
sub esp, 0x18
test eax, eax
jne 0x402f40
mov ecx, dword [esp + 0x38]
test ecx, ecx
je 0x402cd8
cmp dword [ebx], 0x450050
jne 0x402ce0
cmp dword [ebx + 4], 0x460052
jne 0x402ce0
add ebx, dword [ebx + 0x18]
mov eax, dword [ebx + 8]
add eax, ebx
mov ecx, dword [ebx + 0x20]
test ecx, ecx
je 0x402e31
mov edx, dword [esp + 0x2c]
cmp dword [eax + 4], edx
je 0x402f82
xor edx, edx
mov esi, dword [esp + 0x2c]
jmp 0x402e29
cmp dword [eax + 4], esi
je 0x402f82
add eax, 0x28
inc edx
cmp edx, ecx
jne 0x402e20
xor ebp, ebp
mov ecx, dword [ebx + 0x28]
mov dword [esp + 0x24], ecx
add ebx, dword [ebx + 4]
test ecx, ecx
je 0x402f8a
xor esi, esi
lea edi, [esp + 0x3c]
jmp 0x402ec7
mov eax, dword [esp + 0x560]
lea edx, [eax + 4]
mov dword [esp + 4], edi
mov dword [esp], edx
call sub.KERNEL32.dll_lstrcpyA
sub esp, 8
add ebx, dword [ebx]
mov eax, dword [ebx + ebp]
mov edx, dword [esp + 0x560]
mov dword [edx], eax
add ebx, dword [ebx]
call sub.KERNEL32.dll_GetProcessHeap
mov dword [esp + 8], 0x10c
mov dword [esp + 4], 0
mov dword [esp], eax
call sub.KERNEL32.dll_HeapAlloc
sub esp, 0xc
mov ecx, dword [esp + 0x560]
mov dword [ecx + 0x108], eax
test eax, eax
je 0x402f91
mov dword [eax + 0x108], 0
inc esi
cmp dword [esp + 0x24], esi
je 0x402f8a
mov dword [esp + 0x560], eax
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x104
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], 0xffffffff
mov eax, dword [ebx + 0x10]
add eax, ebx
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0
call sub.KERNEL32.dll_WideCharToMultiByte
sub esp, 0x20
test eax, eax
jne 0x402e4d
mov dword [esp + 4], str.Unknown
mov edx, dword [esp + 0x560]
add edx, 4
mov dword [esp], edx
mov dword [esp + 0x20], edx
call sub.KERNEL32.dll_lstrcpyA
sub esp, 8
mov edx, dword [esp + 0x20]
jmp 0x402e57
cmp eax, 0xea
jne 0x402cd8
mov eax, dword [esp + 0x38]
add eax, 0x6400
mov dword [esp + 0x38], eax
mov dword [esp + 4], eax
mov dword [esp], ebx
call sub.msvcrt.dll_realloc
mov ebx, eax
mov ecx, dword [esp + 0x38]
mov edi, eax
mov eax, ebp
rep stosb byte es:[edi], al
jmp 0x402da0
mov dword [esp + 0x2c], 0
jmp 0x402d6c
mov ebp, dword [eax + 0x24]
jmp 0x402e33
xor eax, eax
jmp 0x402b37
mov eax, 1
jmp 0x402b37