Challenge Goal
We are given a Windows KAPE triage collection from a laptop used by a guest named Vera. The goal is to follow the forensic artifacts, recover a hidden password, use it to open what Vera was hiding, and recover the flag.
Flag format starts with:
THM{
Initial Enumeration
After extracting the task files, the main directory contained a KAPE collection:
Get-ChildItem -Force
Important paths:
KAPE\C\Users\vera\
KAPE\C\Users\vera\Documents\backup
KAPE\C\Users\vera\AppData\Local\Google\Chrome For Testing\User Data\
KAPE\C\Windows\System32\config\SAM
KAPE\C\Windows\System32\config\SYSTEM
KAPE\C\Windows\System32\config\SECURITY
The file Documents\backup had no extension and looked like random data when viewed in hex. This is a strong hint for an encrypted container.
Clue From The Story
The social media clue says:
a browser will remember things for you
not every hidden file needs a password cracker
version number 1.26.29
That points to two things:
Browser saved credentials
VeraCrypt 1.26.29
So the plan became:
- Check Chrome artifacts.
- Recover the saved browser password.
- Use that password on the suspicious
backupfile. - Extract the hidden content and find the flag.
Chrome History
The Chrome history database was here:
KAPE\C\Users\vera\AppData\Local\Google\Chrome For Testing\User Data\Default\History
Using SQLite:
sqlite3 "KAPE\C\Users\vera\AppData\Local\Google\Chrome For Testing\User Data\Default\History" ".tables"
Then query visited URLs:
select datetime(last_visit_time/1000000-11644473600,'unixepoch') as last_visit,
url,
title
from urls
order by last_visit_time;
Interesting result:
http://bytelotus.thm:8080/login
http://bytelotus.thm:8080/
SecureVault Portal
So Vera used a portal called SecureVault.
Chrome Saved Login
The saved login database was here:
KAPE\C\Users\vera\AppData\Local\Google\Chrome For Testing\User Data\Default\Login Data
Query:
select origin_url, action_url, username_value, hex(password_value)
from logins;
Result:
origin_url: http://bytelotus.thm:8080/
username: VeraSecretVault
password_value: encrypted Chrome v10 blob
Chrome passwords are encrypted with Windows DPAPI, so we need Vera’s DPAPI material.
Recover Windows/DPAPI Secret
The KAPE collection included Windows registry hives:
SAM
SYSTEM
SECURITY
Using pypykatz, the offline registry secrets revealed:
LSA Default Password
Username: UNKNOWN
Password: minivera
This password was important because it allowed decrypting Vera’s DPAPI masterkey.
Vera’s DPAPI masterkey folder:
KAPE\C\Users\vera\AppData\Roaming\Microsoft\Protect\S-1-5-21-2529683458-431225740-1723070931-1000
The Chrome Local State file contained the encrypted Chrome key:
KAPE\C\Users\vera\AppData\Local\Google\Chrome For Testing\User Data\Local State
After decrypting the DPAPI masterkey with minivera, the Chrome saved password decrypted to:
Wh4t1sV3raD0inG0nTh1sH0st
Opening The Hidden Container
The suspicious file was:
KAPE\C\Users\vera\Documents\backup
It had no signature and looked fully random. Combined with the 1.26.29 clue, this indicated a VeraCrypt container.
Use the recovered password:
Wh4t1sV3raD0inG0nTh1sH0st
Open or mount the file with VeraCrypt.
Once opened, the container contained:
secret_financial_documents\
important_invoice_byte_lotus.pdf
transactions_q3.csv
Finding The Flag
The CSV was not the flag. The PDF looked like an invoice, but it was image-based, so normal text extraction may return nothing.
Render or open the PDF visually. The invoice contains a line item with the flag:
Flag: THM{1t_w4s_****_A11_*******}
Final Answer
THM{1t_w4s_****_A11_*******}
Key Takeaways
Chrome saved credentials can be recovered from triage data if the DPAPI masterkey can be decrypted.
The SECURITY, SAM, and SYSTEM hives are extremely valuable in Windows forensics.
A file with no extension and random-looking bytes may be an encrypted container.
The clue 1.26.29 was the giveaway for VeraCrypt.
Official VeraCrypt format reference: https://veracrypt.io/en/VeraCrypt%20Volume%20Format%20Specification.html
Top comments (0)