DF-5750 / verdict.json
{ "finding_id": "DF-5750", "status": "reproduced", "reproduced": true, "impact": "none", "confidence": "certain", "verdict": "REPRODUCED as unprivileged user: bind() on an already-LISTENING L2CAP socket succeeds and mutates the listeners advertised PSM in place (l2cap_upper.c:106-112 has no state check, unlike l2cap_listen/l2cap_connect discipline; the rfcomm sibling got the upstream check, DF-5747). No duplicate-PSM listener rejection either. Semantic/hardening only (listener routing-key mutation; no memory-safety consequence demonstrated) -> Info.", "exploit_chain": "", "evidence": "run.log (bind/listen/re-bind sequence, re-bind of LISTENING socket returns 0); VERDICT.md", "kernel_refs": [ "sys/netbt/l2cap_upper.c:106", "sys/netbt/l2cap_upper.c:302", "sys/netbt/l2cap_socket.c:320", "sys/netbt/l2cap_signal.c:266" ], "poc_changes": "written fresh; no seed", "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": 60, "guest_dirty": 0, "build_cmd": "cc -O -o bind_state bind_state.c", "run_cmd": "kldload netbt (root, once); ./bind_state (unprivileged)", "code_hash": "795b9f4bccc1efbda1d4f205d6df61286fa3515a86bea35b2129db3643403743", "notes": "requires netbt KLD loaded (privileged) - AF_BLUETOOTH L2CAP sockets then usable by any user. The cosmetic [unexpected] tag on the second-listen EINVAL line in run.log is a print-logic slip (r==-1 vs EINVAL constant); the EINVAL itself is the expected outcome.", "recommended_fix": "l2cap_bind(): return EINVAL unless chan->lc_state == L2CAP_CLOSED && chan->lc_lcid == L2CAP_NULL_CID (upstream rfcomm_bind fix shape).", "fix_status": "not_applicable", "fix_baseline_reproduced": false, "fix_patched_reproduced": false, "fix_verdict": "one-line state check; not built for an Info finding (no security impact beyond routing semantics)", "fix_evidence": "VERDICT.md recommended fix" } |