1. Resources
  2. Detection rules
  3. DCSync

DCSync detection rules

An account with directory replication rights asks a domain controller to replicate password hashes, including krbtgt. Detected when a non-DC account exercises the replication extended rights.

Platform
Active Directory
Severity
Critical
Log source
Windows Security event log
Last updated
Rule formats
Sigmaand queries for: SplunkMicrosoft SentinelIBM QRadar
What an attacker needs
An account holding both replication extended rights on the domain object, directly or through a group, and network access to a domain controller.
Impact
The attacker obtains the password hashes of every account in the domain, including the krbtgt hash that allows forged Golden Tickets.
Response
Disable the account that requested replication and remove its replication rights, then reset privileged and service account passwords and the krbtgt password twice.
Mitigation
Remove replication rights on each domain object from every principal that is not a domain controller or a documented sync account, and treat the accounts that keep them as Tier 0.
Event IDs
51364662

How the attack works

Domain controllers keep each other in sync with the Directory Replication Service (DRS) remote protocol. A DCSync attack impersonates a domain controller and calls the same replication API to pull secret attributes (NT hashes, Kerberos keys) for any account, including krbtgt.

The request only needs the Replicating Directory Changes and Replicating Directory Changes All extended rights on the domain object. These rights are normally held by domain controllers and administrators, but they are also granted by mistake to service accounts, sync accounts and delegated groups, or added by attackers for persistence.

What an attacker needs

  • An account holding both replication extended rights on the domain naming context (directly, through a group, or through control of the domain object such as GenericAll, WriteDacl or Owner).
  • Network access to a domain controller.

Impact

The attacker obtains the password hashes of every account in the domain. With the krbtgt hash they can forge Golden Tickets; with administrator hashes they can authenticate anywhere through pass-the-hash. Recovery requires resetting krbtgt twice and every privileged credential.

Detection rules

Replication Rights Granted on the Domain Object

Detects a new security descriptor on the domain head object (5136, nTSecurityDescriptor, Value Added) whose SDDL grants DS-Replication-Get-Changes-All (1131f6ad-9c07-11d1-f79f-00c04fc2dcd2) to a principal identified by a domain SID, or to Domain Users, Domain Computers, Authenticated Users or Everyone. That right, together with DS-Replication-Get-Changes, is what DCSync needs. Default entries for domain controllers and administrators use SDDL aliases (DD, ED, BA) and are not matched. The event holds the whole new descriptor, so an existing grant (for example a Microsoft Entra Connect account) also matches on any later DACL change; compare with the Value Deleted event that has the same OpCorrelationID. Requires Audit Directory Service Changes and a SACL on the domain object.

LevelHighStatusExperimentalLog sourceWindows Security event log
title: Replication Rights Granted on the Domain Object
id: 0b5391e3-bbc7-4bf2-b826-6b5ebf4af870
status: experimental
description: >-
  Detects a new security descriptor on the domain head object (5136,
  nTSecurityDescriptor, Value Added) whose SDDL grants
  DS-Replication-Get-Changes-All (1131f6ad-9c07-11d1-f79f-00c04fc2dcd2) to a
  principal identified by a domain SID, or to Domain Users, Domain Computers,
  Authenticated Users or Everyone. That right, together with
  DS-Replication-Get-Changes, is what DCSync needs. Default entries for
  domain controllers and administrators use SDDL aliases (DD, ED, BA) and are
  not matched. The event holds the whole new descriptor, so an existing grant
  (for example a Microsoft Entra Connect account) also matches on any later
  DACL change; compare with the Value Deleted event that has the same
  OpCorrelationID. Requires Audit Directory Service Changes and a SACL on the
  domain object.
references:
  - https://attack.mitre.org/techniques/T1003/006/
  - https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-10/security/threat-protection/auditing/event-5136
  - https://learn.microsoft.com/en-us/windows/win32/secauthz/ace-strings
  - https://learn.microsoft.com/en-us/windows/win32/adschema/r-ds-replication-get-changes-all
author: Forestall
date: 2026-11-10
tags:
  - attack.credential-access
  - attack.t1003.006
logsource:
  product: windows
  service: security
