Unsafe Location #11
Cette stratégie n'a pas de traduction française dans les modèles de l'éditeur ; le texte original est en anglais.
Explication
This policy setting allows you to specify a location containing files that should always open in Protected View.
If you enable this policy setting, you can specify a location containing files that always open in Protected View. If you check the "Allow sub folders" option, sub folders will also be included.
If you disable or do not configure this policy setting, only the "Downloaded Program Files" and "Temporary Internet Files" folders will be considered unsafe locations.
Registre
HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\common\security\protectedview\locations\location11- Nom de la valeur
- non défini dans l'ADMX
Valeurs d'activation / désactivation : non défini dans l'ADMX (voir les options ci-dessous).
PowerShell
Commandes PowerShell qui écrivent dans le registre ce que la stratégie écrirait. Les valeurs entre chevrons (<…>) sont à remplacer.
Écrire directement dans le registre contourne la stratégie de groupe : si une GPO gère cette valeur, elle sera réécrite au prochain gpupdate ; sinon la valeur reste en place (effet « tatouage »). Préférez une GPO ou, en local, LGPO.exe. Exécutez PowerShell en administrateur pour HKLM. Certaines stratégies demandent un redémarrage ou gpupdate /force.
Activer
# Activer : office16/L_UnsafeLoc11
$k = 'HKCU:\software\policies\microsoft\office\16.0\common\security\protectedview\locations\location11'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Path
Set-ItemProperty -Path $k -Name 'path' -Value '<valeur>' -Type ExpandString
# Allow sub folders
# décoché : 0
Set-ItemProperty -Path $k -Name 'allowsubfolders' -Value 1 -Type DWordDésactiver
# Désactiver : office16/L_UnsafeLoc11
# Aucune valeur n'est écrite à l'état « Désactivé » (rien de défini dans l'ADMX)Revenir à « Non configuré »
# Revenir à « Non configuré » : office16/L_UnsafeLoc11
$k = 'HKCU:\software\policies\microsoft\office\16.0\common\security\protectedview\locations\location11'
Remove-ItemProperty -Path $k -Name 'path' -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $k -Name 'allowsubfolders' -ErrorAction SilentlyContinueOptions (2)
| Libellé | Contrôle | Valeur de registre | Type REG | Contraintes / détails |
|---|---|---|---|---|
| Path:L_Pathcolon11 | Zone de textetext | path | REG_EXPAND_SZ | |
| Allow sub folders:L_Allowsubfolders11 | Case à cocherboolean | allowsubfolders | REG_DWORD | Coché : REG_DWORD = 1Décoché : REG_DWORD = 0 |
Application
Microsoft 365 Apps / Office (Microsoft) — modèles de novembre 2026
Modèles officiels téléchargés le 12 novembre 2026.