⬢ DragonFlyBSD Kernel Audit
DF-3784 / verdict.json
← back to finding ↓ download raw
{
  "finding_id": "DF-3784",
  "status": "reproduced",
  "reproduced": 1,
  "impact": "leak",
  "confidence": "certain",
  "verdict": "REPRODUCED at source level (decision-logic harness): with iov_len=0x80000000 the (int) cast yields -2147483648; neither guard rejects it; uiomoves n = 0xffffffff80000000 and its loop copies MIN(2GiB, n) = 2147483648 bytes from vbibuffer. The 2 GiB kernel disclosure itself needs the device (VBI data must exist) and cannot run on this guest.",
  "exploit_chain": "open /dev/vbi0 (0444) + continuous PAL capture on /dev/bktr0 -> read(/dev/vbi0, buf, 0x80000000) -> (int) truncation -> uiomove with n=0xffffffff80000000 -> 2 GiB of kernel VA copied to userspace until EFAULT; vbisize/vbistart corrupted.",
  "evidence": "run.log: step-by-step guard evaluation showing every check bypassed and the final 2 GiB copy length; post-state corruption vbisize=-2147418112.",
  "kernel_refs": [
    "sys/dev/video/bktr/bktr_core.c:1159",
    "sys/dev/video/bktr/bktr_core.c:1161",
    "sys/dev/video/bktr/bktr_core.c:1165",
    "sys/dev/video/bktr/bktr_core.c:1177",
    "sys/kern/kern_subr.c:uiomove",
    "sys/kern/sys_generic.c:136"
  ],
  "poc_changes": "none (warnings only); PoC trigger needed -lpthread",
  "attempts": 2,
  "guest_uname": "DragonFly dfbsd 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": 180,
  "guest_dirty": 0,
  "build_cmd": "cc -O -Wall -o harness harness_vbi_read.c",
  "run_cmd": "./harness",
  "code_hash": "23eaf5761d10a292f89b601de4875915ee11b018061223f5a884f1f68601e003",
  "notes": "video_read() has the same (int) cast but its lower-bound check rejects it by accident.",
  "recommended_fix": "Reject readsize <= 0 in vbi_read (fix.diff)",
  "fix_status": "not_testable",
  "fix_baseline_reproduced": 1,
  "fix_patched_reproduced": 0,
  "fix_verdict": "Runtime fix validation impossible on this guest (no Bt848/878 hardware, driver not in GENERIC, no module dir). fix.diff applies cleanly to sys/ and the patched bktr KLD module compiles with -Werror on the guests /usr/src (fix_build.log).",
  "fix_evidence": "fix.diff; fix_build.log (all-8-fixes module build, MAKE_RC=0)"
}