Open in the explorer

Prevent plaintext PINs from being returned by Credential Manager

Ne pas autoriser le renvoi de codes confidentiels en texte brut par le Gestionnaire d’informations d’identification

Type
Computer
GPO path
Computer Configuration › Policies › Administrative Templates › Windows Components › Smart Card FR: Configuration ordinateur › Stratégies › Modèles d'administration › Composants Windows › Carte à puce
Supported on
At least Windows Vista Service Pack 1 FR: Au minimum Windows Vista Service Pack 1
ADMX file
Smartcard.admx
Internal name
Smartcard/DisallowPlaintextPin

Explanation

This policy setting prevents plaintext PINs from being returned by Credential Manager.

If you enable this policy setting, Credential Manager does not return a plaintext PIN.

If you disable or do not configure this policy setting, plaintext PINs can be returned by Credential Manager.

Note: Enabling this policy setting could prevent certain smart cards from working on Windows. Please consult your smart card manufacturer to find out whether you will be affected by this policy setting.

French text from Windows 11 26H2

Ce paramètre de stratégie interdit le renvoi des codes PIN en texte brut par le Gestionnaire d’informations d’identification.

Si vous activez ce paramètre de stratégie, alors le Gestionnaire d’informations d’identification ne renvoie pas de code PIN en texte brut.

Si vous désactivez ce paramètre de stratégie ou ne le configurez pas, alors le Gestionnaire d’informations d’identification peut renvoyer des codes PIN en texte brut.

Remarque : l’activation de ce paramètre de stratégie peut empêcher le fonctionnement de certaines cartes à puce avec Windows. Renseignez-vous auprès du fabricant de votre carte à puce en cas de doute sur l’utilisation de ce paramètre de stratégie.

Registry

HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\SmartCardCredentialProvider
Value name
DisallowPlaintextPin
StateValue written
EnabledREG_DWORD = 1
DisabledREG_DWORD = 0

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/DisallowPlaintextPin
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\SmartCardCredentialProvider'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DisallowPlaintextPin' -Value 1 -Type DWord

Disable

# Disable: Smartcard/DisallowPlaintextPin
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\SmartCardCredentialProvider'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DisallowPlaintextPin' -Value 0 -Type DWord

Revert to "Not configured"

# Revert to "Not configured": Smartcard/DisallowPlaintextPin
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\SmartCardCredentialProvider'
Remove-ItemProperty -Path $k -Name 'DisallowPlaintextPin' -ErrorAction SilentlyContinue

Availability