Microsoft Learn
msDS-KeyCredentialLinkAttribute definition and introduction with Windows Server 2016.
Active Directory attack path · Alternative credentials / PKINIT
Shadow Credentials does not involve stealing or resetting a target's password. The attack abuses a legitimate Windows mechanism that associates cryptographic material with an Active Directory identity: the msDS-KeyCredentialLink attribute, introduced with Windows Server 2016, which can notably hold the public keys used in some Windows Hello for Business scenarios.
If an identity holds permissions to modify this attribute on a user or a computer, it can add a Key Credential it controls. In an environment supporting PKINIT, the matching private key can then be used to request a Kerberos Ticket Granting Ticket as the target, without the legitimate password being known or changed. The mechanism barely disturbs the legitimate user, but leaves detectable traces in Active Directory.
The real question
Who can write msDS-KeyCredentialLink on your sensitive objects, and which asset do those objects lead to?
Each step depends on what the environment actually allows. Nothing in this sequence is automatic.
The truly dangerous point is therefore not only the existence of msDS-KeyCredentialLink. The path starts with a control relationship: an ACL, a delegation or an overly broad right allowing one identity to modify another's credential. This is exactly the logic of the parent page: an isolated technique is not yet an attack path.
Three properties explain its place in Active Directory attack paths.
The target's password is not reset. The user or service can therefore keep working normally while a second authentication mechanism has been added.
A password rotation does not automatically remove the added Key Credential. Persistence ends when the illegitimate value is removed or made unusable.
The impact depends entirely on the target. Adding a Key Credential to a low-privileged account has nothing like the impact of taking over a sensitive service account, a critical computer or a Tier 0 identity.
Several conditions must be met, notably:
The presence of AD CS can make PKINIT available in many environments, but a vulnerable PKI is not a prerequisite for Shadow Credentials, and neither is ESC1. AD CS and Shadow Credentials are two distinct topics that meet around PKI and Kerberos authentication.
A Shadow Credential is first and foremost an Active Directory object-control attack. An audit must therefore look for the identities able to modify msDS-KeyCredentialLink, directly or through broader rights.
Categories of rights to analyse
This list is not exhaustive: the analysis must cover effective rights and their inheritance.
The main signal lives in domain controller logs.
Main event
Event ID 5136 — A directory service object was modified
Filter in particular: AttributeLDAPDisplayName = msDS-KeyCredentialLink
Event ID 5136 is not automatically proof of Shadow Credentials, and it is only generated if Active Directory auditing is correctly configured.
Prevention targets the relationships that make the write possible, not just the attribute.
Identify who actually holds rights allowing msDS-KeyCredentialLink to be modified on users and computers.
Remove unnecessary GenericWrite, GenericAll and WriteProperty, especially on privileged accounts and sensitive objects.
Check the uses and memberships of the groups or accounts legitimately allowed to manage Key Credentials, without blindly removing rights needed by Windows Hello for Business or synchronisation mechanisms.
Check the values present on sensitive accounts and on objects that should not normally use key-based authentication.
Log changes and distinguish operations from known enrolment workflows from unexpected modifications.
To extend this reading to your own directory, a free Active Directory security diagnostic is available.
A simple password change is not enough. The response must include:
These two levels are not the same: removing the Shadow Credential closes the persistence, while fixing the ACL that allowed it breaks the attack path and prevents the same identity from writing another key tomorrow.
Shadow Credentials shows why an Active Directory analysis cannot be limited to hunting for one isolated technique. Our approach covers the whole path, within the Identity and Active Directory security service.
Other techniques from the same collection. They are not necessarily successive steps: each fits into an attack path depending on what the environment allows.
Another route to certificate-based authentication, focused on AD CS certificate templates.
Obtain crackable material from a service account.
Exploit the absence of Kerberos pre-authentication.
Exploit replication rights to obtain the domain's secrets.
Relay a legacy authentication to another service.
Add an authentication key to an object to authenticate as it through Kerberos.
References used to support this page.
Microsoft Learn
msDS-KeyCredentialLinkAttribute definition and introduction with Windows Server 2016.
Microsoft Learn
How Windows Hello for Business worksLegitimate use of public keys associated with identities.
Microsoft Learn
Audit Directory Service ChangesAuditing prerequisites for logging object changes.
Microsoft Learn
Event 5136 — A directory service object was modifiedEvent fields, including AttributeLDAPDisplayName and OpCorrelationID.
SpecterOps
Shadow Credentials: Abusing Key Trust Account Mapping for Account TakeoverOriginal description of the technique and PKINIT conditions.
Elastic Security
Potential Shadow Credentials added to AD ObjectCurrent detection rule and false positives from legitimate mechanisms.