DF-4031 / verdict.json
{ "finding_id": "DF-4031", "status": "not_reproduced", "reproduced": 0, "impact": "none", "confidence": "certain", "verdict": "r600 CS tracked offsets are computed in u32 while the GPU addresses 40 bits: vgt_strmout_size = raw*4 wraps (r600_cs.c:1096, u32 field) so VGT_STRMOUT_BUFFER_SIZE_0=0x40000000 validates as size 0 (check at :721-728) while the GPU executes a 4 GiB streamout bound; cb_color_bo_offset/db_offset/htile_offset/vgt_strmout_bo_offset do raw<<8 in u32 (:1084,:1281,:1295,:1308) so raw>=2^24 makes every CB/DB/htile BO-size check validate the WRONG offset (kernel 0 vs GPU 4 GiB, sim output in run.log). r600 analogue of the evergreen DF-3838 wraparound family. Hardware-gated: no radeon GPU on the audit guest.", "exploit_chain": "Unpriv CS: streamout size register 0x40000000 -> kernel validates 0 bytes, GPU writes up to 4 GiB past the BO; or CB_COLOR0_BASE raw 0x01000000 -> color/depth/htile writes land 4 GiB from the validated window (groomable onto victim BOs) -> cross-process GPU memory corruption.", "evidence": "VERDICT.md (full path:line trace); run.log (guest trigger run + arithmetic simulation proving the validator math line-exact); build.log (clean guest build); env.txt (guest has no radeon GPU \u2014 hardware-gated); fix.diff (proposed fix, NOT applied to sys/)", "kernel_refs": [ "sys/dev/drm/radeon/r600_cs.c:1084", "sys/dev/drm/radeon/r600_cs.c:1096", "sys/dev/drm/radeon/r600_cs.c:1281", "sys/dev/drm/radeon/r600_cs.c:1295", "sys/dev/drm/radeon/r600_cs.c:1308", "sys/dev/drm/radeon/r600_cs.c:717-736", "sys/dev/drm/radeon/r600_cs.c:380", "sys/dev/drm/radeon/r600_cs.c:557", "sys/dev/drm/radeon/r600_cs.c:623" ], "poc_changes": "Trigger written from scratch for this pack (raw ioctl, no libdrm, self-contained struct defs); arithmetic sims written to verify each wrap/desync claim line-exact; past-IB hypothesis for DF-4029 explicitly tested and killed by resource_index_sim.", "attempts": 1, "guest_uname": "DragonFly dfbsd 6.5-DEVELOPMENT DragonFly 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": 45, "guest_dirty": 0, "build_cmd": "./build.sh (guest: cc -O2 -Wall)", "run_cmd": "./run.sh", "code_hash": "da0d9a886161bddfef7392d94a40d9e170e476914de693e08ebd3f3c693fc288", "notes": "Hardware-gated: the audit QEMU guest exposes no radeon DRM device (/dev/dri absent, QEMU virtio display only \u2014 env.txt), so the run-time chain cannot be exercised; classification is not_reproduced at run-time with certain source-level confidence. All findings verified present in upstream Linux master too (cve_match candidates: equivalent).", "recommended_fix": "u64 fields and (u64) casts for every <<8 / *4 tracked-offset conversion (see fix.diff).", "fix_status": "not_testable", "fix_baseline_reproduced": 0, "fix_patched_reproduced": 0, "fix_verdict": "fix.diff authored against the read-only sys/ tree after source verification; baseline and patched runs require r600/rv770 hardware which the audit guest lacks, so fix validation is not testable here.", "fix_evidence": "fix.diff in this pack" } |