AD CS
Certificate enrollment
Non-privileged users can request a certificate from the Enterprise Certificate Authority for any of the existing templates which are available for enrollment.
Certificate extraction
User persistence
Certificates that have been exported in .pem format can be converted to .pfx in order to be compatible with Rubeus and installed directly into the certificate store. This is because certificates in .pfx format are similar to archives and contain all the necessary information to be deployed on the system.
A Ticket Granting Ticket (TGT) can be requested with Rubeus from the Kerberos Key Distribution Center (KDC) for the enrolled user.
Similarly to Rubeus the TGT can be obtained using the “gettgtpkinit.py” by supplying the pfx certificate and the user which the certificate has been issued. This script will output a TGT into the specified ccache file.
To use getnthash.py, set the TGT file path in the KRB5CCNAME environment variable.
The AES-REP encryption key which has been retrieved previously can be used with the getnthash.py utility in order to recover the NTLM hash from the PAC.
Sometimes, the following error is obtained when using the PKINIT tools:
In that case, run the following command:
Last updated