Overpass the Hash / Pass the Key
This attack aims to use the user NTLM hash to request Kerberos tickets, as an alternative to the common Pass The Hash over NTLM protocol. Therefore, this could be especially useful in networks where NTLM protocol is disabled and only Kerberos is allowed as authentication protocol.
In the case of over-pass-hash, we are generating the things that would get us that original TGT in memory on the windows client then fronting up to the domain controller for a service ticket to the thing we want access to, and automatically getting the TGT back as part of the exchange so that we can go on and request all access we want to other things.
In order to perform this attack, the NTLM hash (or password) of the target user account is needed. Thus, once a user hash is obtained, a TGT can be requested for that account. Finally, it is possible to access any service or machine where the user account has permissions.
Grab the Target User Hash
In the target machine run this and dump the NTLM hash of the 'target-user' account:
With the help of ekeys you will able to fetch all keys NTLM (RC4), AES128, AES256 key
Overpass the Hash
So with the help of sekurlsa::pth command we try to use ase256 key or aes128 for Kerberos ticket, it is difficult to detect because it is the more common and secure key used in encryption.
Using our new hash, we issue the command:
If you will use NTLM (RC4), ASE128, ASE256 simultaneously for injecting into Kerberos ticket, this step is more secure and undetectable in the network.
We should be able to now move from our shell that was running as whomever , to a shell with 'target-user' credentials.
we can use getTGT.py script from impacket toolkit as well:
Impacket
You can specify -aesKey [AES key]
to specify to use AES256. You can also use the ticket with other tools like: as smbexec.py or wmiexec.py
with the help of above command, you will be able to request Kerberos authorized ticket in the form of ccache whereas with the help of the following command you will be able to inject the ticket to access the resource.
Rubeus
Last updated