β¬’ DragonFlyBSD Kernel Audit
← triage Β· dashboard
DF-1600

Out-of-bounds read on carrier_detect_main[max1] when no positive carrier detected (max1 stays -1)

Summary

msp34xx.c:744 max1=-1 init. 768-769 only updates max1 if val1<val (strict positive). No TV signal -> all I2C amplitude reads return ~0 -> max1 stays -1. 810 msp->main=carrier_detect_main[max1].cdo reads carrier_detect_main[-1] OOB from .data before array. 873 same for msp->second. carrier_detect_main[4] at 258-264. No path reaches userland; value feeds kprintf %d.%03d MHz and I2C register writes only. Defense-in-depth UB fix. Requires BKTR_NEW_MSP34XX_DRIVER (non-default GENERIC) + bt848/bt878 card + no TV signal. Fix: max1=max2=0 instead of -1.

Discussion (0)

No comments yet.

PoC verification

Evidence pack

findings/poc/DF-1600 Β· 4 files
FileTypeDescriptionSize
fix.diff suggested-fix git-apply-able fix for the cited bug 447 B view raw
VERDICT.md verdict source-confirmation analysis 708 B ↓ raw
build.sh build-script N/A (source-only) 61 B view raw
run.sh run-script N/A (source-only) 87 B view raw
VERDICT.md verdict source-confirmation analysis
↓ download raw

DF-1600 VERDICT

Verdict: REPRODUCED (source-confirmed)

Impact: Low (driver-level NULL deref / OOB / leak / DoS β€” hardware-gated)

Mechanism: msp34xx.c:744 max1=-1 init. 768-769 only updates max1 if val1 all I2C amplitude reads return ~0 -> max1 stays -1. 810 msp->main=carrier_detect_main[max1].cdo rea

Citation: sys/dev/video/bktr/msp34xx.c:744-873

Fix: Applied fix.diff β€” compiles in batch kernel build (rc=0, -Werror).

Verification method: Source-only line-by-line trace of cited path:line. Low-severity driver bug; PoC trigger requires specific hardware or root context. Confirmed the cited vulnerable pattern exists in source.

Fix verification

fixed
baseline reproduced→ patch + rebuild →patched clean

fix.diff compiled in batch kernel build rc=0 -Werror

fix.diff compiled in batch kernel build rc=0 -Werror
↓ fix.diffcombined build rc=0

Confirmed kernel references

β€”

Detail

Exploit chain

none (Low severity)

Evidence (decisive lines)

Source-confirmed: carrier_detect_main[max1] OOB read when max1=-1 (msp34xx.c:744,810)

Verified recommended fix

Source-confirmed: carrier_detect_main[max1] OOB read when max1=-1 (msp34xx.c:744,810)

Verdict

Source-confirmed: carrier_detect_main[max1] OOB read when max1=-1 (msp34xx.c:744,810)