@openvtc/trust-tasks 0.26.3 → 0.26.4

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.
Files changed (48) hide show
  1. package/CHANGELOG.md +38 -0
  2. package/dist/_shared/components.d.ts +47 -0
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/index.d.ts +7 -0
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +7 -0
  7. package/dist/index.js.map +1 -1
  8. package/dist/rooms/_shared/0.1/blobs.d.ts +1 -1
  9. package/dist/rooms/_shared/0.1/blobs.d.ts.map +1 -1
  10. package/dist/rooms/blobs/get/0.2/payload.d.ts +1005 -0
  11. package/dist/rooms/blobs/get/0.2/payload.d.ts.map +1 -0
  12. package/dist/rooms/blobs/get/0.2/payload.js +559 -0
  13. package/dist/rooms/blobs/get/0.2/payload.js.map +1 -0
  14. package/dist/rooms/blobs/upload/abort/0.2/payload.d.ts +263 -0
  15. package/dist/rooms/blobs/upload/abort/0.2/payload.d.ts.map +1 -0
  16. package/dist/rooms/blobs/upload/abort/0.2/payload.js +151 -0
  17. package/dist/rooms/blobs/upload/abort/0.2/payload.js.map +1 -0
  18. package/dist/rooms/blobs/upload/begin/0.2/payload.d.ts +1191 -0
  19. package/dist/rooms/blobs/upload/begin/0.2/payload.d.ts.map +1 -0
  20. package/dist/rooms/blobs/upload/begin/0.2/payload.js +659 -0
  21. package/dist/rooms/blobs/upload/begin/0.2/payload.js.map +1 -0
  22. package/dist/rooms/blobs/upload/chunk/0.2/payload.d.ts +459 -0
  23. package/dist/rooms/blobs/upload/chunk/0.2/payload.d.ts.map +1 -0
  24. package/dist/rooms/blobs/upload/chunk/0.2/payload.js +256 -0
  25. package/dist/rooms/blobs/upload/chunk/0.2/payload.js.map +1 -0
  26. package/dist/rooms/blobs/upload/commit/0.2/payload.d.ts +326 -0
  27. package/dist/rooms/blobs/upload/commit/0.2/payload.d.ts.map +1 -0
  28. package/dist/rooms/blobs/upload/commit/0.2/payload.js +185 -0
  29. package/dist/rooms/blobs/upload/commit/0.2/payload.js.map +1 -0
  30. package/dist/rooms/keys/act/0.1/payload.d.ts +546 -0
  31. package/dist/rooms/keys/act/0.1/payload.d.ts.map +1 -0
  32. package/dist/rooms/keys/act/0.1/payload.js +305 -0
  33. package/dist/rooms/keys/act/0.1/payload.js.map +1 -0
  34. package/dist/rooms/keys/seal/0.2/payload.d.ts +368 -0
  35. package/dist/rooms/keys/seal/0.2/payload.d.ts.map +1 -0
  36. package/dist/rooms/keys/seal/0.2/payload.js +205 -0
  37. package/dist/rooms/keys/seal/0.2/payload.js.map +1 -0
  38. package/package.json +1 -1
  39. package/src/_shared/components.ts +47 -0
  40. package/src/index.ts +7 -0
  41. package/src/rooms/_shared/0.1/blobs.ts +1 -1
  42. package/src/rooms/blobs/get/0.2/payload.ts +625 -0
  43. package/src/rooms/blobs/upload/abort/0.2/payload.ts +187 -0
  44. package/src/rooms/blobs/upload/begin/0.2/payload.ts +731 -0
  45. package/src/rooms/blobs/upload/chunk/0.2/payload.ts +304 -0
  46. package/src/rooms/blobs/upload/commit/0.2/payload.ts +224 -0
  47. package/src/rooms/keys/act/0.1/payload.ts +380 -0
  48. package/src/rooms/keys/seal/0.2/payload.ts +256 -0
package/CHANGELOG.md CHANGED
@@ -11,6 +11,44 @@ The package versions over **its own API** — what a consumer compiles against
11
11
  not over `SPEC.md`. Below 1.0 a breaking change bumps the leading non-zero
12
12
  component.
13
13
 
14
+ ## 0.26.4 — 2026-10-15
15
+
16
+
17
+ ### Added
18
+
19
+ - **rooms**: Act as the member's persona — rooms/keys/act, seal 0.2, direct-to-storage blob transfer (#771)
20
+
21
+ A member of a data room is the DID the room admitted — usually a persona
22
+ their key holder (VTA) holds for them — but the member's own client (CLI,
23
+ extension, phone) holds none of that DID's keys. Until now it could reach a
24
+ host only through rooms/keys/present, which grants the leaf to the caller,
25
+ and then signed with its own key: the host recorded the client's did:key as
26
+ the actor and, on an attributed room, as the author of every record.
27
+
28
+ - rooms/keys/act/0.1 (new): the client builds a host-bound room request
29
+ without presentation or proof; the key holder completes it as the member
30
+ (the member's own authority narrowed to the one action a closed table
31
+ fixes per type, granted to the member; issuer = member; the member's
32
+ authentication proof) and returns it for the client to send. Refused to
33
+ delegates, which keep using rooms/keys/present.
34
+ - rooms/keys/seal/0.2: optional signAsPrincipal — the key holder signs the
35
+ SealedRecordBody as its author (a member the caller acts as) before
36
+ sealing, so the record is attributed to the member.
37
+ - rooms/blobs/upload/{begin,chunk,commit,abort}/0.2 and rooms/blobs/get/0.2:
38
+ two transfer modes. Direct: the host authorizes and reserves as before,
39
+ then issues per-part presigned PUTs (one object, one method, exact length
40
+ and SHA-256 as signed headers, <= 5 min), verifies the object at storage
41
+ before commit records it, and serves reads with a presigned GET. Proxied:
42
+ bytes through the host as chunk documents signed by a single-use upload
43
+ key the begin names, so file bytes never pass through the key holder.
44
+ A host SHOULD NOT offer direct transfer on a private room unless its
45
+ policy allows; the response always names the mode.
46
+ - In place (drafts, wire unchanged): rooms/keys/{read,browse,backfill}
47
+ present as the principal and never let the key holder's own identifier
48
+ reach the host; rooms/keys/welcome and rooms/keys/open keep one group
49
+ state per member per room.
50
+ - rooms/_shared/0.1/blobs: TransferMode, PartPlan, TransferTarget (additive).
51
+
14
52
  ## 0.26.3 — 2026-10-14
