Configure root certificate clean up
Configurer le nettoyage du certificat racine
Explanation
This policy setting allows you to manage the clean up behavior of root certificates. If you enable this policy setting then root certificate cleanup will occur according to the option selected. If you disable or do not configure this setting then root certificate clean up will occur on log off.
Ce paramètre de stratégie vous permet de gérer le comportement du nettoyage des certificats racines. Si vous activez ce paramètre de stratégie, le nettoyage du certificat racine s’exécute en fonction de l’option sélectionnée. Si vous désactivez ce paramètre ou si vous ne le configurez pas, le nettoyage du certificat racine s’exécute lors de la fermeture de session.
Registry
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\CertProp- 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: Smartcard/CertPropRootCleanupString
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\CertProp'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Root certificate clean up options
# Possible options:
# No cleanup = 0
# Clean up certificates on smart card removal = 1
# Clean up certificates on log off = 2
Set-ItemProperty -Path $k -Name 'RootCertificateCleanupOption' -Value 2 -Type DWordDisable
# Disable: Smartcard/CertPropRootCleanupString
# No value is written in the "Disabled" state (nothing defined in the ADMX)Revert to "Not configured"
# Revert to "Not configured": Smartcard/CertPropRootCleanupString
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\CertProp'
Remove-ItemProperty -Path $k -Name 'RootCertificateCleanupOption' -ErrorAction SilentlyContinueOptions (1)
| Label | Control | Registry value | REG type | Constraints / details | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Root certificate clean up optionsOptions de nettoyage du certificat racineRootCertCleanupOption_Levels | Drop-down listenum | RootCertificateCleanupOption | REG_DWORD | Default choice (UI): #2
|