Trust logic for file attachments: registry value UseTrustedHandlersUserHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments
- Policy ID
- AM_EstimateFileHandlerRisk
- Scope
- User Configuration
- Supported on
- At least Windows XP Professional with SP2
- Source
- Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (version 1.0)
- Category
- Windows Components › Attachment Manager
Registry
UseTrustedHandlers
REG_DWORDUser- Enabled value
- Depends on the option value
- Element
- Determine risk by
| Item | Stored value |
|---|---|
| Preferring the file handler | 2 |
| Looking at the file handler and type | 3 |
| Preferring the file type | 1 |
Apply with .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments] ; Options (use only one) ; Preferring the file handler "UseTrustedHandlers"=dword:00000002 ; Looking at the file handler and type "UseTrustedHandlers"=dword:00000003 ; Preferring the file type "UseTrustedHandlers"=dword:00000001
CMD
:: Options (use only one) :: Preferring the file handler reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments" /v "UseTrustedHandlers" /t REG_DWORD /d 2 /f :: Looking at the file handler and type reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments" /v "UseTrustedHandlers" /t REG_DWORD /d 3 /f :: Preferring the file type reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments" /v "UseTrustedHandlers" /t REG_DWORD /d 1 /f
PowerShell
# Common: create the key New-Item -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments' -Force | Out-Null # Options (use only one) # Preferring the file handler New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments' -Name 'UseTrustedHandlers' -PropertyType DWord -Value 2 -Force | Out-Null # Looking at the file handler and type New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments' -Name 'UseTrustedHandlers' -PropertyType DWord -Value 3 -Force | Out-Null # Preferring the file type New-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Policies\Attachments' -Name 'UseTrustedHandlers' -PropertyType DWord -Value 1 -Force | Out-Null