Function at 0x447600
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x318
push ebx
push edi
mov edi, dword [esp + 0x324]
xor ebx, ebx
cmp edi, ebx
jne 0x447620
pop edi
xor eax, eax
pop ebx
add esp, 0x318
ret
push ebp
push esi
push 2
push ebx
push ebx
xor ebp, ebp
push 0x4953f4
mov dword [esp + 0x28], ebp
call dword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsA]
mov esi, eax
cmp esi, 0xffffffff
je 0x447663
lea eax, [esp + 0x140]
push eax
push esi
mov dword [esp + 0x148], 0x11f
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInfoListDetailA]
test eax, eax
jne 0x447670
push esi
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
pop esi
pop ebp
pop edi
xor eax, eax
pop ebx
add esp, 0x318
ret
lea ecx, [esp + 0x24]
push ecx
push ebx
push esi
mov dword [esp + 0x30], 0x1c
mov dword [esp + 0x20], ebx
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
je 0x447805
mov ebp, dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceRegistryPropertyA]
mov eax, dword [esp + 0x38]
push ebx
push ebx
push 0xc8
lea edx, [esp + 0x26c]
push edx
push eax
call dword [sym.imp.SETUPAPI.dll_CM_Get_Device_ID_ExA]
test eax, eax
jne 0x44772f
lea ecx, [esp + 0x1c]
push ecx
push 4
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x2c]
push eax
push 0x15
lea ecx, [esp + 0x38]
push ecx
push esi
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x38], 4
mov dword [esp + 0x3c], ebx
call ebp
mov edx, dword [esp + 0x10]
cmp edx, dword [edi]
jne 0x44772f
lea eax, [esp + 0x1c]
push eax
push 4
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x2c]
push edx
push 0x1c
lea eax, [esp + 0x38]
push eax
push esi
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x38], 4
mov dword [esp + 0x3c], ebx
call ebp
mov eax, dword [esp + 0x10]
mov edx, dword [edi + 4]
mov ecx, eax
shr ecx, 0x10
cmp ecx, edx
jne 0x44772f
mov ecx, dword [edi + 8]
and eax, 0xffff
cmp eax, ecx
je 0x447765
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x24]
inc eax
push edx
push eax
push esi
mov dword [esp + 0x20], eax
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
jne 0x447697
mov ebp, dword [esp + 0x18]
push esi
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
pop esi
mov eax, ebp
pop ebp
pop edi
pop ebx
add esp, 0x318
ret
push 0x20019
push 1
push ebx
push 1
lea eax, [esp + 0x34]
push eax
push esi
call dword [sym.imp.SETUPAPI.dll_SetupDiOpenDevRegKey]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x4477f3
xor eax, eax
mov byte [esp + 0x40], bl
mov ecx, 0x3f
lea edi, [esp + 0x41]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x44]
push edx
stosb byte es:[edi], al
lea eax, [esp + 0x1c]
push eax
push ebx
push 0x47e124
push ebp
mov dword [esp + 0x2c], 1
mov dword [esp + 0x30], 0x100
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4477ea
mov edx, dword [esp + 0x330]
cmp edx, ebx
je 0x4477ea
lea eax, [esp + 0x40]
mov ecx, eax
sub edx, ecx
lea esp, [esp]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x4477e0
push ebp
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x447800
push str.GetDriverKeyfromBDF:_SetupDiOpenDevRegKey_function_fails_n
call fcn.0040aab0
add esp, 4
mov ebp, 1
push esi
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
pop esi
mov eax, ebp
pop ebp
pop edi
pop ebx
add esp, 0x318
ret