# VERDICT -- DF-1389

## Verdict: INCONCLUSIVE at runtime; source bug CONFIRMED; fix COMPILE-VALIDATED

**Citations confirmed:**
  - sys/dev/drm/i915/intel_bios.c:169
  - sys/dev/drm/i915/intel_bios.c:170
  - sys/dev/drm/i915/intel_bios.c:173
  - sys/dev/drm/i915/intel_bios.c:175
  - sys/dev/drm/i915/intel_bios.c:177

### Is the bug real? -- YES (source trace)

get_lvds_dvo_timing() computes lfp_data_size = ptr[1].dvo - ptr[0].dvo and
    dvo_timing_offset = ptr[0].dvo - ptr[0].fp from VBT-controlled u16 offsets,
    then `entry = data + lfp_data_size * index + dvo_timing_offset` with NO
section bounds check. Unlike the sibling get_lvds_fp_timing (:183-200) which
validates against `data_ofs + data_size`. Crafted VBT ptrs -> entry past section
-> OOB read exposed via connector mode list.

### Can it be reproduced on this guest? -- NO (hardware-gated)

No Intel iGPU in PCI list; i915.ko not loaded.

The i915 driver is a loadable module only (NOT in `X86_64_GENERIC`), is not loaded, and cannot be `kldload`'d by an unprivileged user (kldload is root-only). Even loaded, it would not attach without the hardware.
Therefore the vulnerable code is unreachable at runtime here. Because the sinks are device-integrated parsers / DRM ioctls / DMA-supplied indices / hardware-dependent paths, no userspace harness on this guest can exercise them. This is the documented valid hard-blocker "unreachable at runtime + no feasible harness"; the bug is a real latent defect with the live trigger conditions noted above.

### No escalation chain (and why that is correct here)
There is no memory-corruption primitive to escalate on this guest: the corruption sinks live entirely inside the not-attached driver behind hardware that is absent. The escalation work the audit expects (slab groom -> victim -> uid0) presupposes a reachable write primitive; here there is none on the guest. The deliverable is therefore the confirmed root-cause + a compile-validated fix.

### Fix (fix.diff) -- authored and COMPILE-VALIDATED
Mirrored get_lvds_fp_timing's bounds check: read the section u16 size from the
header before lvds_lfp_data, then validate `want > data_size ||
want + sizeof(struct lvds_dvo_timing) > data_size` and return NULL. (matches
finding proposal: mirror fp_timing bounds check.)

The fix was applied to in-guest `/usr/src` (all hunks applied cleanly) and the
module was rebuilt with the kernel's `-Werror` flags: `cd /usr/src/sys/dev/drm/i915 && KERNCONF=X86_64_GENERIC SYSDIR=/usr/src/sys make -m /usr/src/share/mk` => rc=0 (see `build_fix.log`). No warnings or errors in the patched translation unit. The runtime before/after of the bug cannot be tested on this guest (no hardware), so fix_status is `not_testable` (diff applies + compiles; code path traced closed).

### Why not `not_reproduced` (false-positive)?
This is NOT a false positive. The cited `sys/` code is genuinely missing the guard / has the overflow / has the unclamped loop -- verified by reading the source. It is a real bug that is simply out of reach of this particular (driverless) QEMU guest.
