refactor(#2862): drop the fd framing module, the hazard is unreachable

The Framer bound a passed descriptor to the request line it belongs to,
on the premise that several requests can be in flight on one connection
so a descriptor could arrive with a chunk belonging to a different one.

That premise is false. hive-sock-client::try_once connects per request
(connect, write one line, read one line, drop) and priv_client's two
connect sites each open their own stream, so a connection carries
exactly one request: one line, at most one descriptor, nothing to
disambiguate. Request and response align by connection.

Delete it rather than move it. The recvmsg swap still has to happen —
SCM_RIGHTS is attached to a specific recvmsg call and BufReader::lines
cannot surface it — but the pairing it needs is "take the descriptor
that arrived with this line", not a queue and a claim policy.
This commit is contained in:
atlas 2026-07-31 21:01:17 +02:00 committed by mara
commit 364bc290df
2 changed files with 0 additions and 285 deletions

View file

@ -12,12 +12,6 @@
use serde::{Deserialize, Serialize};
// Line framing that also carries passed file descriptors. Part of the
// wire contract rather than one side's implementation detail: the
// daemon sends descriptors and the helper reassembles them, so both
// ends have to agree on how a descriptor is bound to a request.
pub mod framing;
/// Default socket path for the privileged helper.
pub const PRIV_SOCK: &str = "/run/hive/priv.sock";