detection:
  selection:
    EventID: 5136
    ObjectClass: domainDNS
    AttributeLDAPDisplayName: nTSecurityDescriptor
    OperationType:
      - '%%14674'
      - 'Value Added'
    AttributeValue|contains:
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2;;S-1-5-21-'
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2;;DU)'
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2;;DC)'
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2;;AU)'
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2;;WD)'
  condition: selection
falsepositives:
  - Initial configuration of Microsoft Entra Connect or another directory synchronization product, which grants replication rights to its service account, and any later DACL change on the domain object while that grant exists. Compare with the previous descriptor before escalating.
level: high

False positives

  • Initial configuration of Microsoft Entra Connect or another directory synchronization product, which grants replication rights to its service account, and any later DACL change on the domain object while that grant exists. Compare with the previous descriptor before escalating.

Directory Replication Requested by a Non-Domain-Controller Account

Detects use of the DS-Replication-Get-Changes, DS-Replication-Get-Changes-All or DS-Replication-Get-Changes-In-Filtered-Set extended rights by an account that is not a domain controller computer account, the core indicator of a DCSync attack. Requires Audit Directory Service Access and a SACL on the domain object. The filter excludes every account whose name ends in $, so replication requested with a computer account that is not a domain controller, or with a stolen domain controller machine account, is not detected; where you can, replace the filter with an explicit list of your domain controller accounts.

LevelHighStatusExperimentalLog sourceWindows Security event log
title: Directory Replication Requested by a Non-Domain-Controller Account
id: 8f130682-2c22-4505-bc69-1754c8db0cda
status: experimental
description: >-
  Detects use of the DS-Replication-Get-Changes, DS-Replication-Get-Changes-All
  or DS-Replication-Get-Changes-In-Filtered-Set extended rights by an account
  that is not a domain controller computer account, the core indicator of a
  DCSync attack. Requires Audit Directory Service Access and a SACL on the
  domain object.
  The filter excludes every account whose name ends in $, so replication
  requested with a computer account that is not a domain controller, or with a
  stolen domain controller machine account, is not detected; where you can,
  replace the filter with an explicit list of your domain controller accounts.
references:
  - https://attack.mitre.org/techniques/T1003/006/
  - https://learn.microsoft.com/en-us/previous-versions/windows/it-pro/windows-10/security/threat-protection/auditing/event-4662
author: Forestall
date: 2026-11-10
tags:
  - attack.credential-access
  - attack.t1003.006
logsource:
  product: windows
  service: security
detection:
  selection:
    EventID: 4662
    AccessMask: '0x100'
    Properties|contains:
      - '1131f6aa-9c07-11d1-f79f-00c04fc2dcd2'
      - '1131f6ad-9c07-11d1-f79f-00c04fc2dcd2'
      - '89e95b76-444d-4c62-991a-0facbeda640c'
  filter_domain_controllers:
    SubjectUserName|endswith: '$'
  condition: selection and not filter_domain_controllers
falsepositives:
  - Microsoft Entra Connect (MSOL_ / Sync_ accounts) and other documented directory synchronization services; exclude them by exact account name.
level: high

False positives

  • Microsoft Entra Connect (MSOL_ / Sync_ accounts) and other documented directory synchronization services; exclude them by exact account name.

Detection logic

Patterns that need more than one event, a baseline or knowledge of your own environment. Each is a hypothesis to build and tune in your SIEM, not a ready rule.

Replication requested by a computer account that is not one of your domain controllers

Detection hypothesisNeeds your own lists

The rule leaves out every account whose name ends in $, so replication requested with a computer account goes unseen: a server that was granted the replication rights by mistake or for persistence, or a computer account the attacker created and then granted them. Comparing the requesting account with the list of your own domain controller accounts closes that gap.

  1. Take event 4662 with AccessMask 0x100 whose Properties hold 1131f6aa-9c07-11d1-f79f-00c04fc2dcd2, 1131f6ad-9c07-11d1-f79f-00c04fc2dcd2 or 89e95b76-444d-4c62-991a-0facbeda640c, from the Security log of every domain controller, and keep the events whose SubjectUserName ends in $.
  2. Compare SubjectUserSid with the SIDs of the domain controller computer accounts of every domain in the forest: the members of Domain Controllers (RID 516) and Read-only Domain Controllers (RID 521). Global catalogs of other domains replicate too, which is why the list covers the forest.
  3. Report every request whose SubjectUserSid is not on the list, with the domain controller in Computer that logged it.

