mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 05:35:40 +00:00
[SETUPAPI]
- Do not open registry keys with no access rights CORE-10587 svn path=/trunk/; revision=70145
This commit is contained in:
parent
d1f13dc28b
commit
154274318f
3 changed files with 6 additions and 6 deletions
|
@ -4719,7 +4719,7 @@ OpenHardwareProfileKey(
|
|||
rc = RegOpenKeyExW(HKLM,
|
||||
REGSTR_PATH_HWPROFILES,
|
||||
0,
|
||||
0,
|
||||
READ_CONTROL,
|
||||
&hHWProfilesKey);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
{
|
||||
|
@ -4909,7 +4909,7 @@ SetupDiOpenDeviceInfoW(
|
|||
list->HKLM,
|
||||
REGSTR_PATH_SYSTEMENUM,
|
||||
0, /* Options */
|
||||
0,
|
||||
READ_CONTROL,
|
||||
&hEnumKey);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
{
|
||||
|
@ -5697,7 +5697,7 @@ static HKEY SETUPDI_OpenDevKey(HKEY RootKey, struct DeviceInfo *devInfo, REGSAM
|
|||
HKEY enumKey, key = INVALID_HANDLE_VALUE;
|
||||
LONG l;
|
||||
|
||||
l = RegOpenKeyExW(RootKey, REGSTR_PATH_SYSTEMENUM, 0, 0, &enumKey);
|
||||
l = RegOpenKeyExW(RootKey, REGSTR_PATH_SYSTEMENUM, 0, READ_CONTROL, &enumKey);
|
||||
if (!l)
|
||||
{
|
||||
l = RegOpenKeyExW(enumKey, devInfo->instanceId, 0, samDesired, &key);
|
||||
|
@ -5752,7 +5752,7 @@ static HKEY SETUPDI_OpenDrvKey(HKEY RootKey, struct DeviceInfo *devInfo, REGSAM
|
|||
RootKey,
|
||||
REGSTR_PATH_CLASS_NT,
|
||||
0, /* Options */
|
||||
0,
|
||||
READ_CONTROL,
|
||||
&hEnumKey);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
{
|
||||
|
|
|
@ -1997,7 +1997,7 @@ static BOOL InstallOneService(
|
|||
list ? list->HKLM : HKEY_LOCAL_MACHINE,
|
||||
REGSTR_PATH_SERVICES,
|
||||
0,
|
||||
0,
|
||||
READ_CONTROL,
|
||||
&hServicesKey);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
{
|
||||
|
|
|
@ -155,7 +155,7 @@ SETUP_CreateInterfaceList(
|
|||
list->HKLM,
|
||||
REGSTR_PATH_SYSTEMENUM,
|
||||
0, /* Options */
|
||||
0,
|
||||
READ_CONTROL,
|
||||
&hEnumKey);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
goto cleanup;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue