Boot-time kernel panic on malformed MP-table INT entry (dst_apic_int >= IO-APIC pin count)
Summary
mptable_ioapic_int_callback at mptable.c:1296-1300 panic(dst_apic_int >= mio_npin). dst_apic_int u_char firmware-controlled. mio_npin from IOAPIC VER register only during enumerate (after probe). Probe (mptable_ioapic_probe_callback :1174-1214) only validates src_bus_irq<ISA_IRQ_CNT, never dst_apic_int vs pin count. Malicious firmware/VM host: MP table INT entry dst_apic_int=200 > real pin count 24 -> probe passes -> enumerate panics. Secondary panic at :1388 if first replaced by EINVAL. Boot-time DoS from privileged firmware position. Fix: kprintf warning + return 0 (skip bad entry, match existing warn-and-skip idiom at :1051-1055).
Discussion (0)
PoC verification
Evidence pack
findings/poc/DF-1034 Β· 3 files| File | Type | Description | Size | |
|---|---|---|---|---|
| fix.diff | suggested-fix | git-apply-able fix for the cited path | 554 B | view raw |
| VERDICT.md | verdict | source-confirmation narrative | 945 B | β raw |
| env.txt | environment | guest uname + toolchain | 247 B | view raw |
DF-1034 source-confirmation
Verdict: REPRODUCED (source-confirmed) Impact: none Confidence: likely
Kernel ref: sys/platform/pc64/x86_64/mptable.c:1296
Mechanism
mptable boot panic on bad IO-APIC pin: malformed MP-table INT entry with dst_apic_int>=pin count panics at enumerate time (probe only checks src_bus_irq). boot-time DoS from firmware. confirmed.
Confirmation method
source-only Low-severity; confirmation by code inspection. Runtime PoC not exercised for this Low-severity item; confirmation is by code inspection against sys/.
Recommended fix
See fix.diff in this folder (git-apply-able unified diff).
Phase 8 (combined build)
This fix is part of the batched 70-finding combined patch
(../_batch70/combined_70.patch) applied to in-guest /usr/src. A single
make -j6 nativekernel KERNCONF=X86_64_GENERIC build is validated rc=0 with 0
errors under -Werror (../_batch70/fix_build.log).
Fix verification
fixedVALIDATED via combined build: fix in combined_70.patch; single make -j6 nativekernel built rc=0, 0 errors under -Werror (../_batch70/fix_build.log). Cited line corrected. Source-only -> validation = clean -Werror compile.
'>>> Kernel build for X86_64_GENERIC completed' + 'NK_DONE rc=0'; grep -cE 'error:|undefined reference' fix_build.log = 0
Confirmed kernel references
- s
- y
- s
- /
- p
- l
- a
- t
- f
- o
- r
- m
- /
- p
- c
- 6
- 4
- /
- x
- 8
- 6
- _
- 6
- 4
- /
- m
- p
- t
- a
- b
- l
- e
- .
- c
- :
- 1
- 2
- 9
- 6
Detail
Exploit chain
none (source-only Low finding, not memory-corruption driven to runtime; no escalation chain)
Evidence (decisive lines)
baseline (with-src #0): bug at sys/platform/pc64/x86_64/mptable.c:1296. combined-70 fix kernel: NK_DONE rc=0 (0 errors, -Werror).
PoC changes
authored/validated fix.diff (findings/poc/DF-1034/fix.diff); part of combined_70 kernel build.
Verified recommended fix
See findings/poc/DF-1034/fix.diff (git-apply-able). Matches finding proposal.
Verdict
REAL: malformed MP-table INT entry (dst_apic_int>=pin count) panics at enumerate (probe doesn't check). boot DoS. confirmed.
No comments yet.