Function at 0x490460
Capabilities:
Query or enumerate registry value

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4aac4e
push eax
mov dword fs:[0], esp
sub esp, 0x450
mov ecx, 0x41
xor eax, eax
push ebx
push ebp
push esi
push edi
lea edi, [esp + 0x50]
push str.SYSTEMCurrentControlSetServicesusbhubEnum
rep stosd dword es:[edi], eax
mov ecx, 0x41
lea edi, [esp + 0x158]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x158]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x154]
push ecx
push 0x20019
push 0
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4907f0
lea eax, [esp + 0x10]
lea ecx, [esp + 0x50]
push eax
mov eax, dword [esp + 0x20]
lea edx, [esp + 0x18]
push ecx
push edx
push 0
push str.Count
push eax
mov dword [esp + 0x2c], 4
mov dword [esp + 0x28], 0x104
call ebx
test eax, eax
jne 0x4907e5
movsx edi, byte [esp + 0x50]
xor esi, esi
mov dword [esp + 0x38], edi
test edi, edi
mov dword [esp + 0x20], esi
jbe 0x4907e5
lea ecx, [esp + 0x10]
lea edx, [esp + 0x14]
push ecx
push 0
push edx
push 0
lea eax, [esp + 0x50]
push 0xa
push eax
push esi
mov dword [esp + 0x30], 1
call dword [sym.imp.MSVCRT.dll__itoa]
mov ecx, dword [esp + 0x38]
add esp, 0xc
push eax
push ecx
call ebx
test eax, eax
jne 0x4907d8
mov edx, dword [esp + 0x10]
mov ebp, dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, 0x41
lea edi, [esp + 0x258]
rep stosd dword es:[edi], eax
push edx
call ebp
mov ecx, dword [esp + 0x14]
mov esi, eax
mov edx, ecx
xor eax, eax
mov edi, esi
add esp, 4
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
lea edx, [esp + 0x40]
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
mov eax, dword [esp + 0x24]
push esi
push ecx
push 0
push 0xa
push edx
push eax
call dword [sym.imp.MSVCRT.dll__itoa]
mov ecx, dword [esp + 0x38]
add esp, 0xc
push eax
push ecx
call ebx
push esi
lea edx, [esp + 0x25c]
push str.SYSTEMCurrentControlSetEnum_s
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x258]
push eax
push 0x20019
push 0
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4907c6
mov ecx, dword [esp + 0x2c]
lea edx, [esp + 0x10]
push edx
push eax
lea eax, [esp + 0x1c]
push eax
push 0
push str.ParentIdPrefix
push ecx
call ebx
test eax, eax
jne 0x4907bb
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x28]
mov dword [esp + 0x468], 0
call sub.MFC42.DLL_CString::CString_1
push esi
lea ecx, [esp + 0x28]
mov byte [esp + 0x46c], 1
call fcn.004a5764
push 8
push 0x4df2e0
lea ecx, [esp + 0x2c]
call sub.MFC42.DLL_CString::Find_2
mov edx, dword [esp + 0x24]
mov ecx, dword [edx - 8]
sub ecx, eax
inc eax
push ecx
push eax
lea eax, [esp + 0x38]
lea ecx, [esp + 0x2c]
push eax
call sub.MFC42.DLL_CString::Mid
push eax
lea ecx, [esp + 0x2c]
mov byte [esp + 0x46c], 2
call fcn.004a5776
lea ecx, [esp + 0x30]
mov byte [esp + 0x468], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x28]
lea edx, [esp + 0x34]
push ecx
push 0x4e4b50
push edx
call sub.MFC42.DLL_operator_2
push 0x4e4b50
push eax
lea eax, [esp + 0x44]
mov byte [esp + 0x470], 3
push eax
call sub.MFC42.DLL_operator_1
push eax
lea ecx, [esp + 0x2c]
mov byte [esp + 0x46c], 4
call fcn.004a5776
lea ecx, [esp + 0x3c]
mov byte [esp + 0x468], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x34]
mov byte [esp + 0x468], 1
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x10]
push ecx
call ebp
mov ecx, dword [esp + 0x14]
mov ebp, eax
mov edx, ecx
xor eax, eax
mov edi, ebp
add esp, 4
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x18]
push ebp
push ecx
push 0
push str.ParentIdPrefix
push edx
call ebx
mov eax, dword [0x4e765c]
xor edi, edi
test eax, eax
jle 0x49078c
mov dword [esp + 0x18], 0x4e6ee4
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x28]
push ecx
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
add esp, 8
test eax, eax
jne 0x490779
mov ecx, dword [esp + 0x18]
mov eax, dword [0x4e765c]
inc edi
add ecx, 0x3c
cmp edi, eax
mov dword [esp + 0x18], ecx
jl 0x490749
jmp 0x49078c
lea eax, [edi + edi*2]
push ebp
lea edx, [eax + eax*4]
lea ecx, [edx*4 + 0x4e6ef0]
call fcn.004a5764
push ebp
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
lea ecx, [esp + 0x28]
mov byte [esp + 0x468], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x24]
mov dword [esp + 0x468], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x2c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
call dword [sym.imp.MSVCRT.dll_free]
mov edi, dword [esp + 0x3c]
mov esi, dword [esp + 0x24]
add esp, 4
inc esi
cmp esi, edi
mov dword [esp + 0x20], esi
jb 0x490529
mov ecx, dword [esp + 0x1c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [esp + 0x154]
push str.SYSTEMCurrentControlSetServicesusbhub20Enum
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
lea eax, [esp + 0x1c]
lea ecx, [esp + 0x154]
push eax
push 0x20019
push 0
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x490b54
lea edx, [esp + 0x10]
lea eax, [esp + 0x50]
push edx
mov edx, dword [esp + 0x20]
lea ecx, [esp + 0x18]
push eax
push ecx
push 0
push str.Count
push edx
mov dword [esp + 0x2c], 4
mov dword [esp + 0x28], 0x104
call ebx
test eax, eax
jne 0x490b49
movsx esi, byte [esp + 0x50]
xor ebp, ebp
mov dword [esp + 0x40], esi
test esi, esi
mov dword [esp + 0x28], ebp
jbe 0x490b49
lea eax, [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
push 0
push ecx
push 0
lea edx, [esp + 0x58]
push 0xa
push edx
push ebp
mov dword [esp + 0x30], 1
call dword [sym.imp.MSVCRT.dll__itoa]
add esp, 0xc
push eax
mov eax, dword [esp + 0x30]
push eax
call ebx
test eax, eax
jne 0x490b3c
mov ecx, 0x41
lea edi, [esp + 0x35c]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0x20]
mov dword [esp + 0x468], 5
call sub.MFC42.DLL_CString::CString_1
mov ecx, dword [esp + 0x10]
mov byte [esp + 0x468], 6
push ecx
call dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, dword [esp + 0x14]
mov esi, eax
mov edx, ecx
xor eax, eax
mov edi, esi
add esp, 4
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
lea edx, [esp + 0x48]
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
push esi
push ecx
push 0
push 0xa
push edx
push ebp
call dword [sym.imp.MSVCRT.dll__itoa]
add esp, 0xc
push eax
mov eax, dword [esp + 0x30]
push eax
call ebx
push esi
lea ecx, [esp + 0x1c]
call fcn.004a5764
push 8
push 0x4df2e0
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::Find_2
mov ecx, dword [esp + 0x18]
lea edx, [esp + 0x38]
mov ecx, dword [ecx - 8]
sub ecx, eax
inc eax
push ecx
push eax
push edx
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::Mid
push eax
lea ecx, [esp + 0x24]
mov byte [esp + 0x46c], 7
call fcn.004a5776
lea ecx, [esp + 0x38]
mov byte [esp + 0x468], 6
call sub.MFC42.DLL_CString::CString
lea eax, [esp + 0x20]
lea ecx, [esp + 0x3c]
push eax
push 0x4e4b50
push ecx
call sub.MFC42.DLL_operator_2
push 0x4e4b50
lea edx, [esp + 0x38]
push eax
push edx
mov byte [esp + 0x474], 8
call sub.MFC42.DLL_operator_1
mov byte [esp + 0x468], 9
push eax
lea ecx, [esp + 0x24]
call fcn.004a5776
lea ecx, [esp + 0x34]
mov byte [esp + 0x468], 8
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x3c]
mov byte [esp + 0x468], 6
call sub.MFC42.DLL_CString::CString
mov eax, dword [0x4e765c]
xor edi, edi
test eax, eax
jle 0x490a3e
mov dword [esp + 0x24], 0x4e6ee4
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
push ecx
mov eax, dword [eax]
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
add esp, 8
test eax, eax
jne 0x490a29
mov ecx, dword [esp + 0x24]
mov eax, dword [0x4e765c]
inc edi
add ecx, 0x3c
cmp edi, eax
mov dword [esp + 0x24], ecx
jl 0x4909f9
jmp 0x490a3e
lea eax, [edi + edi*2]
mov dword [esp + 0x30], edi
lea edx, [eax + eax*4]
mov dword [edx*4 + 0x4e6ef4], 1
push esi
lea eax, [esp + 0x360]
push str.SYSTEMCurrentControlSetEnum_s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea ecx, [esp + 0x2c]
lea edx, [esp + 0x35c]
push ecx
push 0x20019
push 0
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x490b09
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x18]
push 0
push ecx
push 0
push str.ParentIdPrefix
push edx
call ebx
test eax, eax
jne 0x490afe
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, dword [esp + 0x14]
mov ebp, eax
mov edx, ecx
xor eax, eax
mov edi, ebp
add esp, 4
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x18]
push ebp
push ecx
push 0
push str.ParentIdPrefix
push edx
call ebx
mov eax, dword [esp + 0x30]
push ebp
lea eax, [eax + eax*2]
lea eax, [eax + eax*4]
lea ecx, [eax*4 + 0x4e6ef0]
call fcn.004a5764
push ebp
call dword [sym.imp.MSVCRT.dll_free]
mov ebp, dword [esp + 0x2c]
add esp, 4
mov ecx, dword [esp + 0x2c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
lea ecx, [esp + 0x20]
mov byte [esp + 0x468], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x18]
mov dword [esp + 0x468], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov esi, dword [esp + 0x40]
inc ebp
cmp ebp, esi
mov dword [esp + 0x28], ebp
jb 0x490879
mov edx, dword [esp + 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x460]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x45c
ret