secretsdump: write trust keys to their own .ntds.trustkeys file - #2278
Open
mpgn wants to merge 1 commit into
Open
secretsdump: write trust keys to their own .ntds.trustkeys file#2278mpgn wants to merge 1 commit into
mpgn wants to merge 1 commit into
Conversation
Signed-off-by: mpgn <mpgn@users.noreply.github.com>
mpgn
marked this pull request as ready for review
September 1, 2026 18:29
14 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hello,
While working on this pr Pennyw0rth/NetExec#1321 , @NeffIsBack made a very good point about trusted keys not having their own file and be mixed with the wrong file.
-trust-keyscurrently writes the trust keys into<output>.ntds, mixed with the account hashes.They don't follow the pwdump layout:
The second field is a key type instead of a RID, so hashcat, john and any pwdump parser
break on those lines.
This writes them to
<output>.ntds.trustkeysinstead, the same way Kerberos keys alreadygo to
<output>.ntds.kerberos.Tested against a DC with one trust (
-just-dc -trust-keys):.ntds: 19 account lines, 0 trust lines.ntds.trustkeys: 12 trust lines