Prevent installation of devices not described by other policy settings
Empêcher l’installation de périphériques non décrits par d’autres paramètres de stratégie
Explanation
This policy setting allows you to prevent the installation of devices that are not specifically described by any other policy setting.
NOTE: This policy setting has been replaced by the "Apply layered order of evaluation for Allow and Prevent device installation policies across all device match criteria" policy setting to provide more granular control. It is recommended that you use the "Apply layered order of evaluation for Allow and Prevent device installation policies across all device match criteria" policy setting instead of this policy setting.
If you enable this policy setting, Windows is prevented from installing or updating the driver package for any device that is not described by either the "Allow installation of devices that match any of these device IDs", the "Allow installation of devices for these device classes", or the "Allow installation of devices that match any of these device instance IDs" policy setting.
If you disable or do not configure this policy setting, Windows is allowed to install or update the driver package for any device that is not described by the "Prevent installation of devices that match any of these device IDs", "Prevent installation of devices for these device classes" policy setting, "Prevent installation of devices that match any of these device instance IDs", or "Prevent installation of removable devices" policy setting.
Ce paramètre de stratégie vous permet d’empêcher l’installation de périphériques qui ne sont spécifiquement décrits par aucun autre paramètre de stratégie.
REMARQUE : ce paramètre de stratégie a été remplacé par le paramètre de stratégie « Appliquer un ordre d’évaluation par couches pour les stratégies Autoriser et Empêcher l’installation de périphériques sur tous les critères de correspondance des périphériques » afin de fournir un contrôle plus précis. Il est recommandé d’utiliser le paramètre de stratégie « Appliquer un ordre d’évaluation par couches pour les stratégies Autoriser et Empêcher l’installation de périphériques sur tous les critères de correspondance des périphériques » plutôt que ce paramètre de stratégie.
Si vous activez ce paramètre de stratégie, Windows ne peut pas installer ou mettre à jour le package de pilotes pour tout périphérique qui n’est pas décrit par les paramètres de stratégie « Autoriser l’installation de périphériques correspondant à l’un de ces ID de périphériques », « Autoriser l’installation de périphériques pour ces classes de périphériques », ou « Autoriser l’installation de périphériques correspondant à l’un de ces ID de périphériques ».
Si vous désactivez ou ne configurez pas ce paramètre de stratégie, Windows est autorisé à installer ou à mettre à jour le package de pilotes pour tout périphérique non décrit par les paramètres de stratégies « Empêcher l’installation de périphériques correspondant à l’un de ces ID de périphériques », « Empêcher l’installation de périphériques pour ces classes de périphériques », « Empêcher l’installation de périphériques correspondant à l’un de ces ID de périphériques » ou « Empêcher l’installation de périphériques amovibles ».
Registry
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\DeviceInstall\Restrictions- Value name
DenyUnspecified
| State | Value written |
|---|---|
| Enabled | REG_DWORD = 1 |
| Disabled | REG_DWORD = 0 |
PowerShell
PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.
Writing directly to the registry bypasses Group Policy: if a GPO manages this value, it will be rewritten at the next gpupdate; otherwise the value stays in place (the "tattooing" effect). Prefer a GPO or, locally, LGPO.exe. Run PowerShell as administrator for HKLM. Some policies need a restart or gpupdate /force.
Enable
# Enable: DeviceInstallation/DeviceInstall_Unspecified_Deny
$k = 'HKLM:\Software\Policies\Microsoft\Windows\DeviceInstall\Restrictions'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DenyUnspecified' -Value 1 -Type DWordDisable
# Disable: DeviceInstallation/DeviceInstall_Unspecified_Deny
$k = 'HKLM:\Software\Policies\Microsoft\Windows\DeviceInstall\Restrictions'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DenyUnspecified' -Value 0 -Type DWordRevert to "Not configured"
# Revert to "Not configured": DeviceInstallation/DeviceInstall_Unspecified_Deny
$k = 'HKLM:\Software\Policies\Microsoft\Windows\DeviceInstall\Restrictions'
Remove-ItemProperty -Path $k -Name 'DenyUnspecified' -ErrorAction SilentlyContinue