Tactical LogHuntress CTF 2026 // team archive

Days / Day 28 / Metadata Forensics / Where It All Began

DAY 28//LANE: METADATA FORENSICS//STATUS: CORRECT x3

Where It All Began

SSTTMM Modes reported CORRECT in this write-up

Challenge: 🔎 Where It All Began Challenge ID: metadata-forensics-day-28-where-it-all-began Description: Disk images hold every previous artifact family in context. Recover partition layouts, locate evidence by offset, and prove which image was rebuilt from an incomplete source.

Results

All three modes returned CORRECT from the Game Master. Starts used the regular untimed variants (run_for_time:false for TT/MM, deadline:null).

ModeAccepted answersGame Master result
Single Solve1CORRECT — Token4ad724d30ce2d4d4e5fa704e80737638
Time Trial33CORRECT — Token1799bda941e5ff6b8ae19afc758ec063
Mastery396 across 12 setsCORRECT — Token85bbf34b86264584a297f8ed6a44839e

The result flags are the Game Master's returned completion tokens. The full answer payloads are preserved in single-solve-answers.json, time-trial-answers.json, and mastery-results/mastery-all-answers.json. The complete nested file inventory, per-file SHA-256 values, and file purposes are in artifact-manifest.md.

Challenge questions, formats, and answers

challenge-details.md is the rendered catalog of every live question, exact answer ID, artifact reference, requested syntax, and accepted answer. It includes all 396 Mastery fields. The saved Game Master responses are also preserved in single-solve-start.json, time-trial-start.json, and mastery-start.json.

Artifacts

ModeAssigned artifactSHA-256Contents and purpose
Single Solvemetadata-day-28-evidence.zip1b305bfd7e3fb5cc679b65fd8c8ac2e6344135064f6b4b70c7fa6c3c82753ce6One 128 KiB GPT disk image, disk-001.img.
Time Trialevidence.zip558e28dfa3b4ba8f2a6f70f6200c9e36d976c95ed99b41e08b579588280a174625 previous-family artifacts: note and roster, JPEG, PNG, PDF, ZIP, PE, .NET, MSI, LNK, DOCX, EML, audio, video, ELF, Mach-O, APK, JAR, SQLite, EVTX, registry hive, Prefetch, PCAP, and disk image.
Masterymetadata-forensics-day-28-where-it-all-began-mastery.zipddf69af2f41f3eeefb6d15a4b2bd8f3d4b0be57325bb0e250a0a0dc023bcee4b12 nested evidence bundles, evidence-01.zip (challenge artifact, not published) through evidence-12.zip (challenge artifact, not published); each repeats the same artifact families with a fresh set of note/roster bytes and disk layout. There are 24–25 members per nested bundle.

Each download was fetched through ?op=artifact and hashed locally before analysis. The clickable paths above are the exact root-relative Game Master download paths.

Disk layout findings

Single Solve

mmls identified a valid GPT at 512 bytes per sector. The partition entry has start LBA 34, end LBA 222, length 189 sectors, and name HUNTRESS EVIDENCE. Therefore the submitted sequence is the compact JSON array [34].

The evidence partition begins at byte offset 34 × 512 = 17,408. Its extent is 189 × 512 = 96,768 bytes, ending at byte offset 114,176 (exclusive). The protective MBR is at LBA 0, the primary GPT header at LBA 1, and the partition-entry array occupies LBAs 2–33. A backup EFI PART GPT header is present at the final LBA, 255.

Time Trial

The disk image in evidence.zip (challenge artifact, not published) has three GPT partitions. Their starts in table order are 273, 285, 400, submitted as [273,285,400]. Their corresponding byte offsets are 139,776, 145,920, and 204,800.

Mastery

Each Mastery set has its own disk-001.img. The accepted partition-start sequences are:

Setdisk.partition_start_lba_sequence
1[276,317]
2[122,202]
3[56,74,141,156]
4[159]
5[41,180,212,223,267,362]
6[43,161,167,187,218,261]
7[38,57,78,138]
8[65,230,272,399,472]
9[53,155]
10[84,189,265,333]
11[41,123,178,248]
12[71,203,277,289,425]

These are ordered partition starts, not byte offsets; multiply each LBA by the 512-byte sector size to locate its first byte. The per-set synthesis question separately requires sorting six named full-file SHA-256 digests and submitting the filenames in ascending digest order. Both the partition arrays and synthesis arrays are included in the accepted answer file.

