From 4aab4011574348247e5e19054cd37b4dd67eb4f6 Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:11:20 +0200 Subject: [PATCH 1/7] docs(adr): 0046 device.exec fills in the lease's device, and refuses another (#951) --- ...-device-exec-fills-in-the-leases-device.md | 114 ++++++++++++++++++ docs/internal/adr/README.md | 1 + 2 files changed, 115 insertions(+) create mode 100644 docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md diff --git a/docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md new file mode 100644 index 000000000..3aaf6f1fe --- /dev/null +++ b/docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md @@ -0,0 +1,114 @@ +# 0046. `device.exec` fills in the lease's device, and refuses another + +- **Status:** Proposed +- **Date:** 2026-10-23 +- **Issue:** [#951](https://github.com/callstackincubator/simlock/issues/951) +- **Extends:** [ADR 0005](0005-gateway-and-worker-modes.md) §19a (the + driver resolves the command). Nothing in 0005 is replaced. + +## Context + +`device.exec` runs one `simctl`, `adb` or `devicectl` command against a +lease on the worker that holds the device (ADR 0005 §19a). Only +`devicectl` gets the device from the lease: the driver adds +`--device ` unless the arguments name one +(`src/drivers/ios/devicectl-exec.ts:211`). For `simctl` and for `adb` +on an emulator, the caller's arguments must name the device, and the +daemon parses none of them (`src/daemon/dispatcher.ts:696-712`). So every +caller copies the UDID or the adb serial out of the grant into every +command, and nothing stops one that copies the wrong one: +`simctl install booted …` can reach another agent's simulator in the +same device set. + +Two requests need the device to be implied: an MCP tool that runs these +commands against the session's lease (#951), and `simlock simctl` / +`simlock adb` on a worker scoped to the caller's lease (#948). Where the +device sits differs per tool and per verb, and the drivers already own +each tool's grammar and refusal list (drivers rule 6). + +## Decision + +1. **The driver fills the lease's device in.** When `passthrough` is + given a device (today only `device.exec` gives one), the driver puts + that device into the command where the tool expects it. A caller + leaves the device out: + + | Tool, device | Where the device goes | Already named | + | --- | --- | --- | + | `simctl`, simulator | First operand after the verb and the verb's own options, for verbs on the driver's device-verb list | Left as is when it is the lease's UDID (any letter case) | + | `adb`, emulator | `-s ` before the subcommand, unless the subcommand is on the driver's no-device list (`devices`, `version`, `help`, …) | `-s ` left as is | + | `adb`, physical phone | `-s `, as today | Any leading flag refused, as today | + | `devicectl`, physical iPhone or iPad | `--device `, as today | `--device` / `-d` with the lease's UDID left as is | + + A `simctl` verb not on the device-verb list (`list`, `runtime`, + `help`, `pair`, …) passes as today, with nothing filled in and nothing + checked. + +2. **Naming another device is refused.** Where the table above fills a + device in, an argument that names a different device is refused with + `PASSTHROUGH_REFUSED` before anything runs. The message names both the + device the arguments named and the lease's own. For `simctl` that + is another UDID-shaped operand or `booted`. For an emulator's `adb` it + is `-s `, `-d`, `-e` or `-t`. For `devicectl` it is a + `--device` / `-d` with another value. This is still an accident + boundary, not a security one: `xcrun simctl` stays reachable (drivers + known gaps). + +3. **Every `device.exec` caller gets it.** HTTP, the gateway relay, the + programmatic client and MCP all reach the same driver call, so there + is no opt-in flag. A caller that already names the lease's own device + sees no change. Through a gateway the worker fills the device in, as + it resolves every other part of the command. + +4. **No contract change.** `device.exec`'s input and output keep their + shape and the protocol is not bumped. A worker older than this change + runs the arguments as given. + +5. **The local path stays as it is until #948.** `driver.passthrough` + passes no device, so `simlock simctl` and `simlock adb` on a worker + are unchanged. #948 can pass the caller's lease's device to the same + driver call and get the same rule. + +```mermaid +sequenceDiagram + participant C as Caller (MCP, HTTP, client) + participant G as Gateway + participant W as Worker dispatcher + participant D as Driver + C->>G: device.exec {leaseId, tool: simctl, args: [install, App.app]} + G->>W: same, worker's lease id + W->>D: passthrough(simctl, lease's device, args) + alt arguments name another device + D-->>W: PASSTHROUGH_REFUSED (names both devices) + W-->>C: error, nothing ran + else + D-->>W: xcrun simctl --set install App.app + W-->>C: started, output chunks, {exitCode} + end +``` + +## Consequences + +- A caller writes `["install", "App.app"]` or `["shell", "getprop"]` and + never copies a UDID or serial. The website's "name your device in the + arguments" advice and the Android serial lookup go away. +- An HTTP caller that sends `booted` today, which the docs already tell + it never to do, gets `PASSTHROUGH_REFUSED`. +- Each driver keeps a device-verb list (iOS) or a no-device list + (Android). A new `simctl` verb is passed through unfilled until it is + added to the list. +- In a fleet whose workers run mixed versions, a command that leaves the + device out works only on workers that have this change. + +## Alternatives considered + +- **The MCP tool fills the device in itself.** That puts each tool's + grammar in a frontend, which ADR 0005 §19c rules out for the refusal + list for the same reason. HTTP and #948 would each need their own copy. +- **An opt-in `fillDevice` field on `device.exec`.** This bumps the + protocol and leaves two behaviours to test and document. Callers that + already name their own device see no change without it, so the flag + buys nothing. +- **Fill in only, refuse nothing.** Smaller, but it leaves the + wrong-device accident open on the one path that now knows where the + device argument sits. diff --git a/docs/internal/adr/README.md b/docs/internal/adr/README.md index db96963bf..764aeaa4f 100644 --- a/docs/internal/adr/README.md +++ b/docs/internal/adr/README.md @@ -83,3 +83,4 @@ the status is stale. | [0042](0042-simlock-updates-itself-through-a-frozen-call-and-a-detached-updater.md) | Simlock updates itself through a frozen call and a detached updater | Accepted — not yet implemented; narrows 0009's `takes-requests` stage | | [0043](0043-physical-devices-reach-agent-device-through-a-second-daemon.md) | Physical devices reach agent-device through a second daemon on the worker | Accepted — not yet implemented; supersedes 0023 §3–4 in part | | [0044](0044-the-console-reads-what-its-page-shows-and-events-mark-it-stale.md) | The console reads what its page shows, and events mark it stale | Accepted — not yet implemented; supersedes 0013 §3 | +| [0046](0046-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a | From aed6e864fafff668a29f09592fe0951bcd0331db Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:21:25 +0200 Subject: [PATCH 2/7] docs(adr): renumber to 0047; 0046 is taken by #954 (#951) --- ...device.md => 0047-device-exec-fills-in-the-leases-device.md} | 2 +- docs/internal/adr/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename docs/internal/adr/{0046-device-exec-fills-in-the-leases-device.md => 0047-device-exec-fills-in-the-leases-device.md} (98%) diff --git a/docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md similarity index 98% rename from docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md rename to docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md index 3aaf6f1fe..dfd4cb7d4 100644 --- a/docs/internal/adr/0046-device-exec-fills-in-the-leases-device.md +++ b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md @@ -1,4 +1,4 @@ -# 0046. `device.exec` fills in the lease's device, and refuses another +# 0047. `device.exec` fills in the lease's device, and refuses another - **Status:** Proposed - **Date:** 2026-10-23 diff --git a/docs/internal/adr/README.md b/docs/internal/adr/README.md index 764aeaa4f..81ec6751e 100644 --- a/docs/internal/adr/README.md +++ b/docs/internal/adr/README.md @@ -83,4 +83,4 @@ the status is stale. | [0042](0042-simlock-updates-itself-through-a-frozen-call-and-a-detached-updater.md) | Simlock updates itself through a frozen call and a detached updater | Accepted — not yet implemented; narrows 0009's `takes-requests` stage | | [0043](0043-physical-devices-reach-agent-device-through-a-second-daemon.md) | Physical devices reach agent-device through a second daemon on the worker | Accepted — not yet implemented; supersedes 0023 §3–4 in part | | [0044](0044-the-console-reads-what-its-page-shows-and-events-mark-it-stale.md) | The console reads what its page shows, and events mark it stale | Accepted — not yet implemented; supersedes 0013 §3 | -| [0046](0046-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a | +| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a | From 61de79811bc58c5b05d05ee1210a681c331b679c Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:23:05 +0200 Subject: [PATCH 3/7] docs(adr): 0047 lists the verbs, the refusal forms, and the MCP queue exception (#951) --- ...-device-exec-fills-in-the-leases-device.md | 45 ++++++++++++++++--- docs/internal/adr/README.md | 2 +- 2 files changed, 39 insertions(+), 8 deletions(-) diff --git a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md index dfd4cb7d4..d7b076bd8 100644 --- a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md +++ b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md @@ -5,6 +5,8 @@ - **Issue:** [#951](https://github.com/callstackincubator/simlock/issues/951) - **Extends:** [ADR 0005](0005-gateway-and-worker-modes.md) §19a (the driver resolves the command). Nothing in 0005 is replaced. +- **Narrows:** [ADR 0003](0003-one-typed-daemon-contract-behind-every-frontend.md) + §11's MCP tool-call serialization: `run_on_device` does not queue (§6). ## Context @@ -40,17 +42,35 @@ each tool's grammar and refusal list (drivers rule 6). | `adb`, physical phone | `-s `, as today | Any leading flag refused, as today | | `devicectl`, physical iPhone or iPad | `--device `, as today | `--device` / `-d` with the lease's UDID left as is | - A `simctl` verb not on the device-verb list (`list`, `runtime`, - `help`, `pair`, …) passes as today, with nothing filled in and nothing - checked. + The two lists, read from `xcrun simctl help` (Xcode 27.0) and + `adb help` (platform-tools 37.0.0): + + - **simctl device verbs**, device first: `addmedia`, `appinfo`, `boot`, + `get_app_container`, `getenv`, `icloud_sync`, `install`, + `install_app_data`, `io`, `keychain`, `listapps`, `location`, + `openurl`, `privacy`, `push`, `reboot`, `rename`, `shutdown`, + `status_bar`, `terminate`, `ui`, `uninstall`, `upgrade`; device after + the verb's own options: `launch`, `spawn`, `pbcopy`, `pbpaste`. Among + those options only `-a` takes a separate value. + - **adb no-device subcommands**: `devices`, `help`, `version`, + `connect`, `disconnect`, `pair`, `mdns`, `keygen`, `start-server`, + `kill-server`, `reconnect`, and `forward` / `reverse` followed by + `--list`. + + A `simctl` verb not on its list (`list`, `runtime`, `help`, `pair`, + `pbsync`, `clone`, …) passes as today, with nothing filled in and + nothing checked. An emulator whose address is empty gets nothing filled + in. 2. **Naming another device is refused.** Where the table above fills a device in, an argument that names a different device is refused with `PASSTHROUGH_REFUSED` before anything runs. The message names both the - device the arguments named and the lease's own. For `simctl` that - is another UDID-shaped operand or `booted`. For an emulator's `adb` it - is `-s `, `-d`, `-e` or `-t`. For `devicectl` it is a - `--device` / `-d` with another value. This is still an accident + device the arguments named, as the caller wrote it, and the lease's + own. For `simctl` that is another UUID-shaped operand or `booted` + (`booted`, `0A1B…`). For an emulator's `adb` it is `-s `, + `-d`, `-e` or `-t ` (`-s emulator-5556`, `-e`, `-t 3`). For + `devicectl` it is a `--device` / `-d` whose value is not the lease's + UDID (`--device 00008110-…`), names and ECIDs included. This is still an accident boundary, not a security one: `xcrun simctl` stays reachable (drivers known gaps). @@ -69,6 +89,13 @@ each tool's grammar and refusal list (drivers rule 6). are unchanged. #948 can pass the caller's lease's device to the same driver call and get the same rule. +6. **The MCP tool built on it does not queue.** `run_on_device` (#951) + reads the session's lease when it starts and runs beside the other + tool calls, so `lease_status` and `release_simulator` answer while a + command runs. A release or a session end during a command goes ahead; + the command runs on to its exit or `exec.timeoutMs`, as a command does + today when its connection closes (ADR 0005 §19e). + ```mermaid sequenceDiagram participant C as Caller (MCP, HTTP, client) @@ -97,6 +124,10 @@ sequenceDiagram - Each driver keeps a device-verb list (iOS) or a no-device list (Android). A new `simctl` verb is passed through unfilled until it is added to the list. +- A caller that names its own device another way (a simctl device name, + a devicectl ECID or name, adb `-t `) is refused or, + for a simctl name, gets the UDID put in front of it and simctl fails. + The UDID or serial is the one form that passes. - In a fleet whose workers run mixed versions, a command that leaves the device out works only on workers that have this change. diff --git a/docs/internal/adr/README.md b/docs/internal/adr/README.md index 81ec6751e..9c916afd1 100644 --- a/docs/internal/adr/README.md +++ b/docs/internal/adr/README.md @@ -83,4 +83,4 @@ the status is stale. | [0042](0042-simlock-updates-itself-through-a-frozen-call-and-a-detached-updater.md) | Simlock updates itself through a frozen call and a detached updater | Accepted — not yet implemented; narrows 0009's `takes-requests` stage | | [0043](0043-physical-devices-reach-agent-device-through-a-second-daemon.md) | Physical devices reach agent-device through a second daemon on the worker | Accepted — not yet implemented; supersedes 0023 §3–4 in part | | [0044](0044-the-console-reads-what-its-page-shows-and-events-mark-it-stale.md) | The console reads what its page shows, and events mark it stale | Accepted — not yet implemented; supersedes 0013 §3 | -| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a | +| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a; narrows 0003 §11 for one MCP tool | From b4a5bce1cea2cc4ebe395aec1804eff886c4a86b Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:29:36 +0200 Subject: [PATCH 4/7] docs(adr): 0047 fixes the adb no-device list and two citations (#951) --- .../0047-device-exec-fills-in-the-leases-device.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md index d7b076bd8..b861264f0 100644 --- a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md +++ b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md @@ -12,9 +12,10 @@ `device.exec` runs one `simctl`, `adb` or `devicectl` command against a lease on the worker that holds the device (ADR 0005 §19a). Only -`devicectl` gets the device from the lease: the driver adds -`--device ` unless the arguments name one -(`src/drivers/ios/devicectl-exec.ts:211`). For `simctl` and for `adb` +physical devices get it from the lease: the driver adds +`--device ` to `devicectl` unless the arguments name one +(`src/drivers/ios/devicectl-exec.ts:211`), and `-s ` to a +phone's `adb` (`src/drivers/android/physical-handler.ts:234`). For `simctl` and for `adb` on an emulator, the caller's arguments must name the device, and the daemon parses none of them (`src/daemon/dispatcher.ts:696-712`). So every caller copies the UDID or the adb serial out of the grant into every @@ -54,8 +55,8 @@ each tool's grammar and refusal list (drivers rule 6). those options only `-a` takes a separate value. - **adb no-device subcommands**: `devices`, `help`, `version`, `connect`, `disconnect`, `pair`, `mdns`, `keygen`, `start-server`, - `kill-server`, `reconnect`, and `forward` / `reverse` followed by - `--list`. + `kill-server`, `reconnect offline`, and `forward --list`. `reconnect` + alone and `reverse --list` act on a device and get it filled in. A `simctl` verb not on its list (`list`, `runtime`, `help`, `pair`, `pbsync`, `clone`, …) passes as today, with nothing filled in and @@ -94,7 +95,8 @@ each tool's grammar and refusal list (drivers rule 6). tool calls, so `lease_status` and `release_simulator` answer while a command runs. A release or a session end during a command goes ahead; the command runs on to its exit or `exec.timeoutMs`, as a command does - today when its connection closes (ADR 0005 §19e). + today when its connection closes (`docs/internal/flows/device-exec.md`, + "Detach"). ```mermaid sequenceDiagram From 772842c5143f6dc058f94340a93f1b1803cd59cd Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:34:14 +0200 Subject: [PATCH 5/7] docs(adr): accept 0047 (#951) --- .../internal/adr/0047-device-exec-fills-in-the-leases-device.md | 2 +- docs/internal/adr/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md index b861264f0..811d74362 100644 --- a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md +++ b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md @@ -1,6 +1,6 @@ # 0047. `device.exec` fills in the lease's device, and refuses another -- **Status:** Proposed +- **Status:** Accepted — not yet implemented - **Date:** 2026-10-23 - **Issue:** [#951](https://github.com/callstackincubator/simlock/issues/951) - **Extends:** [ADR 0005](0005-gateway-and-worker-modes.md) §19a (the diff --git a/docs/internal/adr/README.md b/docs/internal/adr/README.md index 9c916afd1..8bf50f2be 100644 --- a/docs/internal/adr/README.md +++ b/docs/internal/adr/README.md @@ -83,4 +83,4 @@ the status is stale. | [0042](0042-simlock-updates-itself-through-a-frozen-call-and-a-detached-updater.md) | Simlock updates itself through a frozen call and a detached updater | Accepted — not yet implemented; narrows 0009's `takes-requests` stage | | [0043](0043-physical-devices-reach-agent-device-through-a-second-daemon.md) | Physical devices reach agent-device through a second daemon on the worker | Accepted — not yet implemented; supersedes 0023 §3–4 in part | | [0044](0044-the-console-reads-what-its-page-shows-and-events-mark-it-stale.md) | The console reads what its page shows, and events mark it stale | Accepted — not yet implemented; supersedes 0013 §3 | -| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Proposed; extends 0005 §19a; narrows 0003 §11 for one MCP tool | +| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Accepted — not yet implemented; extends 0005 §19a; narrows 0003 §11 for one MCP tool | From 01e512c2ac318f09372b1f8252eca7e8f2a47dbb Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Fri, 23 Oct 2026 21:42:39 +0200 Subject: [PATCH 6/7] docs(adr): 0047 lists bootstatus and names the gateway CLI caller refused on booted (#951) --- .../adr/0047-device-exec-fills-in-the-leases-device.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md index 811d74362..afa024b3d 100644 --- a/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md +++ b/docs/internal/adr/0047-device-exec-fills-in-the-leases-device.md @@ -46,7 +46,7 @@ each tool's grammar and refusal list (drivers rule 6). The two lists, read from `xcrun simctl help` (Xcode 27.0) and `adb help` (platform-tools 37.0.0): - - **simctl device verbs**, device first: `addmedia`, `appinfo`, `boot`, + - **simctl device verbs**, device first: `addmedia`, `appinfo`, `boot`, `bootstatus`, `get_app_container`, `getenv`, `icloud_sync`, `install`, `install_app_data`, `io`, `keychain`, `listapps`, `location`, `openurl`, `privacy`, `push`, `reboot`, `rename`, `shutdown`, @@ -122,7 +122,10 @@ sequenceDiagram never copies a UDID or serial. The website's "name your device in the arguments" advice and the Android serial lookup go away. - An HTTP caller that sends `booted` today, which the docs already tell - it never to do, gets `PASSTHROUGH_REFUSED`. + it never to do, gets `PASSTHROUGH_REFUSED`. So does `simlock simctl` + through a gateway, which runs on `device.exec` (`src/cli/AGENTS.md:85`): + the website's `simlock --gateway simctl install booted ./MyApp.app` + example is refused until task #958 rewrites it. - Each driver keeps a device-verb list (iOS) or a no-device list (Android). A new `simctl` verb is passed through unfilled until it is added to the list. From f79a06ab6e081844e29382f13c24753ac7ef1f62 Mon Sep 17 00:00:00 2001 From: Szymon Chmal Date: Sat, 24 Oct 2026 08:45:58 +0200 Subject: [PATCH 7/7] docs(adr): list the 0047 row after 0046 in the index --- docs/internal/adr/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/internal/adr/README.md b/docs/internal/adr/README.md index 5f7394ae7..2773b8b86 100644 --- a/docs/internal/adr/README.md +++ b/docs/internal/adr/README.md @@ -83,6 +83,6 @@ the status is stale. | [0042](0042-simlock-updates-itself-through-a-frozen-call-and-a-detached-updater.md) | Simlock updates itself through a frozen call and a detached updater | Accepted — not yet implemented; narrows 0009's `takes-requests` stage | | [0043](0043-physical-devices-reach-agent-device-through-a-second-daemon.md) | Physical devices reach agent-device through a second daemon on the worker | Accepted — not yet implemented; supersedes 0023 §3–4 in part; §4 narrowed by 0046 | | [0044](0044-the-console-reads-what-its-page-shows-and-events-mark-it-stale.md) | The console reads what its page shows, and events mark it stale | Accepted — not yet implemented; supersedes 0013 §3 | -| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Accepted — not yet implemented; extends 0005 §19a; narrows 0003 §11 for one MCP tool | | [0045](0045-a-devices-screen-streams-to-operators-not-a-leases.md) | A device's screen streams to operators, not a lease's | Accepted — not yet implemented | | [0046](0046-a-standalone-worker-serves-agent-device-by-default-with-a-private-profile.md) | A standalone worker serves agent-device by default and hands local agents a private profile | Accepted — not yet implemented; narrows 0023 §1, §3–4, 0030 §2, 0039 and 0043 §4 | +| [0047](0047-device-exec-fills-in-the-leases-device.md) | `device.exec` fills in the lease's device, and refuses another | Accepted — not yet implemented; extends 0005 §19a; narrows 0003 §11 for one MCP tool |