Title: id(world_net): route_frame lets a frame's own 'world' key override the session-bound world — a WorldSessions session keyed to one world silently leases another · Issue #4576 · developing-today/code · GitHub
Open Graph Title: id(world_net): route_frame lets a frame's own 'world' key override the session-bound world — a WorldSessions session keyed to one world silently leases another · Issue #4576 · developing-today/code
X Title: id(world_net): route_frame lets a frame's own 'world' key override the session-bound world — a WorldSessions session keyed to one world silently leases another · Issue #4576 · developing-today/code
Description: Summary route_frame (pkgs/id/src/world_net.rs:387-396) only inserts the session-bound world when the frame does not already carry a world key — it never overrides one. That breaks the contract the rest of the stack is built on: WorldClie...
Open Graph Description: Summary route_frame (pkgs/id/src/world_net.rs:387-396) only inserts the session-bound world when the frame does not already carry a world key — it never overrides one. That breaks the contract the ...
X Description: Summary route_frame (pkgs/id/src/world_net.rs:387-396) only inserts the session-bound world when the frame does not already carry a world key — it never overrides one. That breaks the contract the ...
Opengraph URL: https://github.com/developing-today/code/issues/4576
X: @github
Domain: github.com
IPv4 address: 140.82.114.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"id(world_net): route_frame lets a frame's own 'world' key override the session-bound world — a WorldSessions session keyed to one world silently leases another","articleBody":"## Summary\n\n`route_frame` (`pkgs/id/src/world_net.rs:387-396`) only *inserts* the session-bound world when the frame does not already carry a `world` key — it never overrides one. That breaks the contract the rest of the stack is built on:\n\n- `WorldClient.world` is documented (world_net.rs:404) as the \"World named in every frame this client sends\".\n- The host binds a session to a world by the **first frame only**: `run_session_with` (pkgs/id/src/world_session/mod.rs:847-890) removes `world` from the first frame and leases that world for the session's whole lifetime; later frames cannot re-route.\n- The new coordinator `WorldSessions` (#3845, merged today in PR #3896) retains sessions keyed by `(endpoint, world)` (world_net.rs:1473-1510) and trusts that key to mean the world the session is actually bound to.\n\nSo a session opened/keyed for world **arena** whose first frame already carries `\"world\": \"bazaar\"` — the shape hand-built join frames routinely use (cf. world_session/tests.rs:1386, :1403) — silently leases **bazaar** on the host, while the coordinator keeps handing out that client as the arena session. Every later frame routed through it (which `route_frame` stamps `arena`, to no effect — the lease is already bazaar) acts on bazaar. Wrong-world reads/writes with no error anywhere.\n\n## Evidence (verified this run, main @ 6fc3145d5)\n\nVerbatim `route_frame` (world_net.rs:387-396, snippet md5 3644119170747a4a3197b05032d01efc) in a laptop probe (`~/git/fleet/probe-2026-11-02-laneB-routeframe/` on the laptop):\n\n```\nbound=arena frame_world=\"bazaar\" routed={\"capability\":\"1.abc\",\"type\":\"join\",\"world\":\"bazaar\"}\nbare frame routed world=\"arena\"\n```\n\n- Frame with its own `world` key + bound world `arena` → routed frame still names `bazaar` (frame wins).\n- Control: frame without a `world` key + bound world `arena` → routed frame names `arena` (insert path works).\n\nAll current in-tree `route_frame` callers (commands/world.rs:738, world_ssh.rs:2680, :2860, `WorldClient::send_json` world_net.rs:470) build frames without a `world` key, so the override branch is latent today — it activates the moment a caller reuses a world-carrying frame template through a bound session, which the `WorldSessions` API now invites. There are no tests for `route_frame`.\n\n## Why it matters\n\nWorld selection is a capability boundary (per-world capability checks are the F13.8 design's stated invariant, doc/2026-11-01T17-54-35Z_design_id_concurrent_world_sessions). A client-side coordinator that can silently hold a session to a different world than its key claims undermines that invariant and produces wrong-world actions that look successful.\n\n## Acceptance criteria\n\n- [ ] `route_frame` with a bound world produces a frame naming that world even when the input frame already carries a different `world` key (bound world wins), or the mismatch is rejected with an explicit error — one behavior, documented on `WorldClient.world` / `route_frame`.\n- [ ] Unit tests for `route_frame`: insert-when-absent, override/reject-when-present-and-different, no-op when the frame's world already equals the bound world, `None` bound world leaves the frame untouched.\n- [ ] A `WorldSessions`-level test (extending the coordinator tests in world_net.rs) shows a session opened for world A cannot end up leased to world B via a pre-keyed first frame.\n- [ ] Existing world_net / world_session tests stay green.\n","author":{"url":"https://github.com/dezren39","@type":"Person","name":"dezren39"},"datePublished":"2026-11-02T20:42:17Z","url":"https://github.com/developing-today/code/issues/4576"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:3030a826-9efb-453c-2b50-b8d6938509ea |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EDCE:DAF5F:A2DE43:D1F8F9:6B063427 |
| html-safe-nonce | a46db11f1791c7ac504b0fece32274b0a4a678ee7dfc94fcc200eec7ce68ceaf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFRENFOkRBRjVGOkEyREU0MzpEMUY4Rjk6NkIwNjM0MjciLCJ2aXNpdG9yX2lkIjoiMTg0MzUwNzYyMjg4OTAxMDIxNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 5c858200ec1b4a1bb632b0800f2bce47110c06570ab0a7ed1729792f1adc7a53 |
| hovercard-subject-tag | issue:6170603097 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/developing-today/code/4576/issue_layout |
| twitter:image | https://opengraph.githubassets.com/fac4101ca5a323b72429b27cf9b841dc91158fab61eefa93242b17e591d67021/developing-today/code/issues/4576 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/fac4101ca5a323b72429b27cf9b841dc91158fab61eefa93242b17e591d67021/developing-today/code/issues/4576 |
| og:image:alt | Summary route_frame (pkgs/id/src/world_net.rs:387-396) only inserts the session-bound world when the frame does not already carry a world key — it never overrides one. That breaks the contract the ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | dezren39 |
| hostname | github.com |
| expected-hostname | github.com |
| None | c3584c853cd39700ecff6e2cf8364295ffdb5313e571046c41cd2479270f7df0 |
| turbo-cache-control | no-preview |
| go-import | github.com/developing-today/code git https://github.com/developing-today/code.git |
| octolytics-dimension-user_id | 26439447 |
| octolytics-dimension-user_login | developing-today |
| octolytics-dimension-repository_id | 627308783 |
| octolytics-dimension-repository_nwo | developing-today/code |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 627308783 |
| octolytics-dimension-repository_network_root_nwo | developing-today/code |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 9eb3bb1597d09170a5f282cd38ae376dee1a5ec1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width