15
53
 
16
54
 
@@ -1177,6 +1177,10 @@ export type TrafficStage = "received" | "stored" | "delivered" | "forwarded" | "
1177
1177
  * Handle for one upload (begin → chunk → commit or abort) or one download (get → chunk). Host-generated and unguessable, which is what lets a reference to another party's transfer be answered as not-found without confirming that it exists. Bound at creation to the party that opened it: the subject the host authenticated for the opening request. Opaque: a producer quotes what it was given.
1178
1178
  */
1179
1179
  export type TransferId = string;
1180
+ /**
1181
+ * How a blob's bytes move. `proxied`: through the host, as chunk documents (rooms/blobs/upload/chunk, rooms/blobs/chunk). `direct`: straight between the member and the storage the room is assigned to, over time-limited URLs the host issues for one object and one method each; the host authorizes every object and verifies every upload, and never carries a byte. Which mode applies is the host's answer, from what the producer accepts, what the room's storage can do, and the room's tier.
1182
+ */
1183
+ export type TransferMode = "direct" | "proxied";
1180
1184
  /**
1181
1185
  * A ULID in Crockford base32, uppercase. Used for `attributeId` and `profileId`. Chosen over a UUID because the leading 48 bits are a timestamp, so a key-ordered scan of the store is also creation-ordered and a `list` needs no secondary sort. Server-assigned on create; a producer MAY supply one to make a create idempotent, and a maintainer MUST reject a supplied value that already exists rather than silently overwriting.
1182
1186
  */
@@ -6561,6 +6565,25 @@ export interface OfferCredentials {
6561
6565
  */
6562
6566
  authority: string;
6563
6567
  }
6568
+ /**
6569
+ * How the uploader will cut a blob for direct transfer, committed before any byte moves: one storage object, written in `partCount` parts of `partSize` bytes (the last may be shorter), each with its digest. Independent of the chunk manifest, because storage imposes part sizes a chunk document cannot carry; the chunk manifest still describes the blob and readers still check it.
6570
+ *
6571
+ * Consistency rules JSON Schema cannot state: `partCount` MUST equal ceil(size / partSize) for the manifest's `size`, and `partDigests` MUST have exactly `partCount` items. Every digest MUST be sha2-256, because it is what the storage itself checks the part against.
6572
+ */
6573
+ export interface PartPlan {
6574
+ /**
6575
+ * Bytes per part. One part of the whole blob's size is a single-object write.
6576
+ */
6577
+ partSize: number;
6578
+ partCount: number;
6579
+ /**
6580
+ * The sha2-256 digest of each part's ciphertext, in order.
6581
+ *
6582
+ * @minItems 1
6583
+ * @maxItems 1024
6584
+ */
6585
+ partDigests: [DigestMultibase, ...DigestMultibase[]];
6586
+ }
6564
6587
  export interface PasskeyVerificationMethod {
6565
6588
  /**
6566
6589
  * The verificationMethod id as it appears in the DID document: `<did>#passkey-<base64url(sha256(credentialId))>`. The fragment is content-derived so a verifier can locate this VM by recomputing `sha256(credential.id)`.
@@ -8607,6 +8630,30 @@ export interface TrafficOutcome {
8607
8630
  */
8608
8631
  detail?: string;
8609
8632
  }
8633
+ /**
8634
+ * One time-limited URL at the room's storage, issued by the host for one object and one method. A bearer credential for its lifetime: whoever holds it may perform exactly that request. A host MUST bind it to one object, one method and — for a write — the part's exact length and checksum, so that storage itself refuses any other bytes, and MUST give it the shortest practical lifetime, never more than 5 minutes. No party logs it.
8635
+ */
8636
+ export interface TransferTarget {
8637
+ /**
8638
+ * The part this target writes, or 0 for a read of the whole object.
8639
+ */
8640
+ index: number;
8641
+ method: "PUT" | "GET";
8642
+ /**
8643
+ * Where to send the request. HTTPS only.
8644
+ */
8645
+ url: string;
8646
+ /**
8647
+ * Headers the request MUST carry exactly as given — for a write, the part's length and checksum, which the URL's signature covers. A client adds nothing the storage would treat as signed.
8648
+ */
8649
+ headers?: {
8650
+ [k: string]: string | undefined;
8651
+ };
8652
+ /**
8653
+ * When the storage stops honouring the URL. A request begun after it is refused by the storage.
8654
+ */
8655
+ expiresAt: string;
8656
+ }
8610
8657
  export interface TransportObservation {
8611
8658
  /**
8612
8659
  * The binding the document actually travelled on.