@openvtc/trust-tasks 0.25.1 → 0.25.2
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/CHANGELOG.md +18 -0
- package/dist/_shared/components.d.ts +304 -2
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.d.ts +4 -4
- package/dist/device/list/0.1/payload.d.ts.map +1 -1
- package/dist/device/list/0.1/payload.js +6 -2
- package/dist/device/list/0.1/payload.js.map +1 -1
- package/dist/device/list/0.2/payload.d.ts +4 -4
- package/dist/device/list/0.2/payload.d.ts.map +1 -1
- package/dist/device/list/0.2/payload.js +6 -2
- package/dist/device/list/0.2/payload.js.map +1 -1
- package/dist/device/register/0.1/payload.d.ts +4 -4
- package/dist/device/register/0.1/payload.d.ts.map +1 -1
- package/dist/device/register/0.1/payload.js +6 -2
- package/dist/device/register/0.1/payload.js.map +1 -1
- package/dist/device/register/0.2/payload.d.ts +4 -4
- package/dist/device/register/0.2/payload.d.ts.map +1 -1
- package/dist/device/register/0.2/payload.js +6 -2
- package/dist/device/register/0.2/payload.js.map +1 -1
- package/dist/index.d.ts +14 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +14 -0
- package/dist/index.js.map +1 -1
- package/dist/vetting/_shared/0.1/hidden-vetting.d.ts +16 -0
- package/dist/vetting/_shared/0.1/hidden-vetting.d.ts.map +1 -0
- package/dist/vetting/_shared/0.1/hidden-vetting.js +6 -0
- package/dist/vetting/_shared/0.1/hidden-vetting.js.map +1 -0
- package/dist/vetting/attestation/0.1/payload.d.ts +94 -146
- package/dist/vetting/attestation/0.1/payload.d.ts.map +1 -1
- package/dist/vetting/attestation/0.1/payload.js +43 -43
- package/dist/vetting/attestation/0.1/payload.js.map +1 -1
- package/dist/vta/_shared/0.4/pcs-engine.d.ts +16 -0
- package/dist/vta/_shared/0.4/pcs-engine.d.ts.map +1 -0
- package/dist/vta/_shared/0.4/pcs-engine.js +6 -0
- package/dist/vta/_shared/0.4/pcs-engine.js.map +1 -0
- package/dist/vta/pcs/applications/create/0.1/payload.d.ts +1215 -0
- package/dist/vta/pcs/applications/create/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/applications/create/0.1/payload.js +724 -0
- package/dist/vta/pcs/applications/create/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/applications/delete/0.1/payload.d.ts +253 -0
- package/dist/vta/pcs/applications/delete/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/applications/delete/0.1/payload.js +146 -0
- package/dist/vta/pcs/applications/delete/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/applications/show/0.1/payload.d.ts +733 -0
- package/dist/vta/pcs/applications/show/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/applications/show/0.1/payload.js +450 -0
- package/dist/vta/pcs/applications/show/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/attest/0.1/payload.d.ts +1456 -0
- package/dist/vta/pcs/attest/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/attest/0.1/payload.js +876 -0
- package/dist/vta/pcs/attest/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/prove/0.1/payload.d.ts +1348 -0
- package/dist/vta/pcs/prove/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/prove/0.1/payload.js +804 -0
- package/dist/vta/pcs/prove/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/root-accept/0.1/payload.d.ts +1100 -0
- package/dist/vta/pcs/root-accept/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/root-accept/0.1/payload.js +634 -0
- package/dist/vta/pcs/root-accept/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/root-request/0.1/payload.d.ts +880 -0
- package/dist/vta/pcs/root-request/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/root-request/0.1/payload.js +496 -0
- package/dist/vta/pcs/root-request/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/tokens/abandon/0.1/payload.d.ts +612 -0
- package/dist/vta/pcs/tokens/abandon/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/tokens/abandon/0.1/payload.js +355 -0
- package/dist/vta/pcs/tokens/abandon/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/tokens/accept/0.1/payload.d.ts +1149 -0
- package/dist/vta/pcs/tokens/accept/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/tokens/accept/0.1/payload.js +657 -0
- package/dist/vta/pcs/tokens/accept/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/tokens/request/0.1/payload.d.ts +908 -0
- package/dist/vta/pcs/tokens/request/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/tokens/request/0.1/payload.js +508 -0
- package/dist/vta/pcs/tokens/request/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/verify-attestation/0.1/payload.d.ts +1423 -0
- package/dist/vta/pcs/verify-attestation/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/verify-attestation/0.1/payload.js +850 -0
- package/dist/vta/pcs/verify-attestation/0.1/payload.js.map +1 -0
- package/dist/vta/pcs/vetter/show/0.1/payload.d.ts +605 -0
- package/dist/vta/pcs/vetter/show/0.1/payload.d.ts.map +1 -0
- package/dist/vta/pcs/vetter/show/0.1/payload.js +351 -0
- package/dist/vta/pcs/vetter/show/0.1/payload.js.map +1 -0
- package/dist/vtc/vetting/hidden/publish/0.1/payload.d.ts +403 -486
- package/dist/vtc/vetting/hidden/publish/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/vetting/hidden/publish/0.1/payload.js +240 -240
- package/dist/vtc/vetting/hidden/publish/0.1/payload.js.map +1 -1
- package/dist/vtc/vetting/hidden/show/0.1/payload.d.ts +482 -565
- package/dist/vtc/vetting/hidden/show/0.1/payload.d.ts.map +1 -1
- package/dist/vtc/vetting/hidden/show/0.1/payload.js +294 -294
- package/dist/vtc/vetting/hidden/show/0.1/payload.js.map +1 -1
- package/package.json +1 -1
- package/src/_shared/components.ts +308 -2
- package/src/device/list/0.1/payload.ts +6 -2
- package/src/device/list/0.2/payload.ts +6 -2
- package/src/device/register/0.1/payload.ts +6 -2
- package/src/device/register/0.2/payload.ts +6 -2
- package/src/index.ts +14 -0
- package/src/vetting/_shared/0.1/hidden-vetting.ts +17 -0
- package/src/vetting/attestation/0.1/payload.ts +49 -101
- package/src/vta/_shared/0.4/pcs-engine.ts +17 -0
- package/src/vta/pcs/applications/create/0.1/payload.ts +768 -0
- package/src/vta/pcs/applications/delete/0.1/payload.ts +182 -0
- package/src/vta/pcs/applications/show/0.1/payload.ts +482 -0
- package/src/vta/pcs/attest/0.1/payload.ts +943 -0
- package/src/vta/pcs/prove/0.1/payload.ts +845 -0
- package/src/vta/pcs/root-accept/0.1/payload.ts +681 -0
- package/src/vta/pcs/root-request/0.1/payload.ts +559 -0
- package/src/vta/pcs/tokens/abandon/0.1/payload.ts +392 -0
- package/src/vta/pcs/tokens/accept/0.1/payload.ts +713 -0
- package/src/vta/pcs/tokens/request/0.1/payload.ts +581 -0
- package/src/vta/pcs/verify-attestation/0.1/payload.ts +888 -0
- package/src/vta/pcs/vetter/show/0.1/payload.ts +387 -0
- package/src/vtc/vetting/hidden/publish/0.1/payload.ts +247 -331
- package/src/vtc/vetting/hidden/show/0.1/payload.ts +295 -379
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Source: specs/vetting/attestation/0.1/payload.schema.json
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import type { Ext } from "../../../_shared/components.js";
|
|
6
|
+
import type { Ext, StatementMeta } from "../../../_shared/components.js";
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -18,6 +18,9 @@ export interface VettingAttestationPayload {
|
|
|
18
18
|
* The attestation itself, multibase base58btc: a tag, a shown class credential and a proof. It carries no identifier of the vetter — the tag is deterministic for this (vetter, applicant) pair and unlinkable across applicants.
|
|
19
19
|
*/
|
|
20
20
|
attestation: string;
|
|
21
|
+
/**
|
|
22
|
+
* The facts the community will count. Bound into the attestation, so changing one here invalidates it.
|
|
23
|
+
*/
|
|
21
24
|
meta: StatementMeta;
|
|
22
25
|
/**
|
|
23
26
|
* The attestation token spent for this attestation. The community records the serial, which is how a vetter's rate is capped without anybody learning who they are.
|
|
@@ -38,61 +41,6 @@ export interface VettingAttestationPayload {
|
|
|
38
41
|
};
|
|
39
42
|
ext?: Ext;
|
|
40
43
|
}
|
|
41
|
-
/**
|
|
42
|
-
* The facts the community will count. Bound into the attestation, so changing one here invalidates it.
|
|
43
|
-
*/
|
|
44
|
-
export interface StatementMeta {
|
|
45
|
-
/**
|
|
46
|
-
* The community this attestation is for. An attestation is not portable between communities.
|
|
47
|
-
*/
|
|
48
|
-
community: string;
|
|
49
|
-
/**
|
|
50
|
-
* The digest of the criterion's requirements as the vetter read them.
|
|
51
|
-
*/
|
|
52
|
-
requirementsDigest: string;
|
|
53
|
-
/**
|
|
54
|
-
* How the vetter met the applicant.
|
|
55
|
-
*/
|
|
56
|
-
method: "inPerson" | "video" | "priorAcquaintance";
|
|
57
|
-
/**
|
|
58
|
-
* The claim types the vetter checked.
|
|
59
|
-
*
|
|
60
|
-
* @minItems 1
|
|
61
|
-
*/
|
|
62
|
-
claimsVerified: [string, ...string[]];
|
|
63
|
-
/**
|
|
64
|
-
* Whether the vetter confirmed a live person.
|
|
65
|
-
*/
|
|
66
|
-
livenessConfirmed: boolean;
|
|
67
|
-
/**
|
|
68
|
-
* The relationship the vetter declared, which the community's independence rules count.
|
|
69
|
-
*/
|
|
70
|
-
declaredRelationship: "none" | "family" | "sameEmployer" | "closeFriend" | "other";
|
|
71
|
-
/**
|
|
72
|
-
* The commitment on the Vetting Card the applicant showed. Consistency across attestations is what stops two applicants pooling them.
|
|
73
|
-
*/
|
|
74
|
-
identityCommitment: string;
|
|
75
|
-
/**
|
|
76
|
-
* Digest of that card, as the vetter verified it.
|
|
77
|
-
*/
|
|
78
|
-
cardDigestMultibase: string;
|
|
79
|
-
/**
|
|
80
|
-
* A DATE, never a timestamp: an exact time would let a community line an attestation up with a vetter's activity, which undoes the proof without touching it.
|
|
81
|
-
*/
|
|
82
|
-
validFrom: string;
|
|
83
|
-
/**
|
|
84
|
-
* A date, for the same reason.
|
|
85
|
-
*/
|
|
86
|
-
validUntil: string;
|
|
87
|
-
/**
|
|
88
|
-
* The token label spent, repeated inside the bound facts so it cannot be swapped in transit.
|
|
89
|
-
*/
|
|
90
|
-
tokenLabel: string;
|
|
91
|
-
/**
|
|
92
|
-
* The token serial spent, likewise bound.
|
|
93
|
-
*/
|
|
94
|
-
tokenSerial: string;
|
|
95
|
-
}
|
|
96
44
|
/**
|
|
97
45
|
* The applicant's receipt. It verifies the attestation on arrival rather than at submit, so a vetter learns immediately that what it sent is usable.
|
|
98
46
|
*/
|
|
@@ -109,7 +57,7 @@ export interface VettingAttestationResponsePayload {
|
|
|
109
57
|
}
|
|
110
58
|
|
|
111
59
|
/** Shared definitions this specification references, re-exported under the names it used to declare them with. */
|
|
112
|
-
export type { Ext };
|
|
60
|
+
export type { Ext, StatementMeta };
|
|
113
61
|
|
|
114
62
|
/** Trust Task type URI. */
|
|
115
63
|
export const TYPE_URI = "https://trusttasks.org/spec/vetting/attestation/0.1" as const;
|
|
@@ -194,6 +142,40 @@ export const PAYLOAD_SCHEMA = {
|
|
|
194
142
|
}
|
|
195
143
|
},
|
|
196
144
|
"$defs": {
|
|
145
|
+
"Response": {
|
|
146
|
+
"$anchor": "response",
|
|
147
|
+
"title": "Vetting Attestation — response payload",
|
|
148
|
+
"type": "object",
|
|
149
|
+
"additionalProperties": false,
|
|
150
|
+
"required": [
|
|
151
|
+
"accepted"
|
|
152
|
+
],
|
|
153
|
+
"description": "The applicant's receipt. It verifies the attestation on arrival rather than at submit, so a vetter learns immediately that what it sent is usable.",
|
|
154
|
+
"properties": {
|
|
155
|
+
"accepted": {
|
|
156
|
+
"type": "boolean",
|
|
157
|
+
"description": "Whether the attestation verified against the community's published parameters and the card the applicant showed."
|
|
158
|
+
},
|
|
159
|
+
"heldCount": {
|
|
160
|
+
"type": "integer",
|
|
161
|
+
"minimum": 0,
|
|
162
|
+
"description": "OPTIONAL. How many attestations the applicant now holds for this criterion — a courtesy so a vetter can tell someone they are done."
|
|
163
|
+
},
|
|
164
|
+
"ext": {
|
|
165
|
+
"$ref": "#/$defs/Ext"
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
"Ext": {
|
|
170
|
+
"title": "Ext",
|
|
171
|
+
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
172
|
+
"type": "object",
|
|
173
|
+
"minProperties": 1,
|
|
174
|
+
"additionalProperties": true,
|
|
175
|
+
"propertyNames": {
|
|
176
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
177
|
+
}
|
|
178
|
+
},
|
|
197
179
|
"StatementMeta": {
|
|
198
180
|
"type": "object",
|
|
199
181
|
"additionalProperties": false,
|
|
@@ -288,7 +270,15 @@ export const PAYLOAD_SCHEMA = {
|
|
|
288
270
|
"description": "The token serial spent, likewise bound."
|
|
289
271
|
}
|
|
290
272
|
}
|
|
291
|
-
}
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
} as const;
|
|
276
|
+
|
|
277
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
278
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
279
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
280
|
+
"$ref": "#/$defs/Response",
|
|
281
|
+
"$defs": {
|
|
292
282
|
"Response": {
|
|
293
283
|
"$anchor": "response",
|
|
294
284
|
"title": "Vetting Attestation — response payload",
|
|
@@ -322,15 +312,7 @@ export const PAYLOAD_SCHEMA = {
|
|
|
322
312
|
"propertyNames": {
|
|
323
313
|
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
324
314
|
}
|
|
325
|
-
}
|
|
326
|
-
}
|
|
327
|
-
} as const;
|
|
328
|
-
|
|
329
|
-
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
330
|
-
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
331
|
-
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
332
|
-
"$ref": "#/$defs/Response",
|
|
333
|
-
"$defs": {
|
|
315
|
+
},
|
|
334
316
|
"StatementMeta": {
|
|
335
317
|
"type": "object",
|
|
336
318
|
"additionalProperties": false,
|
|
@@ -425,40 +407,6 @@ export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
|
425
407
|
"description": "The token serial spent, likewise bound."
|
|
426
408
|
}
|
|
427
409
|
}
|
|
428
|
-
},
|
|
429
|
-
"Response": {
|
|
430
|
-
"$anchor": "response",
|
|
431
|
-
"title": "Vetting Attestation — response payload",
|
|
432
|
-
"type": "object",
|
|
433
|
-
"additionalProperties": false,
|
|
434
|
-
"required": [
|
|
435
|
-
"accepted"
|
|
436
|
-
],
|
|
437
|
-
"description": "The applicant's receipt. It verifies the attestation on arrival rather than at submit, so a vetter learns immediately that what it sent is usable.",
|
|
438
|
-
"properties": {
|
|
439
|
-
"accepted": {
|
|
440
|
-
"type": "boolean",
|
|
441
|
-
"description": "Whether the attestation verified against the community's published parameters and the card the applicant showed."
|
|
442
|
-
},
|
|
443
|
-
"heldCount": {
|
|
444
|
-
"type": "integer",
|
|
445
|
-
"minimum": 0,
|
|
446
|
-
"description": "OPTIONAL. How many attestations the applicant now holds for this criterion — a courtesy so a vetter can tell someone they are done."
|
|
447
|
-
},
|
|
448
|
-
"ext": {
|
|
449
|
-
"$ref": "#/$defs/Ext"
|
|
450
|
-
}
|
|
451
|
-
}
|
|
452
|
-
},
|
|
453
|
-
"Ext": {
|
|
454
|
-
"title": "Ext",
|
|
455
|
-
"description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
|
|
456
|
-
"type": "object",
|
|
457
|
-
"minProperties": 1,
|
|
458
|
-
"additionalProperties": true,
|
|
459
|
-
"propertyNames": {
|
|
460
|
-
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
461
|
-
}
|
|
462
410
|
}
|
|
463
411
|
}
|
|
464
412
|
} as const;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/vta/_shared/0.4/pcs-engine.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* A VTA can act as the hidden-vetting (PCS) engine of its principal: it holds the principal's PCS secret keys, and runs every member-side PCS operation — a vetter's enrolment, token drip and attestation, and an applicant's receipt of attestations and its proof — so that the client carrying the messages never holds a PCS key. These definitions describe the inputs the engine takes and the wire forms it produces. The normative rules (custody, one key per vetter and community, authorization, audit) are in CONVENTIONS.md beside this file. Not itself a Trust Task specification: the `_shared` folder is skipped by the registry build and the codegen.
|
|
8
|
+
*/
|
|
9
|
+
export interface PCSEngineSharedDefinitionsForTheVtaPcsTasks {
|
|
10
|
+
[k: string]: unknown | undefined;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* The definitions this shared schema publishes, hoisted to one declaration each.
|
|
15
|
+
* See "../../../_shared/components.js".
|
|
16
|
+
*/
|
|
17
|
+
export type { ApplicationSummary, Attestation, AttestationMeta, AttestationToken, CommunityParameters, HiddenVettingSubmission, Multibase, SubmittedStatement, TokenDraw, VetterSummary } from "../../../_shared/components.js";
|