# DCSync

**ATT\&CK ID:** [T1003.006](https://attack.mitre.org/techniques/T1003/006/)

**Permissions Required:** <mark style="color:red;">**Administrator**</mark> | <mark style="color:orange;">**DCSync rights**</mark>

**Description**

Adversaries may attempt to access credentials and other sensitive information by abusing a Windows Domain Controller's application programming interface (API) to simulate the replication process from a remote domain controller using a technique called DCSync.

A DCSync attack is where an adversary impersonates a Domain Controller (DC) and requests replication changes from a specific DC. The DC in turn returns replication data to the adversary, which includes account hashes.

By default the following groups have permissions to perform this action:

* Administrators
* Domain Admins
* Enterprise Admins
* Domain Controllers

However, in an incorrectly configured environment it may be possible to hunt down users who have the required individual permissions without being in any of the aforementioned groups. These individual permissions are:

* Replicating Directory Changes
* Replicating Directory Changes All
* Replicating Directory Changes In Filtered Set

## Techniques

### Secretsdump.py

Impacket's `secretsdumpy.py` can be used to dump all domain hashes, providing the hash or password is known for an account with permission to perform replication.

```bash
sudo python2 secretsdump.py <Domain>/<User>:<Password>@<IP>
sudo python2 secretsdump.py security/Moe:'Password123!'@10.10.10.10
```

![](/files/-MihAf7joaTM4FqKnFjF)

###

### Further Reading

{% content-ref url="/pages/-MiffOnnuP3BznB6OgzC" %}
[DCSync Attack](/pentest-everything/everything/everything-active-directory/credential-access/credential-dumping/dcsync/dcsync-attack.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://viperone.gitbook.io/pentest-everything/everything/everything-active-directory/credential-access/credential-dumping/dcsync.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
