Open in the explorer

Specify threats upon which default action should not be taken when detected

Spécifier les menaces selon lesquelles aucune action par défaut ne doit être entreprise lors de la détection

Type
Computer
GPO path
Computer Configuration › Policies › Administrative Templates › Windows Components › Microsoft Defender Antivirus › Threats FR: Configuration ordinateur › Stratégies › Modèles d'administration › Composants Windows › Antivirus Microsoft Defender › Menaces
Supported on
At least Windows Server 2012, Windows 8 or Windows RT FR: Au minimum Windows Server 2012, Windows 8 ou Windows RT
ADMX file
WindowsDefender.admx
Internal name
WindowsDefender/Threats_ThreatIdDefaultAction

Explanation

This policy setting customize which remediation action will be taken for each listed Threat ID when it is detected during a scan. Threats should be added under the Options for this setting. Each entry must be listed as a name value pair. The name defines a valid Threat ID, while the value contains the action ID for the remediation action that should be taken.

Valid remediation action values are:
2 = Quarantine
3 = Remove
6 = Ignore

French text from Windows 11 26H2

Ce paramètre de stratégie permet de personnaliser l’action de mise à jour qui est entreprise pour chaque ID de menace répertorié détecté au cours d’une analyse. Les menaces doivent être ajoutées sous Options pour ce paramètre. Chaque entrée doit être répertoriée en tant que paire nom/valeur. Le nom définit un ID de menace valide, alors que la valeur contient l’ID de l’action de mise à jour qui doit être entreprise.

Les valeurs de l’action de mise à jour valides sont les suivantes :
2 = Mettre en quarantaine
3 = Supprimer
6 = Ignorer

Registry

HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows Defender\Threats
Value name
Threats_ThreatIdDefaultAction
StateValue written
Enablednot defined in the ADMX (see the options below)
Disablednot defined in the ADMX (see the options below)

PowerShell

PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.

The ADMX does not specify the value written when enabled; the GPO editor usually writes REG_DWORD 1 (enabled) / 0 (disabled). The commands below use 1/0 as an assumption.

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: WindowsDefender/Threats_ThreatIdDefaultAction
$k = 'HKLM:\Software\Policies\Microsoft\Windows Defender\Threats'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# The ADMX does not specify the value written; the GPO editor usually writes REG_DWORD 1 (enabled) / 0 (disabled)
Set-ItemProperty -Path $k -Name 'Threats_ThreatIdDefaultAction' -Value 1 -Type DWord  # assumed value (not defined in the ADMX)
$k = 'HKLM:\Software\Policies\Microsoft\Windows Defender\Threats\ThreatIdDefaultAction'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Specify threats upon which default action should not be taken when detected
$items = @{
    '<name1>' = '<value1>'
    '<name2>' = '<value2>'
}  # Replace the values with your own
$items.GetEnumerator() | ForEach-Object { Set-ItemProperty -Path $k -Name $_.Key -Value $_.Value -Type String }

Disable

# Disable: WindowsDefender/Threats_ThreatIdDefaultAction
$k = 'HKLM:\Software\Policies\Microsoft\Windows Defender\Threats'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# The ADMX does not specify the value written; the GPO editor usually writes REG_DWORD 1 (enabled) / 0 (disabled)
Set-ItemProperty -Path $k -Name 'Threats_ThreatIdDefaultAction' -Value 0 -Type DWord  # assumed value (not defined in the ADMX)

Revert to "Not configured"

# Revert to "Not configured": WindowsDefender/Threats_ThreatIdDefaultAction
$k = 'HKLM:\Software\Policies\Microsoft\Windows Defender\Threats'
Remove-ItemProperty -Path $k -Name 'Threats_ThreatIdDefaultAction' -ErrorAction SilentlyContinue
$k = 'HKLM:\Software\Policies\Microsoft\Windows Defender\Threats\ThreatIdDefaultAction'
Remove-Item -Path $k -Recurse -Force -ErrorAction SilentlyContinue

Options (1)

LabelControlRegistry valueREG typeConstraints / details
Specify threats upon which default action should not be taken when detectedSpécifier les menaces selon lesquelles aucune action par défaut ne doit être entreprise lors de la détectionThreats_ThreatIdDefaultActionListList (table)listSoftware\Policies\Microsoft\Windows Defender\Threats\ThreatIdDefaultActionName = value pairs · additiveREG_SZ (values under the key)

Availability