Events4662

LimitsThe list has to be refreshed when a domain controller is added or removed, or a new one shows up as a finding. A stolen domain controller account passes this check: the next entry looks at where the request came from. The event needs a SACL on the domain object that audits these rights.

Replication requested from an address that is not a domain controller

Detection hypothesisJoins two logsNeeds your own lists

Domain controllers replicate with each other, so a legitimate replication request comes from the address of a domain controller or of a documented synchronization server. DCSync is requested from the attacker's host, whatever account it uses. Joining the request to the logon session it was made in gives the source address, which also exposes a stolen domain controller account or a sync account used from another host.

  1. Take event 4662 with AccessMask 0x100 and one of the replication rights GUIDs in Properties, and keep SubjectLogonId, SubjectUserName and the domain controller in Computer.
  2. On the same domain controller, find the event 4624 logged shortly before whose TargetLogonId equals that SubjectLogonId; Microsoft names the logon ID as the value that links event 4662 to event 4624. Read IpAddress and LogonType (3 is a network logon).
  3. Compare IpAddress with the addresses of your domain controllers and of your documented synchronization servers, for example the Microsoft Entra Connect server.
  4. Report requests from any other address, and requests by the synchronization account that come from an address other than its own server.

Events46624624

LimitsLogon IDs are unique per computer only, so join events of the same domain controller. A session whose 4624 has rolled out of the log finds no match, and Microsoft notes that the address fields depend on the authentication context, so some logons carry none. Domain controllers with several addresses and NAT must be in the list. A request run on a domain controller itself shows a domain controller address.

Triage

  • Identify the requesting account (SubjectUserName) and confirm whether it is a domain controller machine account or an approved sync account.
  • Correlate the logon session (SubjectLogonId) with event 4624 to find the source IP address; replication from a workstation is never legitimate.
  • If unexplained, assume all domain credentials are exposed and start the krbtgt and privileged password reset procedure.

Response

Once the attack is confirmed:

  1. Disable the account that requested replication and remove its replication rights on the domain object, including any group membership that grants them. Isolate the host the request came from.
  2. Check the access control list of the domain object for other principals with replication rights that were added for persistence, and remove them.
  3. Reset the passwords of privileged and service accounts only after the account and the rights are closed. Otherwise the new hashes can be replicated again.
  4. Reset the krbtgt password twice, because its hash was among those taken and allows forged tickets for any account.
  5. Watch for further replication requests from accounts that are not domain controllers, and for logons with accounts whose passwords have not been changed yet.

Mitigation

  • Review who holds Replicating Directory Changes (All) on each domain object and remove every principal that is not a domain controller or a documented sync account.
  • Treat accounts that keep these rights (for example Microsoft Entra Connect sync accounts) as Tier 0 and restrict where they can sign in.
  • Enable "Audit Directory Service Access" on domain controllers and audit the domain object so replication requests are logged.

Frequently asked questions

Can the rule see DCSync performed with a computer account?

No. The rule excludes every account whose name ends in $, to leave out domain controllers. Replication requested with another computer account, or with a stolen domain controller machine account, is therefore not detected. Where you can, replace the filter with an explicit list of your domain controller accounts. The Detection logic section describes that comparison, and a second one that checks whether the request came from the address of a domain controller.

Why does the Microsoft Entra Connect server trigger the rule?

Its synchronization account holds the replication rights and uses them as part of its normal work, so it produces the same event 4662 as an attack. Exclude it by its exact account name, and treat it as Tier 0, because whoever controls that account can perform DCSync.

Is it enough to change the administrators' passwords after DCSync?

No. The attacker has the password hashes of every account in the domain, including `krbtgt`. With the `krbtgt` hash they can forge Golden Tickets whatever the new passwords of the administrators are. Recovery means resetting `krbtgt` twice and every privileged credential.

References

We respect your privacy

We use cookies to keep this site secure and working properly. With your permission, we also use optional cookies to understand usage and improve the experience. Cookie Policy

You can change your choice at any time.