Function at 0x100015e0
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x7c
mov esi, dword [ebp + 8]
mov edi, dword [sym.imp.advapi32.dll_RegOpenKeyExW]
lea eax, [esi + 1]
mov dword [ebp - 0x58], eax
lea eax, [ebp - 0x54]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 9
mov dword [esp + 8], 0
mov dword [esp + 4], str.HARDWAREDEVICEMAPScsi
mov dword [esp], 0x80000002
call edi
sub esp, 0x14
test eax, eax
jne 0x100017f8
mov dword [ebp + 8], esi
xor eax, eax
lea ebx, [ebp - 0x48]
lea esi, [esi]
nop
mov dword [esp + 0xc], 0xf
lea esi, [eax + 1]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x54]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumKeyW]
sub esp, 0x10
test eax, eax
jne 0x100017c0
lea eax, [ebp - 0x50]
mov dword [esp + 0xc], 9
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0
mov dword [esp + 4], ebx
mov eax, dword [ebp - 0x54]
mov dword [esp], eax
call edi
sub esp, 0x14
test eax, eax
je 0x10001690
mov eax, esi
jmp 0x10001638
lea eax, [ebp - 0x4c]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x28], 0
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegQueryInfoKeyW]
sub esp, 0x30
test eax, eax
jne 0x100017a0
mov edx, dword [ebp - 0x4c]
sub dword [ebp - 0x58], edx
mov eax, dword [ebp - 0x58]
test eax, eax
jg 0x1000168c
mov eax, dword [ebp - 0x54]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
sub esp, 4
lea eax, [ebp - 0x2a]
mov dword [esp + 0xc], 0xf
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x58]
neg eax
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumKeyW]
sub esp, 0x10
test eax, eax
jne 0x10001830
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
lea eax, [ebp - 0x36]
mov esi, dword [sym.imp.ucrtbase.dll_wcstol]
sub esp, 4
mov dword [esp + 8], 0xa
mov dword [esp + 4], 0
mov dword [esp], eax
call esi
mov dword [esp + 8], 0xa
mov ebx, eax
lea eax, [ebp - 0x18]
mov dword [esp + 4], 0
mov dword [esp], eax
shl ebx, 0x10
call esi
lea esp, [ebp - 0xc]
add eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
mov eax, esi
sub esp, 4
jmp 0x10001638
mov eax, dword [ebp - 0x54]
mov esi, dword [ebp + 8]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
mov eax, dword [ebp - 0x58]
sub esp, 4
test eax, eax
jle 0x1000171a
test byte [0x10003018], 2
jne 0x1000184a
lea esp, [ebp - 0xc]
mov eax, 0xffffffff
pop ebx
pop esi
pop edi
pop ebp
ret
test byte [0x10003018], 2
je 0x100017e6
call sym._wine_dbgstr_wn.constprop.0
mov dword [esp + 0xc], str.Could_not_open_HKLM_s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.ASPI_GetHCforController
mov dword [esp + 4], 0x10003018
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x100017e6
test byte [0x10003018], 2
jne 0x10001877
mov eax, dword [ebp - 0x50]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
sub esp, 4
jmp 0x100017e6
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], str.Invalid_controller__d__n
mov dword [esp + 8], str.ASPI_GetHCforController
mov dword [esp + 4], 0x10003018
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x100017e6
mov dword [esp + 0xc], str.Failed_to_enumerate_keys_n
mov dword [esp + 8], str.ASPI_GetHCforController
mov dword [esp + 4], 0x10003018
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x10001839