1. Resources
  2. Detection sources
  3. Event ID 2974

Event ID 2974: The attribute value provided is not unique in the forest or partition

Written by a domain controller that refused a write because the UPN or SPN value already exists in the forest, with the value and up to ten objects that hold it. Shows attempts to take over another account's name.

Log source
Directory Service log
Detection value
Supporting
Volume
Low (estimate)
Last updated
Log
Directory Service log (Microsoft-Windows-ActiveDirectory_DomainService, on by default)
Logged on
Domain controllers only
Event versions
Not published
Detects
1 attack (1 rule)
MITRE ATT&CK
1 technique in 2 tactics
Threat groups
6 groups that MITRE ATT&CK records using these techniques
Fields the rules read
The event ID and the provider only

When it is written

Domain controllers running Windows Server 2012 R2 or later refuse a write that would give a second object a user principal name (UPN) or service principal name (SPN) that already exists in the forest, and log 2974 to their Directory Service log. The check covers a new value, a renamed object, and the restore or reanimation of a deleted object; it also covers the SPNs Windows rebuilds when an attribute such as dNSHostName or sAMAccountName changes. Microsoft's screenshots show the event as an Error in the Global Catalog task category, with an account in Event Viewer's User box that the page does not describe.

The event text gives the attribute, the refused value, the distinguished names of up to ten objects that already hold it, and the Windows error: 8648 for a UPN, 8647 for an SPN. On a domain controller that is a global catalog the check runs against its own forest-wide index; on one that is not, Microsoft describes it as best effort: the domain controller asks the closest global catalog and checks its own database only when it finds none.

When no event appears although a duplicate exists: a write processed by a domain controller older than Windows Server 2012 R2 is not checked; a restore that fails because of a duplicate logs no event, according to Microsoft; the 21st character of the forest's dSHeuristics attribute can switch the UPN check, the SPN check or the SPN alias check off (MS-ADTS); and a value that slips past the check is not refused. Microsoft fixed one such case in its March 10, 2026 updates (CVE-2026-25177: duplicates made with specially crafted Unicode characters), so on domain controllers without those updates such a duplicate leaves no 2974.

How to turn it on

Microsoft-Windows-ActiveDirectory_DomainService writes the event to the Directory Service log (Event Viewer > Applications and Services Logs > Directory Service), which is on by default. Microsoft

The log needs nothing to be turned on: a domain controller writes it from the moment it is promoted. What Active Directory writes there depends on its diagnostic logging levels, one REG_DWORD value per category under HKLM\SYSTEM\CurrentControlSet\Services\NTDS\Diagnostics (for example 16 LDAP Interface Events), each from 0 (None) to 5 (Internal). Microsoft's default for every category is 0, which it describes as recording only critical and error events; several warning and information events of this library are nonetheless documented as written at that level (the CVE-2021-42291 events, the daily LDAP summaries). Some events, such as the per-client LDAP signing and channel binding events, are written only at level 2 or higher of their category; their pages say so.

Microsoft recommends keeping the levels at 0 unless you investigate an issue, notes that a higher level adds detail and events, and advises against 3 or more because it costs resources and can slow the server. The levels are set per domain controller, so set them on every domain controller whose events you need. AD LDS instances write the same kind of events to their own instance log, which this library does not cover.

Show the diagnostic logging levels of this domain controller
reg query "HKLM\SYSTEM\CurrentControlSet\Services\NTDS\Diagnostics"
Based on vendor documentation.
Show the log's settings (size and retention)
wevtutil gl "Directory Service"
Based on vendor documentation.

Nothing to turn on: a domain controller running Windows Server 2012 R2 or later writes the event at the default diagnostic level. What can silence it is the 21st character of dSHeuristics on the CN=Directory Service,CN=Windows NT,CN=Services object of the configuration partition: MS-ADTS reads it as bits, bit 0 to skip the UPN check, bit 1 the SPN check, bit 2 the SPN alias check. Read the attribute (read only, Active Directory module):

Get-ADObject -Identity ("CN=Directory Service,CN=Windows NT,CN=Services," + (Get-ADRootDSE).configurationNamingContext) -Properties dSHeuristics | Select-Object -ExpandProperty dSHeuristics

