openclaw-brokerkit 0.2.1 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -120,10 +120,9 @@ When OpenClaw is outside the credential trust boundary, the trusted backend
120
120
  must serve the packaged `dist/ui` files at the registered UI path itself. A
121
121
  framed popover may receive a server-enforced `read` or `decide` session: a
122
122
  `read` session shows requests without action controls, and a `decide` session
123
- lets the operator act directly in the frame. Hosts that use framed decisions
124
- accept that the surrounding application controls the iframe's placement and
125
- can attempt UI redressing; use the navigation-only launcher below when that
126
- threat must remain out of scope.
123
+ lets the operator act directly in the frame. The OpenClaw Gateway approvals
124
+ popover is an actionable surface and must receive `decide`; the trusted host
125
+ must retain decision authority and validate that access on every request.
127
126
 
128
127
  ### Session injection
129
128
 
@@ -148,7 +147,7 @@ this closed payload:
148
147
  "api_version": "brokerkit.io/delegated-web/v1",
149
148
  "token": "opaque-short-lived-browser-session",
150
149
  "expires_at": "<no more than five minutes from issue time, RFC3339>",
151
- "access": "read",
150
+ "access": "decide",
152
151
  "renewal_transport": "direct"
153
152
  }
154
153
  ```
@@ -192,29 +191,6 @@ and set `Vary: Origin` plus `Cache-Control: no-store`. It must not return
192
191
  `Access-Control-Allow-Credentials: true`; delegated API requests deliberately
193
192
  omit cookies.
194
193
 
195
- ### Secure-navigation launcher
196
-
197
- With `access: "read"`, each actionable request renders a **Review securely**
198
- button instead of decision controls. The button posts this navigation-only
199
- message:
200
-
201
- ```text
202
- { type: "brokerkit.delegated-web.open", version: 1, nonce }
203
- ```
204
-
205
- The host verifies the exact opaque-origin frame source and navigates the
206
- whole browser tab to the trusted UI URL. The top-level response is
207
- unframeable and contains a server-enforced decision session, so approval,
208
- denial, and revocation require a second explicit action in the trusted
209
- document.
210
-
211
- A host that does not provide a framed inbox can inject this marker so the UI
212
- renders only the secure-navigation launcher:
213
-
214
- ```html
215
- <meta name="brokerkit-delegated-top-level" />
216
- ```
217
-
218
194
  ### Parent session bridge
219
195
 
220
196
  When the parent application is trusted, a sandboxed tab that cannot call the
@@ -230,3 +206,19 @@ frame and must bind each response to the supplied 128-bit nonce. `session` is
230
206
  the same `brokerkit.io/delegated-web/v1` object returned by
231
207
  `POST <basePath>/session`. The bridge is a BrokerKit interface; it contains
232
208
  no host-product namespace or host-specific payload.
209
+
210
+ ### Session rebootstrap
211
+
212
+ A direct-renewal token can expire while a browser tab is suspended. If the
213
+ host rejects renewal with `not_authorized`, a framed UI sends this
214
+ credential-free message once:
215
+
216
+ ```text
217
+ { type: "brokerkit.delegated-web.rebootstrap", version: 1 }
218
+ ```
219
+
220
+ The host must accept it only from the embedded BrokerKit frame and reload only
221
+ that protected frame so its HTML response can inject a fresh session. Hosts
222
+ must rate-limit reloads and must not return a token through this message. This
223
+ keeps rebootstrap host-neutral while leaving session issuance at the trusted
224
+ HTTP boundary.
@@ -1,4 +1,4 @@
1
- export const OPERATOR_V1_SCHEMA_SHA256 = "62065b7c9d09989c66379c6a81dd23f9ae468c7d1a859b69c88a1dee079aa6a6";
1
+ export const OPERATOR_V1_SCHEMA_SHA256 = "306810514cd7e378b194f9d539aae99de07396994ec7de273a18dc5a4aa47118";
2
2
  export const operatorV1 = {
3
3
  apiVersion: "brokerkit.io/operator/v1",
4
4
  statuses: [
@@ -11,7 +11,6 @@ export const operatorV1 = {
11
11
  "revoked",
12
12
  ],
13
13
  actions: ["approve", "deny", "revoke"],
14
- risks: ["unknown", "low", "medium", "high", "critical"],
15
14
  eventKinds: [
16
15
  "request.created",
17
16
  "request.approved",