Uninitialized kernel heap memory disclosure via ATH_DIAG_DYN on non-output spectral control commands
Summary
ath_ioctl_spectral (if_ath_spectral.c:218): outdata=kmalloc(outsize,M_TEMP,M_INTWAIT) -- M_INTWAIT is wait-policy NOT M_ZERO. START/STOP/SET_PARAMS/ENABLE_AT_RESET/ENABLE/DISABLE never write outdata; lines 282-285 unconditionally copyout ad_out_size bytes of unwritten heap buffer to userland. Stale kernel heap (net buffers/credential fragments/keys) disclosed to unprivileged local user. Repeated triggers sample heap churn. Fix: M_INTWAIT|M_ZERO.
Discussion (0)
PoC verification
Evidence pack
findings/poc/DF-2080 Β· 2 files| File | Type | Description | Size | |
|---|---|---|---|---|
| fix.diff | suggested-fix | git-apply-able fix | 388 B | view raw |
| VERDICT.md | verdict | source-trace confirmation | 640 B | β raw |
DF-2080 β ath_ioctl_spectral uninitialized outdata leaked to userspace
Verdict
REPRODUCED (source-only confirmation). Bug confirmed by source tracing.
Mechanism
ath_ioctl_spectral() (if_ath_spectral.c:218) allocates outdata=kmalloc(outsize,M_TEMP,M_INTWAIT) without M_ZERO. START/STOP/SET_PARAMS/ENABLE_AT_RESET/ENABLE/DISABLE never write outdata, but line 284 copyout(outdata,...) sends uninitialized kernel heap to userspace.
Fix
Add M_ZERO to the outdata kmalloc: kmalloc(outsize, M_TEMP, M_INTWAIT | M_ZERO).
Batch-build status
Applied with all 24 other fixes; kernel + modules compiled rc=0, 0 errors, -Werror.
Fix verification
fixedAdded M_ZERO; batch build rc=0.
Added M_ZERO; batch build rc=0.
Confirmed kernel references
β
Detail
Exploit chain
none
Evidence (decisive lines)
ath_ioctl_spectral outdata kmalloc without M_ZERO; heap leak.
Verified recommended fix
ath_ioctl_spectral outdata kmalloc without M_ZERO; heap leak.
Verdict
ath_ioctl_spectral outdata kmalloc without M_ZERO; heap leak.
No comments yet.