@openvtc/trust-tasks 0.21.9 → 0.21.11
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 +82 -0
- package/dist/_shared/components.d.ts +40 -1
- package/dist/_shared/components.d.ts.map +1 -1
- package/dist/auth/_shared/0.1/session.d.ts +1 -1
- package/dist/auth/_shared/0.1/session.d.ts.map +1 -1
- package/dist/auth/_shared/0.2/session.d.ts +16 -0
- package/dist/auth/_shared/0.2/session.d.ts.map +1 -0
- package/dist/auth/_shared/0.2/session.js +6 -0
- package/dist/auth/_shared/0.2/session.js.map +1 -0
- package/dist/auth/authenticate/0.1/payload.d.ts +1 -1
- package/dist/auth/authenticate/0.1/payload.d.ts.map +1 -1
- package/dist/auth/authenticate/0.2/payload.d.ts +715 -0
- package/dist/auth/authenticate/0.2/payload.d.ts.map +1 -0
- package/dist/auth/authenticate/0.2/payload.js +384 -0
- package/dist/auth/authenticate/0.2/payload.js.map +1 -0
- package/dist/auth/passkey/login/finish/0.1/payload.d.ts +1 -1
- package/dist/auth/passkey/login/finish/0.1/payload.d.ts.map +1 -1
- package/dist/auth/passkey/login/finish/0.2/payload.d.ts +1 -1
- package/dist/auth/passkey/login/finish/0.2/payload.d.ts.map +1 -1
- package/dist/auth/refresh/0.1/payload.d.ts +1 -1
- package/dist/auth/refresh/0.1/payload.d.ts.map +1 -1
- package/dist/auth/sessions/list/0.1/payload.d.ts +1 -1
- package/dist/auth/sessions/list/0.1/payload.d.ts.map +1 -1
- package/dist/auth/step-up/approve-response/0.1/payload.d.ts +1 -1
- package/dist/auth/step-up/approve-response/0.1/payload.d.ts.map +1 -1
- package/dist/auth/step-up/approve-response/0.2/payload.d.ts +1 -1
- package/dist/auth/step-up/approve-response/0.2/payload.d.ts.map +1 -1
- package/dist/auth/step-up/approve-response/0.3/payload.d.ts +1 -1
- package/dist/auth/step-up/approve-response/0.3/payload.d.ts.map +1 -1
- package/dist/auth/step-up/approve-response/0.4/payload.d.ts +1 -1
- package/dist/auth/step-up/approve-response/0.4/payload.d.ts.map +1 -1
- package/dist/auth/step-up/approve-response/0.5/payload.d.ts +1 -1
- package/dist/auth/step-up/approve-response/0.5/payload.d.ts.map +1 -1
- package/dist/auth/whoami/0.1/payload.d.ts +1 -1
- package/dist/auth/whoami/0.1/payload.d.ts.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/trust-task-discovery/0.3/payload.d.ts +483 -0
- package/dist/trust-task-discovery/0.3/payload.d.ts.map +1 -0
- package/dist/trust-task-discovery/0.3/payload.js +242 -0
- package/dist/trust-task-discovery/0.3/payload.js.map +1 -0
- package/package.json +1 -1
- package/src/_shared/components.ts +40 -1
- package/src/auth/_shared/0.1/session.ts +1 -1
- package/src/auth/_shared/0.2/session.ts +17 -0
- package/src/auth/authenticate/0.1/payload.ts +1 -1
- package/src/auth/authenticate/0.2/payload.ts +444 -0
- package/src/auth/passkey/login/finish/0.1/payload.ts +1 -1
- package/src/auth/passkey/login/finish/0.2/payload.ts +1 -1
- package/src/auth/refresh/0.1/payload.ts +1 -1
- package/src/auth/sessions/list/0.1/payload.ts +1 -1
- package/src/auth/step-up/approve-response/0.1/payload.ts +1 -1
- package/src/auth/step-up/approve-response/0.2/payload.ts +1 -1
- package/src/auth/step-up/approve-response/0.3/payload.ts +1 -1
- package/src/auth/step-up/approve-response/0.4/payload.ts +1 -1
- package/src/auth/step-up/approve-response/0.5/payload.ts +1 -1
- package/src/auth/whoami/0.1/payload.ts +1 -1
- package/src/index.ts +3 -0
- package/src/trust-task-discovery/0.3/payload.ts +357 -0
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/trust-task-discovery/0.3/payload.schema.json
|
|
4
|
+
*/
|
|
5
|
+
/** Trust Task type URI. */
|
|
6
|
+
export const TYPE_URI = "https://trusttasks.org/spec/trust-task-discovery/0.3";
|
|
7
|
+
/** Trust Task response type URI (request type URI + "#response"). */
|
|
8
|
+
export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/trust-task-discovery/0.3#response";
|
|
9
|
+
/**
|
|
10
|
+
* This specification's payload schema, as a value.
|
|
11
|
+
*
|
|
12
|
+
* SPEC.md §7.2 item 2 is performed against this. It is shipped as data
|
|
13
|
+
* rather than only as a `.json` file because TypeScript types are erased
|
|
14
|
+
* at runtime: without a schema a consumer has nothing to validate, and
|
|
15
|
+
* every REQUIRED payload member is optional in practice. Cross-file
|
|
16
|
+
* `$ref`s are already inlined, so it needs no resolver.
|
|
17
|
+
*/
|
|
18
|
+
export const PAYLOAD_SCHEMA = {
|
|
19
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
20
|
+
"$id": "https://trusttasks.org/spec/trust-task-discovery/0.3",
|
|
21
|
+
"title": "Trust Task Discovery — payload",
|
|
22
|
+
"description": "Request payload for the framework-defined trust-task-discovery exchange. Carries zero or more slug-glob patterns the discoverer wants the responder to filter against. The response payload schema is reachable via $anchor: 'response'.",
|
|
23
|
+
"type": "object",
|
|
24
|
+
"additionalProperties": false,
|
|
25
|
+
"properties": {
|
|
26
|
+
"patterns": {
|
|
27
|
+
"type": "array",
|
|
28
|
+
"maxItems": 16,
|
|
29
|
+
"items": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"minLength": 1,
|
|
32
|
+
"description": "Slug-glob pattern. Matches: '*' (every slug); '<prefix>/*' (any slug starting with '<prefix>/' — e.g. 'acl/*' matches 'acl/grant', 'acl/revoke', 'acl/grant/sub'); otherwise an exact slug match. Wildcards anywhere other than as a trailing segment are not interpreted — the only sigils are the trailing '/*' and the bare '*'."
|
|
33
|
+
},
|
|
34
|
+
"description": "Patterns are ORed: a slug matches the query if at least one pattern matches it. If the array is omitted or empty, the responder MUST treat the query as ['*'] — return every supported task. Bounded at 16 entries as parser hardening (SPEC.md §12.2), not as a capability limit: matching an unbounded pattern list against every published slug is work a responder does on an unauthenticated request, and a discoverer wanting more asks for '*' and filters locally."
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"$defs": {
|
|
38
|
+
"AcceptanceWindow": {
|
|
39
|
+
"title": "Acceptance window",
|
|
40
|
+
"description": "The freshness bounds a responder applies, as a consumer, to the `issuedAt` of a document it receives (SPEC.md §7.2 item 13). A responder refuses a document when now > issuedAt + maxAgeSeconds + clockSkewSeconds, and when issuedAt > now + clockSkewSeconds. It says nothing about `expiresAt`, which is honoured independently (SPEC.md §7.2 item 4). Both members are whole seconds.",
|
|
41
|
+
"type": "object",
|
|
42
|
+
"additionalProperties": false,
|
|
43
|
+
"required": [
|
|
44
|
+
"maxAgeSeconds",
|
|
45
|
+
"clockSkewSeconds"
|
|
46
|
+
],
|
|
47
|
+
"properties": {
|
|
48
|
+
"maxAgeSeconds": {
|
|
49
|
+
"type": "integer",
|
|
50
|
+
"minimum": 1,
|
|
51
|
+
"description": "The greatest age, in whole seconds, of a document's `issuedAt` at which the responder still accepts the document, before any clock-skew tolerance is applied."
|
|
52
|
+
},
|
|
53
|
+
"clockSkewSeconds": {
|
|
54
|
+
"type": "integer",
|
|
55
|
+
"minimum": 0,
|
|
56
|
+
"description": "The clock-skew tolerance, in whole seconds, the responder applies in both directions: added to maxAgeSeconds for a document in its past, and allowed for an `issuedAt` in its future (SPEC.md §4.2, §7.2 item 13). Zero when it applies none."
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"Response": {
|
|
61
|
+
"$anchor": "response",
|
|
62
|
+
"title": "Trust Task Discovery — response payload",
|
|
63
|
+
"description": "List of bare Type URIs the responding party supports. Carried in a Trust Task document whose type is https://trusttasks.org/spec/trust-task-discovery/0.3#response. A response-level `acceptanceWindow` is the window the responder applies to every listed Type URI whose entry carries none of its own. Where neither is present for an entry, the discoverer has learnt nothing about that entry's window and MUST NOT read the absence as the absence of a window.",
|
|
64
|
+
"type": "object",
|
|
65
|
+
"additionalProperties": false,
|
|
66
|
+
"required": [
|
|
67
|
+
"supportedTypes"
|
|
68
|
+
],
|
|
69
|
+
"properties": {
|
|
70
|
+
"supportedTypes": {
|
|
71
|
+
"type": "array",
|
|
72
|
+
"items": {
|
|
73
|
+
"oneOf": [
|
|
74
|
+
{
|
|
75
|
+
"type": "string",
|
|
76
|
+
"format": "uri",
|
|
77
|
+
"description": "Shorthand form: a bare Type URI string. Equivalent to an object with only the `type` member set."
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"type": "object",
|
|
81
|
+
"additionalProperties": false,
|
|
82
|
+
"required": [
|
|
83
|
+
"type"
|
|
84
|
+
],
|
|
85
|
+
"properties": {
|
|
86
|
+
"type": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"format": "uri",
|
|
89
|
+
"description": "A bare Type URI (no #request or #response fragment). The responder supports both request and response variants of every entry it lists."
|
|
90
|
+
},
|
|
91
|
+
"requiredExt": {
|
|
92
|
+
"type": "array",
|
|
93
|
+
"items": {
|
|
94
|
+
"type": "string",
|
|
95
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
96
|
+
},
|
|
97
|
+
"minItems": 1,
|
|
98
|
+
"uniqueItems": true,
|
|
99
|
+
"description": "Reverse-DNS `ext` namespaces this responder requires on inbound documents of this Type URI as a matter of local policy (SPEC.md §4.5.1, §7.2). A producer that does not populate every listed namespace will receive a `malformedRequest` rejection. Optional; reserved-but-recognized in 0.1, RECOMMENDED in future revisions for responders that enforce such policies."
|
|
100
|
+
},
|
|
101
|
+
"acceptanceWindow": {
|
|
102
|
+
"$ref": "#/$defs/AcceptanceWindow"
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"description": "Object form: lists a Type URI together with optional capability annotations. An `acceptanceWindow` here is the window the responder applies to documents of this Type URI, and takes precedence over the response-level `acceptanceWindow` for this entry."
|
|
106
|
+
}
|
|
107
|
+
],
|
|
108
|
+
"description": "An entry in the supportedTypes list. SHORTHAND: a bare Type URI string. EXPANDED: an object with `type` and optional capability annotations (`requiredExt`, `acceptanceWindow`)."
|
|
109
|
+
},
|
|
110
|
+
"description": "Each entry's Type URI MUST match at least one of the request's patterns (if any were supplied). Order is not significant. Duplicates by Type URI are not permitted, regardless of whether the entry is in shorthand or expanded form."
|
|
111
|
+
},
|
|
112
|
+
"frameworkVersion": {
|
|
113
|
+
"type": "string",
|
|
114
|
+
"pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$",
|
|
115
|
+
"description": "MAJOR.MINOR.PATCH version of the Trust Tasks framework specification (SPEC.md) the responder targets — three-part, as the framework has been versioned since 0.4.0 (SPEC.md §5.1.1), and exactly the value a Trust Task specification declares as its target framework version. Lets a discoverer reason about compatibility (SPEC.md §5.2) and select the envelope schema a responder's documents are validated against, which is keyed by the full release: a PATCH is never substituted for another. RECOMMENDED. Two-part in trust-task-discovery/0.1, which could not express a PATCH."
|
|
116
|
+
},
|
|
117
|
+
"acceptanceWindow": {
|
|
118
|
+
"$ref": "#/$defs/AcceptanceWindow"
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
/** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
|
|
125
|
+
export const RESPONSE_PAYLOAD_SCHEMA = {
|
|
126
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
127
|
+
"$ref": "#/$defs/Response",
|
|
128
|
+
"$defs": {
|
|
129
|
+
"AcceptanceWindow": {
|
|
130
|
+
"title": "Acceptance window",
|
|
131
|
+
"description": "The freshness bounds a responder applies, as a consumer, to the `issuedAt` of a document it receives (SPEC.md §7.2 item 13). A responder refuses a document when now > issuedAt + maxAgeSeconds + clockSkewSeconds, and when issuedAt > now + clockSkewSeconds. It says nothing about `expiresAt`, which is honoured independently (SPEC.md §7.2 item 4). Both members are whole seconds.",
|
|
132
|
+
"type": "object",
|
|
133
|
+
"additionalProperties": false,
|
|
134
|
+
"required": [
|
|
135
|
+
"maxAgeSeconds",
|
|
136
|
+
"clockSkewSeconds"
|
|
137
|
+
],
|
|
138
|
+
"properties": {
|
|
139
|
+
"maxAgeSeconds": {
|
|
140
|
+
"type": "integer",
|
|
141
|
+
"minimum": 1,
|
|
142
|
+
"description": "The greatest age, in whole seconds, of a document's `issuedAt` at which the responder still accepts the document, before any clock-skew tolerance is applied."
|
|
143
|
+
},
|
|
144
|
+
"clockSkewSeconds": {
|
|
145
|
+
"type": "integer",
|
|
146
|
+
"minimum": 0,
|
|
147
|
+
"description": "The clock-skew tolerance, in whole seconds, the responder applies in both directions: added to maxAgeSeconds for a document in its past, and allowed for an `issuedAt` in its future (SPEC.md §4.2, §7.2 item 13). Zero when it applies none."
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
"Response": {
|
|
152
|
+
"$anchor": "response",
|
|
153
|
+
"title": "Trust Task Discovery — response payload",
|
|
154
|
+
"description": "List of bare Type URIs the responding party supports. Carried in a Trust Task document whose type is https://trusttasks.org/spec/trust-task-discovery/0.3#response. A response-level `acceptanceWindow` is the window the responder applies to every listed Type URI whose entry carries none of its own. Where neither is present for an entry, the discoverer has learnt nothing about that entry's window and MUST NOT read the absence as the absence of a window.",
|
|
155
|
+
"type": "object",
|
|
156
|
+
"additionalProperties": false,
|
|
157
|
+
"required": [
|
|
158
|
+
"supportedTypes"
|
|
159
|
+
],
|
|
160
|
+
"properties": {
|
|
161
|
+
"supportedTypes": {
|
|
162
|
+
"type": "array",
|
|
163
|
+
"items": {
|
|
164
|
+
"oneOf": [
|
|
165
|
+
{
|
|
166
|
+
"type": "string",
|
|
167
|
+
"format": "uri",
|
|
168
|
+
"description": "Shorthand form: a bare Type URI string. Equivalent to an object with only the `type` member set."
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"type": "object",
|
|
172
|
+
"additionalProperties": false,
|
|
173
|
+
"required": [
|
|
174
|
+
"type"
|
|
175
|
+
],
|
|
176
|
+
"properties": {
|
|
177
|
+
"type": {
|
|
178
|
+
"type": "string",
|
|
179
|
+
"format": "uri",
|
|
180
|
+
"description": "A bare Type URI (no #request or #response fragment). The responder supports both request and response variants of every entry it lists."
|
|
181
|
+
},
|
|
182
|
+
"requiredExt": {
|
|
183
|
+
"type": "array",
|
|
184
|
+
"items": {
|
|
185
|
+
"type": "string",
|
|
186
|
+
"pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
|
|
187
|
+
},
|
|
188
|
+
"minItems": 1,
|
|
189
|
+
"uniqueItems": true,
|
|
190
|
+
"description": "Reverse-DNS `ext` namespaces this responder requires on inbound documents of this Type URI as a matter of local policy (SPEC.md §4.5.1, §7.2). A producer that does not populate every listed namespace will receive a `malformedRequest` rejection. Optional; reserved-but-recognized in 0.1, RECOMMENDED in future revisions for responders that enforce such policies."
|
|
191
|
+
},
|
|
192
|
+
"acceptanceWindow": {
|
|
193
|
+
"$ref": "#/$defs/AcceptanceWindow"
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
"description": "Object form: lists a Type URI together with optional capability annotations. An `acceptanceWindow` here is the window the responder applies to documents of this Type URI, and takes precedence over the response-level `acceptanceWindow` for this entry."
|
|
197
|
+
}
|
|
198
|
+
],
|
|
199
|
+
"description": "An entry in the supportedTypes list. SHORTHAND: a bare Type URI string. EXPANDED: an object with `type` and optional capability annotations (`requiredExt`, `acceptanceWindow`)."
|
|
200
|
+
},
|
|
201
|
+
"description": "Each entry's Type URI MUST match at least one of the request's patterns (if any were supplied). Order is not significant. Duplicates by Type URI are not permitted, regardless of whether the entry is in shorthand or expanded form."
|
|
202
|
+
},
|
|
203
|
+
"frameworkVersion": {
|
|
204
|
+
"type": "string",
|
|
205
|
+
"pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$",
|
|
206
|
+
"description": "MAJOR.MINOR.PATCH version of the Trust Tasks framework specification (SPEC.md) the responder targets — three-part, as the framework has been versioned since 0.4.0 (SPEC.md §5.1.1), and exactly the value a Trust Task specification declares as its target framework version. Lets a discoverer reason about compatibility (SPEC.md §5.2) and select the envelope schema a responder's documents are validated against, which is keyed by the full release: a PATCH is never substituted for another. RECOMMENDED. Two-part in trust-task-discovery/0.1, which could not express a PATCH."
|
|
207
|
+
},
|
|
208
|
+
"acceptanceWindow": {
|
|
209
|
+
"$ref": "#/$defs/AcceptanceWindow"
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
};
|
|
215
|
+
/**
|
|
216
|
+
* SPEC.md §7.2 policy for the request variant, from this specification's
|
|
217
|
+
* front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
|
|
218
|
+
* per-specification and cannot be derived from the document alone, and
|
|
219
|
+
* item 2 needs the schema this carries.
|
|
220
|
+
*/
|
|
221
|
+
export const SPEC = {
|
|
222
|
+
typeUri: TYPE_URI,
|
|
223
|
+
isBearer: false,
|
|
224
|
+
isProofRequired: false,
|
|
225
|
+
isRecipientRequired: true,
|
|
226
|
+
isIssuedAtRequired: false,
|
|
227
|
+
payloadSchema: PAYLOAD_SCHEMA,
|
|
228
|
+
};
|
|
229
|
+
/**
|
|
230
|
+
* SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
|
|
231
|
+
* tracks the *issuer* party's requirement because a response swaps the
|
|
232
|
+
* parties (§7.3 item 5).
|
|
233
|
+
*/
|
|
234
|
+
export const RESPONSE_SPEC = {
|
|
235
|
+
typeUri: RESPONSE_TYPE_URI,
|
|
236
|
+
isBearer: false,
|
|
237
|
+
isProofRequired: false,
|
|
238
|
+
isRecipientRequired: true,
|
|
239
|
+
isIssuedAtRequired: false,
|
|
240
|
+
payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
|
|
241
|
+
};
|
|
242
|
+
//# sourceMappingURL=payload.js.map
|
|
@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C;iCACF;gCACD,aAAa,EAAE,4PAA4P;6BAC5Q;yBACF;wBACD,aAAa,EAAE,kLAAkL;qBAClM;oBACD,aAAa,EAAE,uOAAuO;iBACvP;gBACD,kBAAkB,EAAE;oBAClB,MAAM,EAAE,QAAQ;oBAChB,SAAS,EAAE,uDAAuD;oBAClE,aAAa,EAAE,6jBAA6jB;iBAC7kB;gBACD,kBAAkB,EAAE;oBAClB,MAAM,EAAE,0BAA0B;iBACnC;aACF;SACF;KACF;CACO,CAAC;AAEX;;;;;GAKG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG;IAClB,OAAO,EAAE,QAAQ;IACjB,QAAQ,EAAE,KAAK;IACf,eAAe,EAAE,KAAK;IACtB,mBAAmB,EAAE,IAAI;IACzB,kBAAkB,EAAE,KAAK;IACzB,aAAa,EAAE,cAAc;CACrB,CAAC;AAEX;;;;GAIG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,OAAO,EAAE,iBAAiB;IAC1B,QAAQ,EAAE,KAAK;IACf,eAAe,EAAE,KAAK;IACtB,mBAAmB,EAAE,IAAI;IACzB,kBAAkB,EAAE,KAAK;IACzB,aAAa,EAAE,uBAAuB;CAC9B,CAAC"}
|
package/package.json
CHANGED
|
@@ -4703,7 +4703,7 @@ export interface ServiceState {
|
|
|
4703
4703
|
/**
|
|
4704
4704
|
* A logical authentication context bound to a subject. Producers and consumers exchange Session-shaped data in challenge issuance, authentication responses, and introspection (whoami).
|
|
4705
4705
|
*/
|
|
4706
|
-
export interface
|
|
4706
|
+
export interface Session_AuthV0_1 {
|
|
4707
4707
|
/**
|
|
4708
4708
|
* Opaque, server-chosen session identifier. Stable for the lifetime of the session. Consumers MUST treat the value as opaque; no structure is implied.
|
|
4709
4709
|
*/
|
|
@@ -4735,6 +4735,45 @@ export interface Session {
|
|
|
4735
4735
|
*/
|
|
4736
4736
|
ext?: Ext;
|
|
4737
4737
|
}
|
|
4738
|
+
/**
|
|
4739
|
+
* A logical authentication context bound to a subject. Producers and consumers exchange Session-shaped data in challenge issuance, authentication responses, and introspection (whoami).
|
|
4740
|
+
*/
|
|
4741
|
+
export interface Session_AuthV0_2 {
|
|
4742
|
+
/**
|
|
4743
|
+
* Opaque, server-chosen session identifier. Stable for the lifetime of the session. Consumers MUST treat the value as opaque; no structure is implied.
|
|
4744
|
+
*/
|
|
4745
|
+
id: string;
|
|
4746
|
+
/**
|
|
4747
|
+
* The authenticated party's VID (typically a DID URL).
|
|
4748
|
+
*/
|
|
4749
|
+
subject: string;
|
|
4750
|
+
/**
|
|
4751
|
+
* ISO-8601 timestamp when the session was created.
|
|
4752
|
+
*/
|
|
4753
|
+
issuedAt: string;
|
|
4754
|
+
/**
|
|
4755
|
+
* ISO-8601 timestamp when the session ceases to be valid. Producers SHOULD refresh before this time; consumers MUST reject after.
|
|
4756
|
+
*/
|
|
4757
|
+
expiresAt: string;
|
|
4758
|
+
/**
|
|
4759
|
+
* Authentication Methods References per [RFC 8176]. Typical values: "did" (challenge-response), "passkey" (WebAuthn), "vta" (verifiable-trust agent approval). Multi-factor sessions list every method used.
|
|
4760
|
+
*
|
|
4761
|
+
* @minItems 1
|
|
4762
|
+
*/
|
|
4763
|
+
amr?: [string, ...string[]];
|
|
4764
|
+
/**
|
|
4765
|
+
* Authentication Context Class Reference per [OIDC Core §2]. Profiles define their own values; the recommended set is "aal1" (single-factor DID auth), "aal2" (a second possession-or-biometric factor confirmed), and "aal3" (hardware-bound second factor).
|
|
4766
|
+
*/
|
|
4767
|
+
acr?: string;
|
|
4768
|
+
/**
|
|
4769
|
+
* The did:key VID bound to this session by auth/authenticate/0.2, when the producer registered one. Present here so introspection (auth/whoami, auth/sessions/list) can show the binding a client already holds; it is descriptive, not an additional grant — the binding, its scope and its lifetime are governed entirely by the auth/authenticate/0.2 specification that established it. Absent when the session was established without a session key, or by a specification version that does not carry one.
|
|
4770
|
+
*/
|
|
4771
|
+
sessionKey?: string;
|
|
4772
|
+
/**
|
|
4773
|
+
* Ecosystem-defined extension members per SPEC.md §4.5.1.
|
|
4774
|
+
*/
|
|
4775
|
+
ext?: Ext;
|
|
4776
|
+
}
|
|
4738
4777
|
export interface WebOrigin_VaultV0_1 {
|
|
4739
4778
|
kind: "web-origin";
|
|
4740
4779
|
/**
|
|
@@ -14,4 +14,4 @@ export interface AuthSharedSessionDefinitions {
|
|
|
14
14
|
* The definitions this shared schema publishes, hoisted to one declaration each.
|
|
15
15
|
* See "../../../_shared/components.js".
|
|
16
16
|
*/
|
|
17
|
-
export type { Session } from "../../../_shared/components.js";
|
|
17
|
+
export type { Session_AuthV0_1 as Session } from "../../../_shared/components.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
|
|
3
|
+
* Source: specs/auth/_shared/0.2/session.schema.json
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Reusable JSON Schema fragments that describe an authenticated session, referenced by the auth/* Trust Task specifications. 0.2 adds the optional sessionKey binding (auth/authenticate/0.2); 0.1 remains in place for specifications still pinned to it (SPEC.md §6.6 item 3 — a component version bump never changes an already-published specification version underfoot).
|
|
8
|
+
*/
|
|
9
|
+
export interface AuthSharedSessionDefinitions {
|
|
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 { Session_AuthV0_2 as Session } from "../../../_shared/components.js";
|