Disable additional security checks on VBA library references that may refer to unsafe locations on the local machine
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 restricts VBA to checking project library references only against the registry and trusted zones. By default VBA performs additional checks against library paths to prevent loading references from potentially unsafe locations on the local machine as well. It is recommended that this setting remain 0 or unset to allow for the more secure default behavior. Only enable this setting if the default behavior is causing compatibility issues with critical solutions, and then, only to provide time to migrate the solutions to address the less secure behavior, at which point the setting should be turned off again.
Registre
HKEY_CURRENT_USER\software\policies\microsoft\vba\security- Nom de la valeur
disablestrictvbarefssecurity
| État | Valeur écrite |
|---|---|
| Activé | REG_DWORD = 1 |
| Désactivé | REG_DWORD = 0 |
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_DisableStrictVbaRefsSecurityPolicy
$k = 'HKCU:\software\policies\microsoft\vba\security'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'disablestrictvbarefssecurity' -Value 1 -Type DWordDésactiver
# Désactiver : office16/L_DisableStrictVbaRefsSecurityPolicy
$k = 'HKCU:\software\policies\microsoft\vba\security'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'disablestrictvbarefssecurity' -Value 0 -Type DWordRevenir à « Non configuré »
# Revenir à « Non configuré » : office16/L_DisableStrictVbaRefsSecurityPolicy
$k = 'HKCU:\software\policies\microsoft\vba\security'
Remove-ItemProperty -Path $k -Name 'disablestrictvbarefssecurity' -ErrorAction SilentlyContinueApplication
Microsoft 365 Apps / Office (Microsoft) — modèles de novembre 2026
Modèles officiels téléchargés le 12 novembre 2026.