Open in the explorer

Trust logic for file attachments

Logique de confiance pour les pièces jointes

Type
User
GPO path
User Configuration › Policies › Administrative Templates › Windows Components › Attachment Manager FR: Configuration utilisateur › Stratégies › Modèles d'administration › Composants Windows › Gestionnaire de pièces jointes
Supported on
At least Windows XP Professional with SP2 FR: Au minimum Windows XP Professionnel avec SP2
ADMX file
AttachmentManager.admx
Internal name
AttachmentManager/AM_EstimateFileHandlerRisk

Explanation

This policy setting allows you to configure the logic that Windows uses to determine the risk for file attachments.

Preferring the file handler instructs Windows to use the file handler data over the file type data. For example, trust notepad.exe, but don't trust .txt files.

Preferring the file type instructs Windows to use the file type data over the file handler data. For example, trust .txt files, regardless of the file handler.

Using both the file handler and type data is the most restrictive option. Windows chooses the more restrictive recommendation which will cause users to see more trust prompts than choosing the other options.

If you enable this policy setting, you can choose the order in which Windows processes risk assessment data.

If you disable this policy setting, Windows uses its default trust logic, which prefers the file handler over the file type.

If you do not configure this policy setting, Windows uses its default trust logic, which prefers the file handler over the file type.

French text from Windows 11 26H2

Ce paramètre de stratégie vous permet de configurer la logique utilisée par Windows pour déterminer les risques que présentent des pièces jointes.

L’option Préférence au gestionnaire de fichier indique à Windows qu’il doit utiliser les données du gestionnaire de fichier plutôt que celles du type de fichier. Par exemple, faire confiance à notepad.exe, mais pas aux fichiers .txt.

Préférence au type de fichier indique à Windows qu’il doit utiliser les données du type de fichier plutôt que celles du gestionnaire de fichier. Par exemple, faire confiance aux fichiers .txt, sans tenir compte du gestionnaire de fichier.

L’utilisation conjointe du gestionnaire de fichier et des données de type est l’option la plus restrictive. Windows choisit la recommandation la plus restrictive qui entraîne l’affichage d’un nombre d’alertes plus important que les autres options.

Si vous activez ce paramètre de stratégie, vous pouvez choisir l’ordre dans lequel Windows traite les données d’évaluation des risques.

Si vous désactivez ce paramètre de stratégie, Windows utilise sa logique de confiance par défaut qui préfère le gestionnaire de fichier au type de fichier.

Si vous ne configurez pas ce paramètre de stratégie, Windows utilise sa logique de confiance par défaut qui préfère le gestionnaire de fichier au type de fichier.

Registry

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments
Value name
not defined in the ADMX

Enable / disable values: not 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.

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: AttachmentManager/AM_EstimateFileHandlerRisk
$k = 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Determine risk by
# Possible options:
#   Preferring the file handler = 2
#   Looking at the file handler and type = 3
#   Preferring the file type = 1
Set-ItemProperty -Path $k -Name 'UseTrustedHandlers' -Value 2 -Type DWord

Disable

# Disable: AttachmentManager/AM_EstimateFileHandlerRisk
# No value is written in the "Disabled" state (nothing defined in the ADMX)

Revert to "Not configured"

# Revert to "Not configured": AttachmentManager/AM_EstimateFileHandlerRisk
$k = 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments'
Remove-ItemProperty -Path $k -Name 'UseTrustedHandlers' -ErrorAction SilentlyContinue

Options (1)

LabelControlRegistry valueREG typeConstraints / details
Determine risk byDéterminer le risque parAM_TrustLogicSettingDrop-down listenumUseTrustedHandlersREG_DWORD
Default choice (UI): #0
LabelValue
Preferring the file handlerREG_DWORD = 2
Looking at the file handler and typeREG_DWORD = 3
Preferring the file typeREG_DWORD = 1

Availability