Child to Parent Movement Across Trusts
Last updated
Last updated
Domains that are in the same forest have an explicit two way trust between them. Between parent and child domains there are trust keys that can be used to move elsewhere within the forest.
The are two ways to take advantage of this:
Using Trust Tickets
Using krgtbt
If we are able to obtain a single Domain Admin, the trust of the entire forest would be at risk because we would now be able to move anywhere.
The attack is very similar to forging Silver or Golden Tickets. However, we must obtain the trust key, or the password shared between the two domains that maintains the trust.
Authentication is very similar to the average Kerberos authentication. The difference is that an extra step is taken to authenticate to the KDC on the other domain. This must occur because KDCs cannot grant TGSs to other domains. The target services credentials necessary to create tickets on the other domain are stored in the other domains DC.
The trust key becomes something like a middleman which allows the user to request a TGS on the other domain. It is this key which is encrypted into the TGT before the TGS request to the next domain is made instead of the DC's krbtgt password.
If there are more than two domains in a forest, the authentication procedure gets more complicated depending on the trust relationships within the forest.
To forge these tickets, we need the trust key. So we must find that first. This will require Admin privileges.
Now that we have the trust key, we can forge an Inter-Realm TGT (doesn't require Admin privileges). However, we first need the Enterprise Admins SID
Now we can forge the Inter-Realm TGT
And then forge a TGS to the parent
Then we can inject the ticket created from the last step
Now check our access to the parent
Step 1 - Make Sure You Have the krbtgt Hash
Step 2 - Create an Inter Realm TGT
Step 3 - Inject the Ticket
Step 4 - Check the Injection
First, get the parent Domain Controllers SID
Then create the ticket
Now you can DCSync to get the parent DC Administrator hash
Since intra-forest trusts are considered by default to be secure there is no real effective defense mechanism.
What can be done is to change the machine account passwords often in order to reduce persistence within the network. However, the best thing to do is protect the domain controller from any outside intrusion or code execution.