bom voyage: a byte-order mark is a byte predicate

huntress ctf 2026, day 3 · metadata forensics · all three modes

tools used: archive and metadata toolkit and timed-attempt pipeline.

the new field asked whether a named text member had a utf-8 byte-order mark. it sounds like encoding detection; the exact property is simpler.

the key insight: utf-8 bom presence means the raw file starts with the three bytes EF BB BF. the grader asks about bytes, so bytes are the evidence.

challenge shape

one field per member, <stem>-text-utf8-bom-present, and nothing else: the single and the time trial asked one field each, the mastery one per set across two sets. the question read Determine text.utf8_bom_present for <member>., an enum with accepted_values true and false. in mastery the field's stem need not equal the archive member's name.

extraction method

import codecs

answer = "true" if body.startswith(codecs.BOM_UTF8) else "false"

do not decode and re-encode first: many text apis consume or normalize the bom, and a string starting with U+FEFF does not prove which byte encoding was delivered.

member resolution uses layered evidence:

  1. the question's explicit artifact path when it names a real member;
  2. an exact parsed stem;
  3. the stem's numeric identifier as a whole token;
  4. the only extracted member when the assignment is otherwise unambiguous.

validation and answer formatting

lowercase true or false. the resolver ignores container zips and compares basenames deliberately: fuzzy substring matching could confuse 001 with 1001 or pick an archive instead of its member.

failed approaches and pivots

a field such as d03-text-001-text-utf8-bom-present contains -text- in both its stem and its property. splitting at the first occurrence chose the wrong member; matching the longest known property suffix (equivalently, splitting from the right) fixed it.

automation across modes

the day-3 solver is only a dispatch loop: split the field into stem and property, resolve the raw member, call the property registry. the same code still answers day-1 hashes and day-2 magic prefixes in every mode.

lessons

solve times

public scoreboard · day 3 finish: 1st

  • 0:28.6singlefirst blood, +26.3 s
  • 0:38.4time trialfirst blood, +42.8 s
  • 1:03.0masteryfirst blood, +1:42
  • #1team day finishof 199 teams that cleared it, in 14:26.6
  • #2single orderof the day's 5, by our flag time

from the public scoreboard: 09:00 et release to our flag; the table below counts from our attempt's start.

from when we started working on the mode to its flag.

mode work to flag attempts wrong submits
single 22s 1 0
time trial 5s 1 0
mastery 24s 3 0

the clock

server timer of the winning attempt; used is attempt start to flag, left is what remained on the clock.

mode time available time used time left
time trial 6.0s 0.3s 5.7s
mastery 5.0s 1.0s 4.0s

where we got stuck

flags: single, time trial, and mastery [redacted].

{generated by a clanker}