d-day: a d language elf, and a configuration blob that was base64 text in .rodata

huntress ctf 2026, day 11 · binary reverse engineering · all three modes

tools used: binary-analysis toolkit and timed-attempt pipeline.

the prompt: "d templates generate code the way a printing press generates pages — fast, and everywhere. trace the runtime's template expansions back to the collection config they built." the new tag, d11, was a build of a d program: an x86-64 elf in every delivery, carrying the lane's hcfg configuration blob.

the key insight: the d11 fields were day 9's fields, not day 10's. day 10 asked whether the build keeps the blob in a section of its own; day 11 asked again where the blob starts, and this build had no .hcfg section at all. the blob was base64 text inside .rodata, so the offset is where that text begins, the rule day 9's nim build established. no field asked about templates.

challenge shape

the single asked 110 fields, ten per tag for d01 to d11, over one evidence zip of about 32 mb; the time trial asked the same 110 of a fresh zip, the mastery 330 over three. the ten d11 fields:

d11_artifact_sha256_1            exact text   sha-256 of the delivered member
d11_analysis_architecture        exact text
d11_analysis_format              exact text
d11_analysis_machine             integer      base 10
d11_analysis_config_campaign     exact text   } from the hcfg blob
d11_analysis_config_domain       exact text   }
d11_analysis_config_mutex        exact text   }
d11_analysis_config_url          exact text   }
d11_analysis_config_crc32_hex    pattern      } lowercase hex with a 0x prefix
d11_analysis_hcfg_offset         integer      base 10

the d10 member was again a pe in one mastery set, as on day 10. the variants repeated across modes: the time trial's zip and the first mastery set held the same members, and the second mastery set repeated the single's d11 build.

artifact anatomy

the d11 member is a d program compiled to a native elf and left unstripped, with debug information. the d runtime shows in several independent places:

_Dmain                 the d entry point, called by the runtime's c main
_D...                  d-mangled symbols (module, name, type)
__minfo                the section holding the module-info records
druntime strings       the runtime's own messages in .rodata

the hcfg blob has the layout the toolkit article describes: the HCFG magic, a version, a one-byte xor key, the length, a crc32 of the plaintext, and the xor-encoded json. this build stores it base64-encoded, as a string in .rodata, so the raw magic never appears in the file. the encoded magic does: base64 of HCFG begins SENGR, and that prefix is the anchor the search looks for.

extraction method

the dispatch is the same as on every day since day 3: the field's tag selects the member, the member's format selects the reader. the sha-256, format, architecture and machine come from the elf header and the delivered bytes. the config fields and the offset come from one carrier search that looks for the blob in every form the lane has used: raw, xor-wrapped, base64 or hex text, in ascii or utf-16.

for a text carrier the search finds the encoded magic, extends the run of characters of that alphabet, decodes it and checks that a valid blob comes out:

for form in forms:
    anchor = form.anchor.decode().encode(encoding)
    run = _pattern(form, encoding)
    at = d.find(anchor)
    while at >= 0:
        m = run.match(d, at)
        text = m.group() if m else b""
        for raw in form.decodings(text):
            h = elf._hcfg_at(raw, 0)
            if h is not None:
                out.append((at, ..., h))
                break
        at = d.find(anchor, at + 1)

the offset field answers with the file offset of the literal's first base64 character in the elf as extracted from the evidence zip: not a position in the decoded bytes, and not a position in the zip. that is the reading graded for day 9's nim build, whose string literal held the same encoded blob. by hand:

7z e -pinfected evidence.zip 'd11*'
strings -a -t d d11--variant-NNN.elf | grep SENGR

a d string literal has no flag byte in front of it (nim's has @), so the decimal offset strings prints is the answer as it stands.

validation and answer formatting

a decoded blob counts only if it starts with the magic, its length fits the decoded bytes, the crc32 of the decrypted json matches the one in the header, and the json parses as an object. if two carriers in one member decode to different valid blobs, the reader raises instead of choosing. the config values are the json's values verbatim: the mutex keeps its single backslash, and the crc32 field is the header's value as eight lowercase hex digits after 0x, zero-padded. the machine is e_machine in decimal; the format and architecture are the labels the lane's grader has accepted before, elf and x86-64.

automation across modes

the day 10 solver answered all 110 fields of the single and the time trial and 330 of the mastery, without a change: the d11 member was found by its tag, the elf readers answered the header fields, and the carrier search found the base64 text. day 10's section-table producer was not needed, because no d11 field asked about a section.

lessons

solve times

public scoreboard · day 11 finish: 1st

  • 0:02.7singlefirst blood, +1.4 s
  • 0:06.2time trialfirst blood, +0.25 s
  • 0:10.1masteryfirst blood, +0.80 s
  • #1team day finishof 164 teams that cleared it, in 0:10.1
  • #4single 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 2.2s 1 0
time trial 3.5s 1 0
mastery 3.9s 1 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 30.0s 2.1s 27.9s
mastery 30.0s 2.7s 27.3s

both timed attempts came from the grader's regular pool and were marked not eligible for the hall of fame; each still carried a 30-second deadline, and the flags and their board times count.

where we got stuck

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

{generated by a clanker}