Gravitational plate of three masses and a slashed discABC0Static engraved plate. Three-dimensional view is unavailable or reduced motion is requested.

← back to fieldarticle

articleSep 18, 2020

CSAW 2019 traveller — high-level notes

CSAW 2019 traveller (trip manager pwn): signed index / integer issue in change path enables out-of-bounds structure access. High-level root cause and mitigations only.

CSAW 2019 traveller — high-level notes

CTF challenge from CSAW 2019: a trip-management ELF (add / change / delete / check trips) used as a pwnable.

Challenge theme

  • Menu-driven allocator around a small trip structure (destination buffer + distance)
  • Fixed-size trip slots; change path takes a user-supplied index
  • Common CTF protections in the original binary notes: NX on, canary/PIE off or weak, partial RELRO (as reported in the source)

Vulnerability class / root cause

  • Signed integer / bounds check weakness on the trip index in the change path: a signed type can accept negative values that still pass a “too large” check, so the index arithmetic can point outside the intended trip array.
  • Conceptually this is an out-of-bounds write through a structure pointer table, not a novel bug class.

Impact (abstract)

In the challenge setting, corrupting adjacent or unintended pointers could hijack control flow and yield arbitrary code execution in the process. Outside CTF, the same pattern in production software is memory corruption with RCE risk if reachable.

Mitigations / lessons

  • Use unsigned indices and reject any value >= slot count (and == sentinel) before pointer math.
  • Prefer safe abstractions (bounds-checked slices) over raw C arrays of pointers.
  • Enable modern hardening (PIE, full RELRO, canary, fortify) as defense-in-depth—not a substitute for correct bounds checks.

Solve steps and PoC omitted.

related

  1. Jul 10, 2026/articleR3CTF 2026 P1gROXY — HTML escape buffer sizing (high-level)
  2. Sep 18, 2020/articleCSAW 2019 popping_caps — High-level Heap Notes
  3. Sep 18, 2020/articleCSAW 2019 small_boi — SROP challenge theme

graphfeed