⬢ DragonFlyBSD Kernel Audit
DF-5136 / verdict.json
← back to finding ↓ download raw
{
  "finding_id": "DF-5136",
  "status": "untested",
  "reproduced": 0,
  "impact": "none",
  "confidence": "likely",
  "verdict": "vbt_sdvo_panel_type is registered as a raw int tunable (i915_params.c:68) and consumed at intel_bios.c:357-381 as an element index into the VBT BDB_SDVO_PANEL_DTDS section with only the exact magic values -2/-1 special-cased — any other value (negative or huge) drives dvo_timing + index out of bounds (36 bytes/element) in the mapped VBT blob, then into fill_detail_timing_data and the SDVO/LVDS mode. Not executed: the audit guest has no Intel GPU, i915 never attaches, and intel_bios_init()/parse_sdvo_panel_data are unreachable there — a hardware-precondition gap, not a refutation. Root-set boot tunable + old-SDVO-VBT precondition => Low.",
  "exploit_chain": "root loader.conf/kenv drm.i915.vbt_sdvo_panel_type=<n> (n not in {-2,-1}) -> i915 attach on hardware with BDB_SDVO_PANEL_DTDS -> parse_sdvo_panel_data -> fill_detail_timing_data(dvo_timing + n) -> OOB read (panic on large n; garbage mode/possible kernel-log disclosure on moderate n).",
  "evidence": "README.md/VERDICT.md: full source trace with line cites; run.sh documents why no trigger exists on the guest.",
  "kernel_refs": [
    "sys/dev/drm/i915/i915_params.c:68",
    "sys/dev/drm/i915/intel_bios.c:357",
    "sys/dev/drm/i915/intel_bios.c:381"
  ],
  "poc_changes": "No seed; analysis-only pack. fix.diff authored from source (clamp index to 0..0xf after the -1/-2 handling).",
  "attempts": 0,
  "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": 0,
  "guest_dirty": 0,
  "build_cmd": "",
  "run_cmd": "not runnable: no Intel GPU on the audit guest (i915 never attaches)",
  "code_hash": "",
  "notes": "Same-family hardening as the upstream Linux clamp of panel_type; the negative-index window (-3 and below) reads BEFORE the section, which the upstream-style check must also cover (index < 0 || index > 0xf).",
  "recommended_fix": "Clamp index to 0..0xf after the -2/-1 handling in parse_sdvo_panel_data (intel_bios.c:371), see fix.diff.",
  "fix_status": "not_testable",
  "fix_baseline_reproduced": 0,
  "fix_patched_reproduced": 0,
  "fix_verdict": "Not testable on this guest (no Intel GPU); the one-line clamp is trivially correct against the source trace.",
  "fix_evidence": "fix.diff (unified diff against sys/dev/drm/i915/intel_bios.c)."
}