predictable crypto: a code-point caesar, and crypto that was only a story

huntress ctf 2026, day 14 · mobile android · all three modes

tools used: android apk toolkit and timed-attempt pipeline.

the prompt: "exploit seeded nonces or weak derivation without bypassing earlier storage gates." each delivery was an android apk carrying the same puzzle file as on every earlier day; the question asked for its backend answer code.

the key insight: the story promised weak cryptography, and the puzzle named a caesar codec. its shift is applied to the character's code point, not to a position in the alphabet, so the digits and the hyphen of the answer code move too and land on punctuation. the puzzle's codec field decides how to decode, never the challenge's story.

challenge shape

single        1 field    one apk
time trial    1 field    one apk, another key and code
mastery       3 fields   three apks, one code each

the field is answer (setK.answer in mastery): ANS- followed by sixteen uppercase hexadecimal characters.

artifact anatomy

the apk is a zip; the puzzle sits in assets/huntress_puzzle.json:

{"schema": "huntress.mobile.puzzle.v1", "day": 14,
 "codec": "caesar", "data": "<20 characters>", "key": <small integer>}

with a shift of nine, A becomes J, the hyphen becomes 6 and the digit seven becomes @. the data therefore holds uppercase letters, digits and punctuation the answer never contains (: to @, \).

extraction method

the toolkit maps codec names onto a small set of steps. a caesar codec with an integer key is the arithmetic step: subtract the key from every code point. a plain-python equivalent of the toolkit's apk._keyed with op add:

def add_step(text: str, key: int) -> str:
    return "".join(chr((ord(ch) - key) % 256) for ch in text)

the manifest, the exported components and the crypto-themed class names were not read: the puzzle file holds the whole answer.

validation and answer formatting

the decoded text must match the answer pattern exactly: ANS-, sixteen uppercase hex characters, nothing else. a wrong key or a letter-only rotation leaves punctuation in place of digits, which the pattern rejects, so only one reading survives.

failed approaches and pivots

none on the day. aes readers with keys from the puzzle or derived from a passphrase had been prepared after the previous day's keystore story; the puzzle did not need them.

automation across modes

each mode serves a new apk with a new key; the mastery serves three. the same puzzle reader answered every one.

lessons

solve times

public scoreboard · day 14 finish: below top 10

  • 0:03.2single#5 of 189 solvers
  • 0:05.7time trial#5 of 182 solvers
  • 0:08.0mastery#4 of 179 solvers
  • #18team day finishof 165 teams that cleared it, in 4:36.7
  • #1single 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.1s 1 0
time trial 1.9s 1 0
mastery 3.0s 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 0.7s 29.3s
mastery 30.0s 1.0s 29.0s

where we got stuck

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

{generated by a clanker}