Function at 0x40f200
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54de81
mov eax, dword fs:[0]
push eax
sub esp, 0x21c
mov eax, dword [0x5a2740]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x214], ecx
mov ecx, dword [ebp + 0x14]
mov ebx, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
xor esi, esi
mov dword [ebp - 0x21c], ecx
mov dword [ebp - 0x228], 0
cmp ecx, 1
jle 0x40f373
lea ecx, [ebp - 0x224]
push ecx
lea ecx, [ebp - 0x210]
push ecx
lea ecx, [ebp - 0x21c]
push ecx
push str.DeviceInstance
push edi
push eax
mov dword [ebp - 0x21c], 1
mov dword [ebp - 0x224], 0x100
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
test eax, eax
jne 0x40f470
mov ecx, dword [ebp - 0x214]
lea edx, [ebp - 0x210]
mov eax, dword [ecx]
push edx
call dword [eax + 0x18]
test eax, eax
je 0x40f470
push edi
lea ecx, [ebp - 0x214]
call fcn.00402f80
mov dword [ebp - 4], esi
push 0x7b
push dword [ebp - 0x214]
call fcn.00527af7
mov esi, eax
mov eax, dword [ebp - 0x214]
add esp, 8
test esi, esi
jne 0x40f2e3
or esi, 0xffffffff
jmp 0x40f2e7
sub esi, eax
sar esi, 1
mov ecx, dword [eax - 0xc]
cmp esi, 0xffffffff
je 0x40f349
lea edx, [ecx - 1]
test edx, edx
js 0x40f33f
cmp edx, ecx
jg 0x40f33f
cmp word [eax + edx*2], 0x7d
jne 0x40f349
push edx
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x214]
call fcn.00402d90
lea ecx, [esi + 1]
push ecx
push ebx
mov ecx, eax
mov byte [ebp - 4], 1
call fcn.0040a020
lea ecx, [ebp - 0x218]
call fcn.00401600
lea ecx, [ebp - 0x214]
call fcn.00401600
jmp 0x40f47c
push 0x80070057
call fcn.004017c0
lea edx, [eax - 0x10]
mov dword [ebp - 4], 0xffffffff
lea eax, [edx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40f470
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x40f470
lea ecx, [ebp - 0x220]
push ecx
push 0x20019
push 0
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40f464
or edi, 0xffffffff
jmp 0x40f3a0
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x210]
push eax
push esi
push dword [ebp - 0x220]
mov dword [ebp - 0x224], 0x100
call dword [sym.imp.SHLWAPI.dll_SHEnumKeyExW]
inc esi
test eax, eax
jne 0x40f464
mov eax, dword [ebp - 0x21c]
mov ecx, dword [ebp - 0x214]
inc eax
push eax
lea eax, [ebp - 0x210]
push eax
push dword [ebp - 0x220]
lea eax, [ebp - 0x218]
push eax
call fcn.0040f200
mov dword [ebp - 4], 2
mov eax, dword [ebp - 0x218]
cmp dword [eax - 0xc], 0
jne 0x40f42d
lea edx, [eax - 0x10]
mov dword [ebp - 4], 0xffffffff
lea eax, [edx + 0xc]
mov ecx, edi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40f3a0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x40f3a0
add eax, 0xfffffff0
push eax
call fcn.00402630
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x218]
add eax, 0x10
add edx, 0xfffffff0
mov dword [ebx], eax
add esp, 4
lea eax, [edx + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x40f47c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x40f47c
push dword [ebp - 0x220]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0x57e024
mov ecx, ebx
call fcn.00402f80
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005255c5
mov esp, ebp
pop ebp
ret 0x10