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

cxm_dec_fw: decoder firmware download loop bounded by hardcoded CXM_FW_SIZE (256 KiB), not the actual object size β€” latent kernel-rodata OOB read if an under-length firmware blob is compiled in

Summary

4-byte NOFW stub, unsized extern (cxm.h:308); the sole consumer copies a hardcoded 256KiB from the array (cxm.c:687-689) with no size validation. Stock stub = dead code (NOFW guard -> ENXIO, no /dev/cxmN); a builder dropping in an under-length real blob gets adjacent rodata OOB-read and DMA'd into card SDRAM (no read-back path to userspace). Build-time hazard only. Export-the-size + refuse-wrong-size fix; twin DF-5238.

Discussion (0)

No comments yet.

PoC verification

Evidence pack

findings/poc/DF-5237 Β· 1 files
FileTypeDescriptionSize
verdict.json file 1.0 KB view raw

Fix verification

not_testable
baseline no→ patch + rebuild →patched clean
per-fix-DF-5237

Confirmed kernel references

Detail

Evidence (decisive lines)

static trace: unsized extern + hardcoded CXM_FW_SIZE loop (cxm.c:681-689)

Verified recommended fix

export fw size symbol + refuse size != CXM_FW_SIZE before copy

Verdict

untested (Info build-time hazard; requires Conexant HW + hand-built wrong-size fw blob)