Skip to content

redteam: task 5.9 — RT-6 UDS suite (rt-6-1..6): 74/74 green, two new findings (#400, #401), one refuted premise - #402

Merged
randomizedcoder merged 2 commits into
mainfrom
feat/redteam-rt-6-1-rt-6-6
Dec 6, 2026
Merged

randomizedcoder merged 2 commits into
mainfrom
feat/redteam-rt-6-1-rt-6-6

Conversation

@randomizedcoder

Copy link
Copy Markdown
Owner

Phase 5, task 5.9 — the RT-6 UDS suite. All six scenarios pass; three BLOCKED, three CONFIRMED.

Results

Row Verdict Asserts Evidence The finding
rt-6-1 UDS symlink attack BLOCKED 13/13 20261205T181303-4a9a9345b-3515947 all three shapes refused (a symlink, a regular file, and a symlink pointing at a LIVE socket — the Lstat never follows, the stale-unlink never reaches the real one); the attack files survive untouched
rt-6-2 stale-socket unlink DoS CONFIRMED — #400 10/10 20261205T181938-4a9a9345b-3973716 the default policy unlinks a LIVE service's socket, no liveness probe; the victim process still runs, orphaned on an unlinked inode, while the twin answers /healthz on the victim's path. unlinkStale=false refuses by name and the victim survives (the regression guard)
rt-6-3 socket replacement race CONFIRMED — #400 10/10 20261205T201441-4a9a9345b-1022919 the chmod enforcement is real (the daemon's own dirs 0750, sockets 0600 — a non-root same-container process cannot unlink from them); the world-writable parent is the hole: the attacker's fake socket owns the path, the daemon never notices. The documented requirement: dir 0700, owned by the daemon user
rt-6-4 baseline poisoning CONFIRMED — #401 17/17 20261205T212243-4a9a9345b-1502677 the corrupt baseline degrades safely (gauge 0, counted, TCP collection unaffected — the runLinkMonitor contract, repeated on Ubuntu/Docker), but the CRAFTED-VALID baseline is accepted with no integrity check and drives go_link_monitor_up_links_delta = -99997 — a fake ~100k 'links missing' alert from ONE file write
rt-6-5 secret-file modes audit BLOCKED 10/10 20261205T221425-4a9a9345b-1938524 the plan's premise is STALE: the listener REFUSES a group/world-readable secret file at startup ('a secret file must not be accessible by group or others', chmod 0400, Kubernetes defaultMode: 0400) — the row's 'consider refusing' is already the product behavior. The read-side audit stands: the 0644 file is still world-readable on the mount (the refusal stops the use, not the read)
rt-6-6 GOIP_WRITE_OUT confinement BLOCKED 14/14 20261205T235143-4a9a9345b-2820953 the goip_write-tagged goip (docker-cp'd into the daemon's own container) writes the request FILE only (the loopback flags, the route table, the daemon all unchanged); without the variable the verbs refuse outright; /ip is OFF by default, and with -linkMonitorIPPaths the read verbs serve while the write verb is refused 400 BY NAME (no write encoder in the binary — the no-write-encoders flake check)

Issues

Harness

  • goip added to redteam-attacker-tools (static, goip_write-tagged — rt-6-6's in-container toolkit, the rt-5-3 busybox pattern).
  • The six new apps auto-generate from the scenario files; the matrix gains the six rows (48 → 54).

Harness lessons (in the findings.md rows + the DoD row)

  1. A bind-mounted socket dir is DOCKER'S (0755), not the daemon's — the 0750 socketDirMode only creates, it never tightens. The chmod-enforcement leg must measure the daemon's own /run tree, not the bind.
  2. A class is served by exactly ONE listener (metrics+metrics is a config error, ip needs -linkMonitorIPPaths, debug needs an admin credential — grpc-read is the flagless read class).
  3. A twin with NO -dest runs the KAFKA default and dies of redpanda retries ~30 s in — every twin pins -dest.
  4. The expected-refusal exit code must be captured with the &&/|| idiom, never the bare $? after the command (set -e kills the scenario first).
  5. goip's loopback prints 'state UNKNOWN' — the up/down signal is the flags list, not the state keyword.

Docs

  • docs/redteam-plan.md: all six rows VERIFIED.
  • docs/redteam-implementation.md: task 5.9 ticked + the part-4 DoD row.
  • vagrant/redteam/findings.md: six rows with the full mechanisms + the per-run harness lessons.
  • docs/security.md: the UDS-path-attacks + secret-files sections (the measured enforcement and the private-parent-dir requirement).

Matrix

The 54-row matrix regression runs on the branch head before the PR lands; the DoD row carries the number when it lands.

…product findings (#400, #401), one refuted premise

All six rows green:
- rt-6-1 UDS symlink attack: BLOCKED 13/13 (20261205T181303-4a9a9345b-3515947)
  — all three shapes refused (a symlink, a regular file, and a symlink
  pointing at a LIVE socket: the Lstat never follows, the stale-unlink
  never reaches the real one); the attack files survive untouched.
- rt-6-2 stale-socket unlink DoS: CONFIRMED 10/10
  (20261205T181938-4a9a9345b-3973716) — the default policy unlinks a
  LIVE service's socket, no liveness probe; the victim process still
  runs, orphaned on an unlinked inode, while the twin answers /healthz
  on the victim's path. unlinkStale=false refuses by name and the victim
  survives (the regression guard). Issue #400.
- rt-6-3 socket replacement race: CONFIRMED 10/10
  (20261205T201441-4a9a9345b-1022919) — the chmod enforcement is real
  (the daemon's own dirs 0750, sockets 0600, a non-root same-container
  process cannot unlink from them); the world-writable parent is the
  hole (the attacker's fake socket owns the path, the daemon never
  notices). The documented requirement: dir 0700, owned by the daemon
  user. Issue #400's doc arm.
- rt-6-4 baseline poisoning: CONFIRMED 17/17
  (20261205T212243-4a9a9345b-1502677) — the corrupt baseline degrades
  safely (gauge 0, counted, TCP collection unaffected — the
  runLinkMonitor contract, repeated on Ubuntu/Docker), but the
  crafted-valid baseline is accepted with no integrity check and drives
  go_link_monitor_up_links_delta = -99997 — a fake ~100k 'links
  missing' alert from ONE file write. Issue #401.
- rt-6-5 secret-file modes audit: BLOCKED 10/10
  (20261205T221425-4a9a9345b-1938524) — the plan's premise is STALE:
  the listener REFUSES a group/world-readable secret file at startup
  ('a secret file must not be accessible by group or others', chmod
  0400, Kubernetes defaultMode: 0400). The row's 'consider refusing
  world-readable secret files at startup' is already the product
  behavior. The read-side audit stands: the 0644 file is still
  world-readable on the mount (the refusal stops the use, not the
  read).
- rt-6-6 GOIP_WRITE_OUT confinement: BLOCKED 14/14
  (20261205T235143-4a9a9345b-2820953) — the goip_write-tagged goip
  (docker-cp'd into the daemon's own container) writes the request FILE
  only (the loopback flags, the route table, the daemon all
  unchanged); without the variable the verbs refuse outright; /ip is
  OFF by default, and with -linkMonitorIPPaths the read verbs serve
  while the write verb is refused 400 BY NAME (no write encoder in the
  binary — the no-write-encoders flake check).

Harness: goip added to redteam-attacker-tools (static, goip_write —
rt-6-6's in-container toolkit, the rt-5-3 busybox pattern); the six
new apps auto-generate from the scenario files.

Harness lessons (in the findings.md rows + the DoD row): a
bind-mounted socket dir is DOCKER'S (0755), not the daemon's — the
0750 socketDirMode only creates, it never tightens; a class is served
by exactly ONE listener (metrics+metrics is a config error, ip needs
-linkMonitorIPPaths, debug needs an admin credential — grpc-read is
the flagless read class); a twin with NO -dest runs the KAFKA default
and dies of redpanda retries ~30 s in; the expected-refusal exit code
must be captured with the &&/|| idiom, never the bare $? (set -e
kills the scenario first); and goip's loopback prints 'state UNKNOWN'
— the up/down signal is the flags list.

Docs: plan rows VERIFIED, task 5.9 ticked + the part-4 DoD row,
findings.md rows, security.md's UDS-path-attacks + secret-files
sections.

The 54-row matrix regression runs on the branch head before the PR
lands.
…the rt-4-6 driver-underrun flake, solo re-run PASS 16/16)
@randomizedcoder

Copy link
Copy Markdown
Owner Author

Final regression (the DoD row): the 54-row matrix on the branch head aebef83a1 — 53/54 PASS + rt-4-6 FAIL (20261206T020955-aebef83a1-3637319).

The one failure is a harness-side driver underrun, not a product regression: only 79 churn cycles — the driver under-ran (target ~240) — the assert fired on the driver's own telemetry, and rt-4-6 was green in task 5.8's 48-row run on the same daemon code path.

Solo re-run of rt-4-6 on the same commit: PASS 16/16 (20261206T032052-aebef83a1-4118058) — the flake is the driver's, not the daemon's.

All six rt-6 rows passed inside the matrix run itself (rt-6-1 BLOCKED, rt-6-2 CONFIRMED, rt-6-3 CONFIRMED, rt-6-4 CONFIRMED, rt-6-5 BLOCKED, rt-6-6 BLOCKED — every one matching its expected verdict).

@randomizedcoder
randomizedcoder merged commit 173217a into main Dec 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant