This technique is usually carried out when an operator faces an AD Environment with ADCS deployed in its own DC and the HTTP Web Enrollment Endpoint is enabled
It also applies if NTLM authentication is disabled for the HTTP Web Enrollment Endpoint or for the entire domain
Since an ESC8 cannot be performed, we have to leverage Kerberos Relay in order to bypass one of this restrictions
Workflow
Requirements
Abuse - UNIX-Like
Creating a “Marshall” DNS Record
First of all, we have to leverage a controlled domain account to add an arbitrary DNS record in the Domain DNS zone pointing to our attacker machine
We may face the following error when running the command above
Error
[-] Connecting to host...[-] Binding to host[+] Bind OKTraceback (most recent call last): File "/home/al3xbb/HTB/VulnCicada/Tools/KRBRELAYX/dnstool.py", line 615, in <module>...<SNIP>... raise NXDOMAIN(qnames=self.qnames_to_try, responses=self.nxdomain_responses)dns.resolver.NXDOMAIN: The DNS query name does not exist: cicada.vl.
This occurs because the client’s DNS Resolvers do not know how to resolve the domain in question
Simply add the following line to the /etc/resolv.conf file, so the client can send any query name to the specified resolver and it won’t get an NXDOMAIN error
nameserver <DC_IP>...<SNIP>...
Setting up a Relayer
Then, we have to run a tool that relays the incoming AP_REQ from the victim to the specified target
In this case, we will coerce a DC to send back to us an authentication over a certain protocol that we can relay to the ADCS Web Enrollment Endpoint
Once we have control over the DC computer account, we can leverage the DRSUAPI RPC interface and authenticate ourselves as the domain account in question in order to perform a DCSync attack