DF-4983 / verdict.json
{ "finding_id": "DF-4983", "status": "untested", "reproduced": 0, "impact": "none", "confidence": "certain", "verdict": "Certain dead-cleanup defect by source trace: cxm_iic_detach (cxm_i2c.c:229) clears CXM_IVAR_IICBUS with return ignored, but cxm_write_ivar (cxm.c:2115-2118) rejects any write when sc->iicbus is already set โ always the case at detach โ so cxm_softc.iicbus permanently dangles to the destroyed iicbus device_t after iic teardown; sensor sub-drivers deref it 27+ times (cxm_saa7115.c:678+, cxm_msp34xxx.c:295+). Non-racy cxm attach/detach orders never deref after teardown (checked); realistic deref requires the known DF-4753/DF-4419 detach-vs-ioctl race, which this bug arms with a second freed object that the intended invalidation hook can never reclaim. Not runnable on the reference guest: cxm never attaches without a Conexant iTVC15/16 card (verified cxm.ko resident, /dev/cxm absent).", "exploit_chain": "", "evidence": "VERDICT.md (line-accurate proof incl. the sc->cxm_iic vs sc->iicbus invalidation asymmetry); df4983_cxm_iic_stale_ivar.c (annotated trigger sketch: unpriv ioctl loop + kldunload cxm); fix.diff (write_ivar val==0 clears unconditionally)", "kernel_refs": ["sys/dev/video/cxm/cxm_i2c.c:229", "sys/dev/video/cxm/cxm_i2c.c:220", "sys/dev/video/cxm/cxm.c:2100", "sys/dev/video/cxm/cxm.c:2115", "sys/dev/video/cxm/cxm.c:2118", "sys/dev/video/cxm/cxm.c:2066", "sys/dev/video/cxm/cxm.c:622", "sys/dev/video/cxm/cxm_saa7115.c:678"], "poc_changes": "Authored fresh; no pass-1 seed existed for cxm_i2c.c", "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": "", "code_hash": "", "notes": "Hardware-gated (Conexant iTVC15/16 capture card required; guest verified without one). The racy dereference window itself is the already-filed DF-4753/DF-4419 cxm family detach race โ not re-reported; this finding is the cxm_i2c.c-owned defect making the iicbus pointer un-invalidate-able.", "recommended_fix": "cxm_write_ivar: treat val==0 as an unconditional detach-time clear; keep the set-once EINVAL guard for non-zero values", "fix_status": "not_applicable", "fix_baseline_reproduced": 0, "fix_patched_reproduced": 0, "fix_verdict": "No baseline reproducible on the available guest (no cxm hardware -> /dev/cxm never exists), so no A/B fix validation; fix.diff makes the cxm_i2c.c:229 invalidation actually take effect while preserving set-once attach semantics", "fix_evidence": "fix.diff (cxm.c write_ivar 0-case clear) in this pack" } |