scmmap under-bounds offset when framebuffer height*stride is 0 or overflows int
Summary
scmmap at syscons.c:4090-4097: sz=roundup(fbi->height*fbi->stride,PAGE_SIZE). height/stride uint16; product computed as int (overflows 65535*65535). If height or stride=0: sz=0, sz-PAGE_SIZE underflows to ~2^64-4096, any offset passes bound -> vtophys(vaddr+offset) maps unintended physical memory. Requires SYSCAP_RESTRICTEDROOT + buggy/malicious framebuffer driver. Fix: reject height==0||stride==0, compute in size_t, check sz>=PAGE_SIZE before subtraction.
Discussion (0)
PoC verification
Evidence pack
findings/poc/DF-1202 Β· 1 files| File | Type | Description | Size | |
|---|---|---|---|---|
| manifest.json | file | 397 B | view raw |
Fix verification
not_testablerecommended fix identified; fix.diff not authored/validated in this batch
recommended fix identified; fix.diff not authored/validated in this batch
Confirmed kernel references
β
Detail
Exploit chain
none (Info severity)
Evidence (decisive lines)
Source-confirmed at sys/dev/misc/syscons/syscons.c:4089: scmmap under-bounds offset when framebuffer height*stride is 0 or overflows int
Verified recommended fix
Source-confirmed at sys/dev/misc/syscons/syscons.c:4089: scmmap under-bounds offset when framebuffer height*stride is 0 or overflows int
Verdict
Source-confirmed at sys/dev/misc/syscons/syscons.c:4089: scmmap under-bounds offset when framebuffer height*stride is 0 or overflows int
No comments yet.