githubEdit

Silver Ticket

Requirements:

1) SPN password NTLM hash

https://www.browserling.com/tools/ntlm-hash

OR Use this Python one-liner instead

python3 -c "from passlib.hash import nthash; print(nthash.hash('YourPassword'))"

Another one-liner

echo -n 'YourPassword' | iconv -t UTF-16LE | openssl md4

2) Domain SID

Windows

Get-ADDomain

Linux

rpcclient -U "user.name" -c "lsaquery" IP

3) Target SPN (mssql/domain.local)

Windows

Get-ADUser -Filter {SamAccountName -eq "svc_mssql"} -Properties ServicePrincipalNames

Linux (Add -request to Kerberoast if needed)

4) Kerberos modules installed on your machine

Steps:

1) Verify if the service you are authenticated runs in the context of the service user. If yes, you can impersonate the administrator!

Create a share directory

Run your SMB Server

Try to authenticate to your SMB Server, then check for verification

2) Create ST

/rc4 take the service account (generally the machine account) hash. /aes128 or /aes256 can be used for AES keys.

Requesting a ST with a valid TGT can be performed with Rubeus like this:

Another solution, if you don't have the NT hash or the AES keys of the service but you have a TGT for the service account, is to impersonate an account via a request for a service ticket through S4USelf to an alternative service (and the opsec is better since the PAC is consistent):

Linux

Another solution, if you don't have the NT hash or the AES keys of the service but you have a TGT for the service account, is to impersonate an account via a request for a service ticket through S4USelf to an alternative service (and the opsec is better since the PAC is consistent):

MISC

3) After crafting your ST, export the ccache file into krb5ccname

4) Adjust the krb5.conf by adding the target domain and realm by adding them as new entries with the corresponding format

TIP: If you have access to a service (MSSQL, for example) via port forward, DO NOT FORGET to set an extra /etc/hosts file entry with localhost

5) Authenticate with your crafted Silver Ticket

Last updated