# Domain Trusts

Domain trusts are relationships established between two or more domains that allow for shared access to resources and user authentication across boundaries.&#x20;

These trusts can be one-way, where only one domain recognizes the trust, or two-way, enabling mutual recognition and authentication.&#x20;

In Windows Server environments, trusts can be transitive, extending the trust beyond two domains, or non-transitive, limiting the trust strictly between the two specified domains.&#x20;

Understanding and configuring domain trusts is crucial for maintaining security and efficient resource management in complex network infrastructures.

### **Get a list of all the domain trusts for the current domain**

```
Get-NetDomainTrust
```

### **Get details about the forest**

```
Get-NetForest
```

### **Get all domains in the forest**

```
Get-NetForestDomain
Get-NetforestDomain -Forest <domain name>
```

### **Get global catalogs for the current forest**

```
Get-NetForestCatalog
Get-NetForestCatalog -Forest <domain name>
```

### **Map trusts of a forest**

```
Get-NetForestTrust
Get-NetForestTrust -Forest <domain name>
Get-NetForestDomain -Verbose | Get-NetDomainTrust
```

#### Check domain trust for a specific domain

```
Get-NetDomainTrust -Domain <specific domain name>
```

#### Get the forest trust status

```
Get-NetForestTrustStatus
Get-NetForestTrustStatus -Forest <domain name>
```

#### Retrieve Domain Controllers for a specific domain

```
Get-NetDomainController
Get-NetDomainController -DomainName <specific domain name>
```

#### Enumerate Organization Units (OUs) in a domain

```
Get-NetOU -Domain <domain name>
Get-NetOU -Domain <domain name> -FullData
```


---

# 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://crtp-certification.certs-study.com/domain-enumeration/domain-trusts.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.