An empty result means the attribute is not set and every check is on. If the string has 21 characters or more, its 21st character should be 0.

Fields

The template of this event is not part of client Windows and Microsoft does not publish its XML field names, so the fields are named by the labels of Microsoft’s documentation.

FieldWhat it holds
AttributeLDAP name of the attribute whose value is not unique: userPrincipalName or servicePrincipalName.
ValueThe value that was refused, the UPN or the SPN. The message prints it after Value=.
Object DNDistinguished names of the objects that already hold the value, one per line, up to ten according to Microsoft. This part of the message has no label; Microsoft's text sample writes it as .
WinerrorWindows error code in decimal: 8648 (0x21C8) for a UPN, 8647 (0x21C7) for an SPN. Microsoft's page also prints 8467 and 8468 in its text and its SPN sample; those numbers do not match the hexadecimal codes, and its screenshots show 8648.

Values to know

Attribute

ValueMeaningSignal
servicePrincipalNameA second account claimed an SPN another account holdsMicrosoft's advisory for CVE-2026-25177 explains that a duplicate SPN can make the domain controller issue tickets encrypted with the wrong key, so that the service rejects them, or push clients to NTLM. A refused write is an attempt.Attack signal
userPrincipalNameA second account claimed a UPN another account holdsA sign-in name taken from another account. Microsoft also notes that duplicate UPNs break synchronization with Microsoft Entra ID.Attack signal

Winerror

ValueMeaningSignal
86480x21C8, ERROR_DS_UPN_VALUE_NOT_UNIQUE_IN_FORESTThe UPN case.Worth knowing
86470x21C7, ERROR_DS_SPN_VALUE_NOT_UNIQUE_IN_FORESTThe SPN case.Worth knowing

Object DN

ValueMeaningSignal
A domain controller or another Tier 0 objectThe value belongs to a critical accountSomeone tried to give its SPN or UPN to another object.Attack signal
An older account of the same service or personA leftover registrationRemove the stale value and repeat the change.Noise

Volume and noise

Ordinary sources are administrators and deployment scripts that register an SPN that a previous account of the same service still holds (a service moved to a new account before the old registration was removed), provisioning that reuses a UPN, and the restore or rename of an object whose name is in use again. Microsoft's own guidance is to review 2974 regularly, both to spot attempts to create duplicates and to find objects that already share a value.

Keeping it manageable

  • Keep every 2974: the event is rare, and the rule matches the event ID alone because Microsoft documents its content as text, not as named fields.
  • Clean up the duplicates the events reveal (Microsoft's page shows how to find every object with a value, deleted objects included), so that a new event stands out.
  • Give priority to SPN values of domain controllers and other Tier 0 services, and to UPNs of privileged accounts, among the listed objects.
  • Watch the 21st character of dSHeuristics as well (the dSHeuristics Modification rule reads event 5136 on that attribute): once a check is off, this event stops for good.

Attacks this event reveals

Detection rules that read this event:

Frequently asked questions

Does event 2974 mean that a duplicate UPN or SPN now exists?

No. The domain controller refused the write, so the new duplicate was not created. The objects listed in the event can still share the value among themselves, for example when they were written by an older domain controller, which is why Microsoft recommends reviewing the event to find existing duplicates as well.

Why does event 2974 show 8647 or 8648 while Microsoft's page mentions 8467 and 8468?

The codes are 8647 (0x21C7, SPN) and 8648 (0x21C8, UPN), as Microsoft's table and its screenshots show. The numbers 8467 and 8468 in the page's text and SPN sample do not match those hexadecimal codes.

Who tried to write the duplicate value?

The message does not name it. Microsoft's screenshots show an account in Event Viewer's User box (the user of the event record), which the page does not describe. Confirm it against the logons on the same domain controller at that time (event 4624), which also give the source address.

Can the uniqueness check be switched off?

Yes. MS-ADTS describes the 21st character of the forest's dSHeuristics attribute as bits that turn off the UPN check, the SPN check or the SPN alias check. With a check off, no event 2974 is written for that kind of value, so treat a change to that character as a finding.

References