DF-2366 / verdict.json
{ "finding_id": "DF-2366", "status": "reproduced", "reproduced": 1, "impact": null, "confidence": "certain", "verdict": "REPRODUCED: userland replica of the verbatim rc4_init loop with key pointing into a PROT_NONE guard page and keylen=0 faults deterministically on the key[0] read (SIGSEGV, exit 139; kernel logged the same signal for the guest binary). In the kernel the identical instruction reads one byte past the caller buffer. In-tree callers (netgraph mppc RC4 compression: ng_mppc.c rc4_init with KEYLEN(cfg.bits), 8-16 bytes) never pass keylen<=0, so this is defense-in-depth; no reachable fault found.", "exploit_chain": "no escalation path: no in-tree rc4_init caller passes keylen<=0 (netgraph mppc passes 8-16); latent only", "evidence": "run.log: rc4_init(state, guard-page key, keylen=0) -> Segmentation fault (exit 139); kernel logged pid 1063 (p366s) signal 11; in-kernel equivalent is the 1-byte OOB read of the caller buffer", "kernel_refs": [ "sys/crypto/rc4/rc4.c:71", "sys/crypto/rc4/rc4.c:74", "sys/netgraph7/mppc/ng_mppc.c:843" ], "poc_changes": "First demo put key[0] on the last byte of a MAPPED page (no fault, keylen=0 keeps k=0 so only key[0] is read); fixed by pointing the zero-length key buffer into a PROT_NONE guard page. Also: compile without -O, gcc dead-code-eliminates the unused schedule at -O.", "attempts": 3, "guest_uname": "DragonFly dfbsd 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": 15, "guest_dirty": 0, "build_cmd": "cc -o rc4_keylen0 rc4_keylen0.c (no -O: gcc DCEs the unused schedule at -O)", "run_cmd": "./rc4_keylen0 (expect: Segmentation fault, exit 139)", "code_hash": "9d4c904becebcca93dd42172167cfee1d19424dcf6fa1a47bde24f62c417634f", "notes": "", "recommended_fix": "Early-return on keylen<=0 before touching the key buffer.", "fix_status": "not_testable", "fix_kernel_uname": null, "fix_baseline_reproduced": null, "fix_patched_reproduced": null, "fix_verdict": "fix.diff compile-validated in the batch combined kernel build (all 37 diffs of this batch applied to in-guest /usr/src; make -j6 nativekernel KERNCONF=X86_64_GENERIC, see batch build log referenced in VERDICT.md); no behavior A/B performed for this Info-tier item; behavior A/B intentionally skipped for Info tier", "fix_evidence": "batch combined kernel build log (see findings/poc/_batch41 note in VERDICT.md)" } |