Method

1. Retrieve assigned bytes and verify them

The supported proxy was used for every Game Master request. For example:

curl -sS 'http://[ip]/huntress-ctf-proxy?op=artifact&challenge=metadata-forensics-day-28-where-it-all-began' \
  -o metadata-day-28-evidence.zip
sha256sum metadata-day-28-evidence.zip
unzip -l metadata-day-28-evidence.zip
unzip -p metadata-day-28-evidence.zip disk-001.img > disk-001.img
python3 [local path] disk-001.img

For Time Trial and Mastery, change the challenge= value to the exact mode ID from the Game Master start response. The bytes were not retyped or fetched from another identity.

2. Parse structures from raw bytes

  • mmls reports partition starts in sectors and labels GPT metadata separately from actual partitions. disk_layout.py filters partition rows and emits compact JSON.
  • Python's zipfile, hashlib, struct, xml.etree, and email/text parsing handle nested ZIP names, full-file hashes, JPEG/PNG/PDF headers, PE fields, .NET MVID, MSI ProductCode, OOXML external targets, SQLite page size, EVTX records, registry root name, Prefetch name, PCAP records, and Mach-O universal-binary CPU types.
  • Media codec names follow the artifact codec identifier (flac, opus, mp3, aac, or FFmpeg-style PCM names). MP4 dimensions come from the video sample-entry header.
  • ZIP member names, external OOXML targets, and Mach-O CPU-type sets are sorted for their canonical answer arrays. Partition starts remain in partition-table order.
  • Full-file digests include the exact BOM and bytes. A SQLite header page-size value of 1 means 65,536 bytes by the SQLite format.

The reusable parser is solve_mastery.py. It derives all 396 answers from the downloaded outer ZIP and the saved API response. solve_bundle.py uses the same parsers for a one-bundle mode such as Time Trial. The generated requests are kept under mastery-results/ and time-trial-answers.json.

3. Submit using exact answer IDs

All values were sent under questions[].id from the live response. JSON-array answers were compact JSON strings without Markdown or prose. The 396-answer Mastery payload was 30,493 bytes, below the Game Master's 4 MiB request limit.

submit_mastery.py submits one combined batch first. If the service returns incorrect, it recursively divides only the rejected batch, records accepted subsets, and logs each response. This isolated two generator mistakes shared by all 12 sets: the PE original-filename field was initially confused with the challenge artifact filename, and the SQLite page-size suffix was initially confused with a file-size question. The parser was corrected to read the PE version resource value and SQLite header. All 372 other values were accepted on the first verification pass; the 24 corrected values were then accepted together, completing Mastery.

The final successful result responses were CORRECT; no timer was running in these starts because run_for_time was false and the API deadline was null.

Faster workflow next time

  1. Save the complete start response immediately; it contains the exact IDs, questions, syntax, and artifact capability.
  2. Fetch the artifact once through ?op=artifact, save to disk, and verify the API SHA-256 before extraction.
  3. Keep nested bundles in memory or separate folders, and map each question's artifact reference to the matching basename. Never mix bytes from separate variants.
  4. Run solve_bundle.py for one bundle or solve_mastery.py for all 12. Check that the output answer count equals the API count before submitting.
  5. Submit all answers together while the JSON body is below 4 MiB. If rejected, use submit_mastery.py to bisect rejected groups; fix a field parser, regenerate the answer file, and send only unresolved IDs.
  6. For disk questions, use mmls first, then multiply each start LBA by 512 to inspect the partition at its byte offset. Keep LBA sequences in table order and keep set-valued metadata arrays in their canonical sorted order.

Files kept in the workspace

  • single-solve-start.json, time-trial-start.json, mastery-start.json: saved live API responses.
  • single-solve-answers.json, time-trial-answers.json, mastery-results/mastery-all-answers.json: accepted answer payloads.
  • solve_bundle.py, solve_mastery.py, submit_mastery.py, disk_layout.py, render_catalog.py, artifact_manifest.py: reusable scripts.
  • challenge-details.md: full player-facing question catalog, required formats, accepted answers, and mode guidance.
  • artifact-manifest.md: nested artifact names, byte counts, SHA-256 values, and purposes.
  • results.json: compact result and flag record.