⬢ DragonFlyBSD Kernel Audit
DF-3757 / verdict.json
← back to finding ↓ download raw
{
  "finding_id": "DF-3757",
  "status": "not_reproduced",
  "reproduced": 0,
  "impact": "none",
  "confidence": "likely",
  "verdict": "tulip_txput_setup() (if_de.c:3631-3636) defers on `ri->ri_free == 1 but not on `ri->ri_free == 0. With all 128 TX descriptors chip-owned (saturation; tulip_tx_intr reclaims nothing, if_de.c:3169), the setup-frame path falls through: ri_free underflows to -1 (if_de.c:3644), the setup frame is programmed over a chip-owned in-flight descriptor (if_de.c:3645-3675), tulip_tx_intrs SETUPPKT branch then skips m_freem for the clobbered packet (if_de.c:3176-3202) leaking mbuf+cluster, and KASSERT clobbering earlier tx mbuf (if_de.c:3544) panics INVARIANTS kernels on descriptor reuse. Unprivileged trigger on hardware: IP_ADD_MEMBERSHIP -> if_addmulti -> ifp->if_ioctl(SIOCADDMULTI) with no join privilege (if.c:2738-2739) while the ring is 100% in flight. A 1:1 logic model built and run on the audit guest CONFIRMED the underflow and descriptor-ownership violation (run.log, exit 0); the kernel path needs a live de(4) NIC under TX saturation and the guest has zero DEC 2114x hardware (env.txt), hence not_reproduced. Expected real-world impact: unprivileged local DoS (panic/mbuf exhaustion) on machines with a de(4) NIC, timing-window dependent.",
  "exploit_chain": "",
  "evidence": "run.log: ri->ri_free = -1 (UNDERFLOW) + setup frame programmed over descriptor 0 (chip-owned before write: YES); VERDICT.md cites the guard line 3633, underflow 3644, SETUPPKT skip 3176-3202, KASSERT 3544, and the unprivileged join path if.c:2739.",
  "kernel_refs": [
    "sys/dev/netif/de/if_de.c:3631-3636",
    "sys/dev/netif/de/if_de.c:3644",
    "sys/dev/netif/de/if_de.c:3176-3202",
    "sys/dev/netif/de/if_de.c:3544",
    "sys/net/if.c:2738-2739"
  ],
  "poc_changes": "No seed PoC; authored 1:1 guard/reclaim model from scratch, compiled clean on first attempt (gcc 8.3 guest).",
  "attempts": 1,
  "guest_uname": "DragonFly dfbsd 6.5-DEVELOPMENT DragonFly 6.5-DEVELOPMENT #0: Thu Jul 2 06:02:54 UTC 2026 root@dfbsd:/usr/obj/usr/src/sys/X86_64_GENERIC x86_64",
  "runtime_sec": 120,
  "guest_dirty": 0,
  "build_cmd": "cc -O2 -Wall -o txput_setup_guard_model txput_setup_guard_model.c",
  "run_cmd": "./txput_setup_guard_model; echo exit=$?",
  "code_hash": "7f5ced84f295de02de07911a89cae3f00f736759aa8faabac074a2bc060cb50c",
  "notes": "Severity Medium per local-DoS rubric on de-equipped machines; requires the physical NIC, so unverifiable on this guest. Fix is a one-character-class change (== 1 -> < 2).",
  "recommended_fix": "if_de.c:3633: change `ri->ri_free == 1 to `ri->ri_free < 2 so a completely full ring defers instead of underflowing.",
  "fix_status": "not_testable",
  "fix_baseline_reproduced": 0,
  "fix_patched_reproduced": 0,
  "fix_verdict": "fix.diff authored (== 1 -> < 2 at if_de.c:3633); not kernel-tested: no de(4) hardware on the guest, baseline itself cannot run.",
  "fix_evidence": "fix.diff; logic model encodes both the buggy guard and the corrected < 2 semantics."
}