fix(rpc): UDS transport silently drops X-Hero-Context headers — context isolation broken for direct socket calls #40
Labels
No labels
prio_critical
prio_low
type_bug
type_contact
type_issue
type_lead
type_question
type_story
type_task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lhumina_code/hero_biz#40
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Root cause (code-verified, 2026-05-07)
Finding 1 — hero_rpc UDS transport drops X-Hero-Context headers (real bug)
File:
hero_rpc/crates/openrpc/src/transport.rsThe
post_raw_json_with_headers()method accepts a header slice but silently ignores it for Unix Domain Socket transport. Only HTTP transport passes headers through. The docstring documents this explicitly:This means any service talking to another service directly over UDS while relying on
X-Hero-Contextfor context isolation will silently get the wrong context. Tracked in lhumina_code/hero_rpc#42.Finding 2 — hero_osis OsisClient endpoint and header construction is already correct
File:
hero_rpc/crates/openrpc_http_client_lib/src/lib.rsOsisClient::new()constructs{base_url}/hero_osis_{domain}/rpcand callspost_raw_json_with_headerswith[("X-Hero-Context", &self.context)]. Since this uses HTTP transport (through hero_router), the header is forwarded correctly.The Cargo.lock in hero_osis pins
hero_rpc_clientat commite512c1bf(development branch) — the endpoint format is already correct in the current state.The
cargo updaterecommendation in lhumina_code/hero_osis#46 and the endpoint format analysis in #37 were based on stale/hallucinated analysis and do not reflect the actual code.What needs to happen
P1 — Fix UDS header forwarding in hero_rpc
Thread
extra_headersthroughhttp_post_unix()intransport.rsso thatX-Hero-ContextandX-Hero-Claimssurvive the UDS hop. This is required for any service that communicates with another service directly over UDS and needs context isolation.Tracked in lhumina_code/hero_rpc#42.
Stale analysis to disregard
cargo updatefor hero_rpc_client) — current Cargo.lock already has the correct endpoint formatOwner: Casper (lhumina_code/hero_rpc#42 UDS fix)
Source: Code-verified 2026-05-07
fix(ai): AI assistant hallucinates CRM data — tools not wired to OSISto fix(rpc): UDS transport silently drops X-Hero-Context headers — context isolation broken for direct socket calls