@pagopa/io-react-native-wallet 2.0.0-next.4 → 2.0.0-next.6
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/lib/commonjs/credential/issuance/07-verify-and-parse-credential.js +3 -3
- package/lib/commonjs/credential/issuance/07-verify-and-parse-credential.js.map +1 -1
- package/lib/commonjs/credential/status/{02-status-attestation.js → 02-status-assertion.js} +28 -22
- package/lib/commonjs/credential/status/02-status-assertion.js.map +1 -0
- package/lib/commonjs/credential/status/03-verify-and-parse-status-assertion.js +85 -0
- package/lib/commonjs/credential/status/03-verify-and-parse-status-assertion.js.map +1 -0
- package/lib/commonjs/credential/status/README.md +22 -20
- package/lib/commonjs/credential/status/index.js +6 -6
- package/lib/commonjs/credential/status/index.js.map +1 -1
- package/lib/commonjs/credential/status/types.js +48 -15
- package/lib/commonjs/credential/status/types.js.map +1 -1
- package/lib/commonjs/trust/types.js +2 -1
- package/lib/commonjs/trust/types.js.map +1 -1
- package/lib/commonjs/utils/credentials.js +33 -0
- package/lib/commonjs/utils/credentials.js.map +1 -0
- package/lib/commonjs/utils/crypto.js +1 -7
- package/lib/commonjs/utils/crypto.js.map +1 -1
- package/lib/commonjs/utils/jwk.js +12 -0
- package/lib/commonjs/utils/jwk.js.map +1 -1
- package/lib/module/credential/issuance/07-verify-and-parse-credential.js +4 -4
- package/lib/module/credential/issuance/07-verify-and-parse-credential.js.map +1 -1
- package/lib/module/credential/status/{02-status-attestation.js → 02-status-assertion.js} +28 -22
- package/lib/module/credential/status/02-status-assertion.js.map +1 -0
- package/lib/module/credential/status/03-verify-and-parse-status-assertion.js +78 -0
- package/lib/module/credential/status/03-verify-and-parse-status-assertion.js.map +1 -0
- package/lib/module/credential/status/README.md +22 -20
- package/lib/module/credential/status/index.js +3 -3
- package/lib/module/credential/status/index.js.map +1 -1
- package/lib/module/credential/status/types.js +43 -12
- package/lib/module/credential/status/types.js.map +1 -1
- package/lib/module/trust/types.js +2 -1
- package/lib/module/trust/types.js.map +1 -1
- package/lib/module/utils/credentials.js +26 -0
- package/lib/module/utils/credentials.js.map +1 -0
- package/lib/module/utils/crypto.js +2 -8
- package/lib/module/utils/crypto.js.map +1 -1
- package/lib/module/utils/jwk.js +11 -1
- package/lib/module/utils/jwk.js.map +1 -1
- package/lib/typescript/credential/issuance/07-verify-and-parse-credential.d.ts.map +1 -1
- package/lib/typescript/credential/status/02-status-assertion.d.ts +23 -0
- package/lib/typescript/credential/status/02-status-assertion.d.ts.map +1 -0
- package/lib/typescript/credential/status/03-verify-and-parse-status-assertion.d.ts +21 -0
- package/lib/typescript/credential/status/03-verify-and-parse-status-assertion.d.ts.map +1 -0
- package/lib/typescript/credential/status/index.d.ts +4 -4
- package/lib/typescript/credential/status/index.d.ts.map +1 -1
- package/lib/typescript/credential/status/types.d.ts +495 -18
- package/lib/typescript/credential/status/types.d.ts.map +1 -1
- package/lib/typescript/trust/build-chain.d.ts +2 -2
- package/lib/typescript/trust/types.d.ts +26 -26
- package/lib/typescript/utils/credentials.d.ts +11 -0
- package/lib/typescript/utils/credentials.d.ts.map +1 -0
- package/lib/typescript/utils/crypto.d.ts.map +1 -1
- package/lib/typescript/utils/jwk.d.ts +7 -0
- package/lib/typescript/utils/jwk.d.ts.map +1 -1
- package/package.json +6 -8
- package/src/credential/issuance/07-verify-and-parse-credential.ts +4 -6
- package/src/credential/status/{02-status-attestation.ts → 02-status-assertion.ts} +37 -28
- package/src/credential/status/03-verify-and-parse-status-assertion.ts +109 -0
- package/src/credential/status/README.md +22 -20
- package/src/credential/status/index.ts +7 -14
- package/src/credential/status/types.ts +62 -15
- package/src/trust/types.ts +1 -1
- package/src/utils/credentials.ts +29 -0
- package/src/utils/crypto.ts +12 -20
- package/src/utils/jwk.ts +15 -1
- package/lib/commonjs/credential/status/02-status-attestation.js.map +0 -1
- package/lib/commonjs/credential/status/03-verify-and-parse-status-attestation.js +0 -55
- package/lib/commonjs/credential/status/03-verify-and-parse-status-attestation.js.map +0 -1
- package/lib/module/credential/status/02-status-attestation.js.map +0 -1
- package/lib/module/credential/status/03-verify-and-parse-status-attestation.js +0 -49
- package/lib/module/credential/status/03-verify-and-parse-status-attestation.js.map +0 -1
- package/lib/typescript/credential/status/02-status-attestation.d.ts +0 -19
- package/lib/typescript/credential/status/02-status-attestation.d.ts.map +0 -1
- package/lib/typescript/credential/status/03-verify-and-parse-status-attestation.d.ts +0 -24
- package/lib/typescript/credential/status/03-verify-and-parse-status-attestation.d.ts.map +0 -1
- package/src/credential/status/03-verify-and-parse-status-attestation.ts +0 -70
@@ -1,41 +1,431 @@
|
|
1
1
|
import * as z from "zod";
|
2
2
|
/**
|
3
|
-
* Shape from parsing a status
|
3
|
+
* Shape from parsing a status assertion response in case of 201.
|
4
4
|
*/
|
5
|
-
export declare const
|
6
|
-
|
5
|
+
export declare const StatusAssertionResponse: z.ZodObject<{
|
6
|
+
status_assertion_responses: z.ZodArray<z.ZodString, "many">;
|
7
7
|
}, "strip", z.ZodTypeAny, {
|
8
|
-
|
8
|
+
status_assertion_responses: string[];
|
9
9
|
}, {
|
10
|
-
|
10
|
+
status_assertion_responses: string[];
|
11
11
|
}>;
|
12
12
|
/**
|
13
|
-
* Type from parsing a status
|
14
|
-
* Inferred from {@link
|
13
|
+
* Type from parsing a status assertion response in case of 201.
|
14
|
+
* Inferred from {@link StatusAssertionResponse}.
|
15
15
|
*/
|
16
|
-
export type
|
16
|
+
export type StatusAssertionResponse = z.infer<typeof StatusAssertionResponse>;
|
17
|
+
export type ParsedStatusAssertion = z.infer<typeof ParsedStatusAssertion>;
|
17
18
|
/**
|
18
|
-
*
|
19
|
+
* Shape for parsing a successful status assertion in a JWT.
|
19
20
|
*/
|
20
|
-
export
|
21
|
+
export declare const ParsedStatusAssertion: z.ZodObject<{
|
22
|
+
header: z.ZodObject<{
|
23
|
+
typ: z.ZodLiteral<"status-assertion+jwt">;
|
24
|
+
alg: z.ZodString;
|
25
|
+
kid: z.ZodOptional<z.ZodString>;
|
26
|
+
}, "strip", z.ZodTypeAny, {
|
27
|
+
alg: string;
|
28
|
+
typ: "status-assertion+jwt";
|
29
|
+
kid?: string | undefined;
|
30
|
+
}, {
|
31
|
+
alg: string;
|
32
|
+
typ: "status-assertion+jwt";
|
33
|
+
kid?: string | undefined;
|
34
|
+
}>;
|
35
|
+
payload: z.ZodObject<{
|
36
|
+
iss: z.ZodString;
|
37
|
+
credential_status_type: z.ZodString;
|
38
|
+
credential_status_detail: z.ZodOptional<z.ZodObject<{
|
39
|
+
state: z.ZodString;
|
40
|
+
description: z.ZodString;
|
41
|
+
}, "strip", z.ZodTypeAny, {
|
42
|
+
state: string;
|
43
|
+
description: string;
|
44
|
+
}, {
|
45
|
+
state: string;
|
46
|
+
description: string;
|
47
|
+
}>>;
|
48
|
+
credential_hash_alg: z.ZodString;
|
49
|
+
credential_hash: z.ZodString;
|
50
|
+
cnf: z.ZodObject<{
|
51
|
+
jwk: z.ZodObject<{
|
52
|
+
alg: z.ZodOptional<z.ZodString>;
|
53
|
+
crv: z.ZodOptional<z.ZodString>;
|
54
|
+
d: z.ZodOptional<z.ZodString>;
|
55
|
+
dp: z.ZodOptional<z.ZodString>;
|
56
|
+
dq: z.ZodOptional<z.ZodString>;
|
57
|
+
e: z.ZodOptional<z.ZodString>;
|
58
|
+
ext: z.ZodOptional<z.ZodBoolean>;
|
59
|
+
k: z.ZodOptional<z.ZodString>;
|
60
|
+
key_ops: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
61
|
+
kid: z.ZodOptional<z.ZodString>;
|
62
|
+
kty: z.ZodUnion<[z.ZodLiteral<"RSA">, z.ZodLiteral<"EC">]>;
|
63
|
+
n: z.ZodOptional<z.ZodString>;
|
64
|
+
p: z.ZodOptional<z.ZodString>;
|
65
|
+
q: z.ZodOptional<z.ZodString>;
|
66
|
+
qi: z.ZodOptional<z.ZodString>;
|
67
|
+
use: z.ZodOptional<z.ZodString>;
|
68
|
+
x: z.ZodOptional<z.ZodString>;
|
69
|
+
y: z.ZodOptional<z.ZodString>;
|
70
|
+
x5c: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
71
|
+
x5t: z.ZodOptional<z.ZodString>;
|
72
|
+
"x5t#S256": z.ZodOptional<z.ZodString>;
|
73
|
+
x5u: z.ZodOptional<z.ZodString>;
|
74
|
+
}, "strip", z.ZodTypeAny, {
|
75
|
+
kty: "RSA" | "EC";
|
76
|
+
alg?: string | undefined;
|
77
|
+
crv?: string | undefined;
|
78
|
+
d?: string | undefined;
|
79
|
+
dp?: string | undefined;
|
80
|
+
dq?: string | undefined;
|
81
|
+
e?: string | undefined;
|
82
|
+
ext?: boolean | undefined;
|
83
|
+
k?: string | undefined;
|
84
|
+
key_ops?: string[] | undefined;
|
85
|
+
kid?: string | undefined;
|
86
|
+
n?: string | undefined;
|
87
|
+
p?: string | undefined;
|
88
|
+
q?: string | undefined;
|
89
|
+
qi?: string | undefined;
|
90
|
+
use?: string | undefined;
|
91
|
+
x?: string | undefined;
|
92
|
+
y?: string | undefined;
|
93
|
+
x5c?: string[] | undefined;
|
94
|
+
x5t?: string | undefined;
|
95
|
+
"x5t#S256"?: string | undefined;
|
96
|
+
x5u?: string | undefined;
|
97
|
+
}, {
|
98
|
+
kty: "RSA" | "EC";
|
99
|
+
alg?: string | undefined;
|
100
|
+
crv?: string | undefined;
|
101
|
+
d?: string | undefined;
|
102
|
+
dp?: string | undefined;
|
103
|
+
dq?: string | undefined;
|
104
|
+
e?: string | undefined;
|
105
|
+
ext?: boolean | undefined;
|
106
|
+
k?: string | undefined;
|
107
|
+
key_ops?: string[] | undefined;
|
108
|
+
kid?: string | undefined;
|
109
|
+
n?: string | undefined;
|
110
|
+
p?: string | undefined;
|
111
|
+
q?: string | undefined;
|
112
|
+
qi?: string | undefined;
|
113
|
+
use?: string | undefined;
|
114
|
+
x?: string | undefined;
|
115
|
+
y?: string | undefined;
|
116
|
+
x5c?: string[] | undefined;
|
117
|
+
x5t?: string | undefined;
|
118
|
+
"x5t#S256"?: string | undefined;
|
119
|
+
x5u?: string | undefined;
|
120
|
+
}>;
|
121
|
+
}, "strip", z.ZodTypeAny, {
|
122
|
+
jwk: {
|
123
|
+
kty: "RSA" | "EC";
|
124
|
+
alg?: string | undefined;
|
125
|
+
crv?: string | undefined;
|
126
|
+
d?: string | undefined;
|
127
|
+
dp?: string | undefined;
|
128
|
+
dq?: string | undefined;
|
129
|
+
e?: string | undefined;
|
130
|
+
ext?: boolean | undefined;
|
131
|
+
k?: string | undefined;
|
132
|
+
key_ops?: string[] | undefined;
|
133
|
+
kid?: string | undefined;
|
134
|
+
n?: string | undefined;
|
135
|
+
p?: string | undefined;
|
136
|
+
q?: string | undefined;
|
137
|
+
qi?: string | undefined;
|
138
|
+
use?: string | undefined;
|
139
|
+
x?: string | undefined;
|
140
|
+
y?: string | undefined;
|
141
|
+
x5c?: string[] | undefined;
|
142
|
+
x5t?: string | undefined;
|
143
|
+
"x5t#S256"?: string | undefined;
|
144
|
+
x5u?: string | undefined;
|
145
|
+
};
|
146
|
+
}, {
|
147
|
+
jwk: {
|
148
|
+
kty: "RSA" | "EC";
|
149
|
+
alg?: string | undefined;
|
150
|
+
crv?: string | undefined;
|
151
|
+
d?: string | undefined;
|
152
|
+
dp?: string | undefined;
|
153
|
+
dq?: string | undefined;
|
154
|
+
e?: string | undefined;
|
155
|
+
ext?: boolean | undefined;
|
156
|
+
k?: string | undefined;
|
157
|
+
key_ops?: string[] | undefined;
|
158
|
+
kid?: string | undefined;
|
159
|
+
n?: string | undefined;
|
160
|
+
p?: string | undefined;
|
161
|
+
q?: string | undefined;
|
162
|
+
qi?: string | undefined;
|
163
|
+
use?: string | undefined;
|
164
|
+
x?: string | undefined;
|
165
|
+
y?: string | undefined;
|
166
|
+
x5c?: string[] | undefined;
|
167
|
+
x5t?: string | undefined;
|
168
|
+
"x5t#S256"?: string | undefined;
|
169
|
+
x5u?: string | undefined;
|
170
|
+
};
|
171
|
+
}>;
|
172
|
+
exp: z.ZodNumber;
|
173
|
+
iat: z.ZodNumber;
|
174
|
+
}, "strip", z.ZodTypeAny, {
|
175
|
+
iss: string;
|
176
|
+
credential_hash_alg: string;
|
177
|
+
iat: number;
|
178
|
+
exp: number;
|
179
|
+
cnf: {
|
180
|
+
jwk: {
|
181
|
+
kty: "RSA" | "EC";
|
182
|
+
alg?: string | undefined;
|
183
|
+
crv?: string | undefined;
|
184
|
+
d?: string | undefined;
|
185
|
+
dp?: string | undefined;
|
186
|
+
dq?: string | undefined;
|
187
|
+
e?: string | undefined;
|
188
|
+
ext?: boolean | undefined;
|
189
|
+
k?: string | undefined;
|
190
|
+
key_ops?: string[] | undefined;
|
191
|
+
kid?: string | undefined;
|
192
|
+
n?: string | undefined;
|
193
|
+
p?: string | undefined;
|
194
|
+
q?: string | undefined;
|
195
|
+
qi?: string | undefined;
|
196
|
+
use?: string | undefined;
|
197
|
+
x?: string | undefined;
|
198
|
+
y?: string | undefined;
|
199
|
+
x5c?: string[] | undefined;
|
200
|
+
x5t?: string | undefined;
|
201
|
+
"x5t#S256"?: string | undefined;
|
202
|
+
x5u?: string | undefined;
|
203
|
+
};
|
204
|
+
};
|
205
|
+
credential_status_type: string;
|
206
|
+
credential_hash: string;
|
207
|
+
credential_status_detail?: {
|
208
|
+
state: string;
|
209
|
+
description: string;
|
210
|
+
} | undefined;
|
211
|
+
}, {
|
212
|
+
iss: string;
|
213
|
+
credential_hash_alg: string;
|
214
|
+
iat: number;
|
215
|
+
exp: number;
|
216
|
+
cnf: {
|
217
|
+
jwk: {
|
218
|
+
kty: "RSA" | "EC";
|
219
|
+
alg?: string | undefined;
|
220
|
+
crv?: string | undefined;
|
221
|
+
d?: string | undefined;
|
222
|
+
dp?: string | undefined;
|
223
|
+
dq?: string | undefined;
|
224
|
+
e?: string | undefined;
|
225
|
+
ext?: boolean | undefined;
|
226
|
+
k?: string | undefined;
|
227
|
+
key_ops?: string[] | undefined;
|
228
|
+
kid?: string | undefined;
|
229
|
+
n?: string | undefined;
|
230
|
+
p?: string | undefined;
|
231
|
+
q?: string | undefined;
|
232
|
+
qi?: string | undefined;
|
233
|
+
use?: string | undefined;
|
234
|
+
x?: string | undefined;
|
235
|
+
y?: string | undefined;
|
236
|
+
x5c?: string[] | undefined;
|
237
|
+
x5t?: string | undefined;
|
238
|
+
"x5t#S256"?: string | undefined;
|
239
|
+
x5u?: string | undefined;
|
240
|
+
};
|
241
|
+
};
|
242
|
+
credential_status_type: string;
|
243
|
+
credential_hash: string;
|
244
|
+
credential_status_detail?: {
|
245
|
+
state: string;
|
246
|
+
description: string;
|
247
|
+
} | undefined;
|
248
|
+
}>;
|
249
|
+
}, "strip", z.ZodTypeAny, {
|
250
|
+
header: {
|
251
|
+
alg: string;
|
252
|
+
typ: "status-assertion+jwt";
|
253
|
+
kid?: string | undefined;
|
254
|
+
};
|
255
|
+
payload: {
|
256
|
+
iss: string;
|
257
|
+
credential_hash_alg: string;
|
258
|
+
iat: number;
|
259
|
+
exp: number;
|
260
|
+
cnf: {
|
261
|
+
jwk: {
|
262
|
+
kty: "RSA" | "EC";
|
263
|
+
alg?: string | undefined;
|
264
|
+
crv?: string | undefined;
|
265
|
+
d?: string | undefined;
|
266
|
+
dp?: string | undefined;
|
267
|
+
dq?: string | undefined;
|
268
|
+
e?: string | undefined;
|
269
|
+
ext?: boolean | undefined;
|
270
|
+
k?: string | undefined;
|
271
|
+
key_ops?: string[] | undefined;
|
272
|
+
kid?: string | undefined;
|
273
|
+
n?: string | undefined;
|
274
|
+
p?: string | undefined;
|
275
|
+
q?: string | undefined;
|
276
|
+
qi?: string | undefined;
|
277
|
+
use?: string | undefined;
|
278
|
+
x?: string | undefined;
|
279
|
+
y?: string | undefined;
|
280
|
+
x5c?: string[] | undefined;
|
281
|
+
x5t?: string | undefined;
|
282
|
+
"x5t#S256"?: string | undefined;
|
283
|
+
x5u?: string | undefined;
|
284
|
+
};
|
285
|
+
};
|
286
|
+
credential_status_type: string;
|
287
|
+
credential_hash: string;
|
288
|
+
credential_status_detail?: {
|
289
|
+
state: string;
|
290
|
+
description: string;
|
291
|
+
} | undefined;
|
292
|
+
};
|
293
|
+
}, {
|
294
|
+
header: {
|
295
|
+
alg: string;
|
296
|
+
typ: "status-assertion+jwt";
|
297
|
+
kid?: string | undefined;
|
298
|
+
};
|
299
|
+
payload: {
|
300
|
+
iss: string;
|
301
|
+
credential_hash_alg: string;
|
302
|
+
iat: number;
|
303
|
+
exp: number;
|
304
|
+
cnf: {
|
305
|
+
jwk: {
|
306
|
+
kty: "RSA" | "EC";
|
307
|
+
alg?: string | undefined;
|
308
|
+
crv?: string | undefined;
|
309
|
+
d?: string | undefined;
|
310
|
+
dp?: string | undefined;
|
311
|
+
dq?: string | undefined;
|
312
|
+
e?: string | undefined;
|
313
|
+
ext?: boolean | undefined;
|
314
|
+
k?: string | undefined;
|
315
|
+
key_ops?: string[] | undefined;
|
316
|
+
kid?: string | undefined;
|
317
|
+
n?: string | undefined;
|
318
|
+
p?: string | undefined;
|
319
|
+
q?: string | undefined;
|
320
|
+
qi?: string | undefined;
|
321
|
+
use?: string | undefined;
|
322
|
+
x?: string | undefined;
|
323
|
+
y?: string | undefined;
|
324
|
+
x5c?: string[] | undefined;
|
325
|
+
x5t?: string | undefined;
|
326
|
+
"x5t#S256"?: string | undefined;
|
327
|
+
x5u?: string | undefined;
|
328
|
+
};
|
329
|
+
};
|
330
|
+
credential_status_type: string;
|
331
|
+
credential_hash: string;
|
332
|
+
credential_status_detail?: {
|
333
|
+
state: string;
|
334
|
+
description: string;
|
335
|
+
} | undefined;
|
336
|
+
};
|
337
|
+
}>;
|
338
|
+
export type ParsedStatusAssertionError = z.infer<typeof ParsedStatusAssertionError>;
|
21
339
|
/**
|
22
|
-
*
|
340
|
+
* The JWT that contains the errors occurred for the status assertion request.
|
341
|
+
* @see https://italia.github.io/eid-wallet-it-docs/versione-corrente/en/credential-revocation.html#http-status-assertion-response
|
23
342
|
*/
|
24
|
-
export declare const
|
343
|
+
export declare const ParsedStatusAssertionError: z.ZodObject<{
|
25
344
|
header: z.ZodObject<{
|
26
|
-
typ: z.ZodLiteral<"status-
|
345
|
+
typ: z.ZodLiteral<"status-assertion-error+jwt">;
|
27
346
|
alg: z.ZodString;
|
28
347
|
kid: z.ZodOptional<z.ZodString>;
|
29
348
|
}, "strip", z.ZodTypeAny, {
|
30
349
|
alg: string;
|
31
|
-
typ: "status-
|
350
|
+
typ: "status-assertion-error+jwt";
|
32
351
|
kid?: string | undefined;
|
33
352
|
}, {
|
34
353
|
alg: string;
|
35
|
-
typ: "status-
|
354
|
+
typ: "status-assertion-error+jwt";
|
36
355
|
kid?: string | undefined;
|
37
356
|
}>;
|
38
357
|
payload: z.ZodObject<{
|
358
|
+
credential_hash_alg: z.ZodString;
|
359
|
+
credential_hash: z.ZodString;
|
360
|
+
error: z.ZodString;
|
361
|
+
error_description: z.ZodString;
|
362
|
+
}, "strip", z.ZodTypeAny, {
|
363
|
+
error: string;
|
364
|
+
error_description: string;
|
365
|
+
credential_hash_alg: string;
|
366
|
+
credential_hash: string;
|
367
|
+
}, {
|
368
|
+
error: string;
|
369
|
+
error_description: string;
|
370
|
+
credential_hash_alg: string;
|
371
|
+
credential_hash: string;
|
372
|
+
}>;
|
373
|
+
}, "strip", z.ZodTypeAny, {
|
374
|
+
header: {
|
375
|
+
alg: string;
|
376
|
+
typ: "status-assertion-error+jwt";
|
377
|
+
kid?: string | undefined;
|
378
|
+
};
|
379
|
+
payload: {
|
380
|
+
error: string;
|
381
|
+
error_description: string;
|
382
|
+
credential_hash_alg: string;
|
383
|
+
credential_hash: string;
|
384
|
+
};
|
385
|
+
}, {
|
386
|
+
header: {
|
387
|
+
alg: string;
|
388
|
+
typ: "status-assertion-error+jwt";
|
389
|
+
kid?: string | undefined;
|
390
|
+
};
|
391
|
+
payload: {
|
392
|
+
error: string;
|
393
|
+
error_description: string;
|
394
|
+
credential_hash_alg: string;
|
395
|
+
credential_hash: string;
|
396
|
+
};
|
397
|
+
}>;
|
398
|
+
/**
|
399
|
+
* The status assertion response that might include either a successful assertion or an error
|
400
|
+
*/
|
401
|
+
export type ParsedStatusAssertionResponse = z.infer<typeof ParsedStatusAssertionResponse>;
|
402
|
+
export declare const ParsedStatusAssertionResponse: z.ZodUnion<[z.ZodObject<{
|
403
|
+
header: z.ZodObject<{
|
404
|
+
typ: z.ZodLiteral<"status-assertion+jwt">;
|
405
|
+
alg: z.ZodString;
|
406
|
+
kid: z.ZodOptional<z.ZodString>;
|
407
|
+
}, "strip", z.ZodTypeAny, {
|
408
|
+
alg: string;
|
409
|
+
typ: "status-assertion+jwt";
|
410
|
+
kid?: string | undefined;
|
411
|
+
}, {
|
412
|
+
alg: string;
|
413
|
+
typ: "status-assertion+jwt";
|
414
|
+
kid?: string | undefined;
|
415
|
+
}>;
|
416
|
+
payload: z.ZodObject<{
|
417
|
+
iss: z.ZodString;
|
418
|
+
credential_status_type: z.ZodString;
|
419
|
+
credential_status_detail: z.ZodOptional<z.ZodObject<{
|
420
|
+
state: z.ZodString;
|
421
|
+
description: z.ZodString;
|
422
|
+
}, "strip", z.ZodTypeAny, {
|
423
|
+
state: string;
|
424
|
+
description: string;
|
425
|
+
}, {
|
426
|
+
state: string;
|
427
|
+
description: string;
|
428
|
+
}>>;
|
39
429
|
credential_hash_alg: z.ZodString;
|
40
430
|
credential_hash: z.ZodString;
|
41
431
|
cnf: z.ZodObject<{
|
@@ -163,6 +553,7 @@ export declare const ParsedStatusAttestation: z.ZodObject<{
|
|
163
553
|
exp: z.ZodNumber;
|
164
554
|
iat: z.ZodNumber;
|
165
555
|
}, "strip", z.ZodTypeAny, {
|
556
|
+
iss: string;
|
166
557
|
credential_hash_alg: string;
|
167
558
|
iat: number;
|
168
559
|
exp: number;
|
@@ -192,8 +583,14 @@ export declare const ParsedStatusAttestation: z.ZodObject<{
|
|
192
583
|
x5u?: string | undefined;
|
193
584
|
};
|
194
585
|
};
|
586
|
+
credential_status_type: string;
|
195
587
|
credential_hash: string;
|
588
|
+
credential_status_detail?: {
|
589
|
+
state: string;
|
590
|
+
description: string;
|
591
|
+
} | undefined;
|
196
592
|
}, {
|
593
|
+
iss: string;
|
197
594
|
credential_hash_alg: string;
|
198
595
|
iat: number;
|
199
596
|
exp: number;
|
@@ -223,15 +620,21 @@ export declare const ParsedStatusAttestation: z.ZodObject<{
|
|
223
620
|
x5u?: string | undefined;
|
224
621
|
};
|
225
622
|
};
|
623
|
+
credential_status_type: string;
|
226
624
|
credential_hash: string;
|
625
|
+
credential_status_detail?: {
|
626
|
+
state: string;
|
627
|
+
description: string;
|
628
|
+
} | undefined;
|
227
629
|
}>;
|
228
630
|
}, "strip", z.ZodTypeAny, {
|
229
631
|
header: {
|
230
632
|
alg: string;
|
231
|
-
typ: "status-
|
633
|
+
typ: "status-assertion+jwt";
|
232
634
|
kid?: string | undefined;
|
233
635
|
};
|
234
636
|
payload: {
|
637
|
+
iss: string;
|
235
638
|
credential_hash_alg: string;
|
236
639
|
iat: number;
|
237
640
|
exp: number;
|
@@ -261,15 +664,21 @@ export declare const ParsedStatusAttestation: z.ZodObject<{
|
|
261
664
|
x5u?: string | undefined;
|
262
665
|
};
|
263
666
|
};
|
667
|
+
credential_status_type: string;
|
264
668
|
credential_hash: string;
|
669
|
+
credential_status_detail?: {
|
670
|
+
state: string;
|
671
|
+
description: string;
|
672
|
+
} | undefined;
|
265
673
|
};
|
266
674
|
}, {
|
267
675
|
header: {
|
268
676
|
alg: string;
|
269
|
-
typ: "status-
|
677
|
+
typ: "status-assertion+jwt";
|
270
678
|
kid?: string | undefined;
|
271
679
|
};
|
272
680
|
payload: {
|
681
|
+
iss: string;
|
273
682
|
credential_hash_alg: string;
|
274
683
|
iat: number;
|
275
684
|
exp: number;
|
@@ -299,7 +708,75 @@ export declare const ParsedStatusAttestation: z.ZodObject<{
|
|
299
708
|
x5u?: string | undefined;
|
300
709
|
};
|
301
710
|
};
|
711
|
+
credential_status_type: string;
|
302
712
|
credential_hash: string;
|
713
|
+
credential_status_detail?: {
|
714
|
+
state: string;
|
715
|
+
description: string;
|
716
|
+
} | undefined;
|
303
717
|
};
|
304
|
-
}
|
718
|
+
}>, z.ZodObject<{
|
719
|
+
header: z.ZodObject<{
|
720
|
+
typ: z.ZodLiteral<"status-assertion-error+jwt">;
|
721
|
+
alg: z.ZodString;
|
722
|
+
kid: z.ZodOptional<z.ZodString>;
|
723
|
+
}, "strip", z.ZodTypeAny, {
|
724
|
+
alg: string;
|
725
|
+
typ: "status-assertion-error+jwt";
|
726
|
+
kid?: string | undefined;
|
727
|
+
}, {
|
728
|
+
alg: string;
|
729
|
+
typ: "status-assertion-error+jwt";
|
730
|
+
kid?: string | undefined;
|
731
|
+
}>;
|
732
|
+
payload: z.ZodObject<{
|
733
|
+
credential_hash_alg: z.ZodString;
|
734
|
+
credential_hash: z.ZodString;
|
735
|
+
error: z.ZodString;
|
736
|
+
error_description: z.ZodString;
|
737
|
+
}, "strip", z.ZodTypeAny, {
|
738
|
+
error: string;
|
739
|
+
error_description: string;
|
740
|
+
credential_hash_alg: string;
|
741
|
+
credential_hash: string;
|
742
|
+
}, {
|
743
|
+
error: string;
|
744
|
+
error_description: string;
|
745
|
+
credential_hash_alg: string;
|
746
|
+
credential_hash: string;
|
747
|
+
}>;
|
748
|
+
}, "strip", z.ZodTypeAny, {
|
749
|
+
header: {
|
750
|
+
alg: string;
|
751
|
+
typ: "status-assertion-error+jwt";
|
752
|
+
kid?: string | undefined;
|
753
|
+
};
|
754
|
+
payload: {
|
755
|
+
error: string;
|
756
|
+
error_description: string;
|
757
|
+
credential_hash_alg: string;
|
758
|
+
credential_hash: string;
|
759
|
+
};
|
760
|
+
}, {
|
761
|
+
header: {
|
762
|
+
alg: string;
|
763
|
+
typ: "status-assertion-error+jwt";
|
764
|
+
kid?: string | undefined;
|
765
|
+
};
|
766
|
+
payload: {
|
767
|
+
error: string;
|
768
|
+
error_description: string;
|
769
|
+
credential_hash_alg: string;
|
770
|
+
credential_hash: string;
|
771
|
+
};
|
772
|
+
}>]>;
|
773
|
+
export declare enum StatusType {
|
774
|
+
VALID = "0x00",
|
775
|
+
INVALID = "0x01",
|
776
|
+
SUSPENDED = "0x02"
|
777
|
+
}
|
778
|
+
export type InvalidStatusErrorReason = {
|
779
|
+
error: string;
|
780
|
+
error_description: string;
|
781
|
+
};
|
305
782
|
//# sourceMappingURL=types.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/credential/status/types.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB;;GAEG;AACH,eAAO,MAAM,
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/credential/status/types.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB;;GAEG;AACH,eAAO,MAAM,uBAAuB;;;;;;EAElC,CAAC;AAEH;;;GAGG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAE9E,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAE1E;;GAEG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBhC,CAAC;AAEH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAC9C,OAAO,0BAA0B,CAClC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAYrC,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,KAAK,CACjD,OAAO,6BAA6B,CACrC,CAAC;AACF,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAGxC,CAAC;AAEH,oBAAY,UAAU;IACpB,KAAK,SAAS;IACd,OAAO,SAAS;IAChB,SAAS,SAAS;CACnB;AAED,MAAM,MAAM,wBAAwB,GAAG;IACrC,KAAK,EAAE,MAAM,CAAC;IACd,iBAAiB,EAAE,MAAM,CAAC;CAC3B,CAAC"}
|
@@ -275,7 +275,7 @@ export declare const getCredentialIssuerEntityConfiguration: (entityBaseUrl: Par
|
|
275
275
|
locale: string;
|
276
276
|
}[];
|
277
277
|
claims: {
|
278
|
-
path: string[];
|
278
|
+
path: (string | number | null)[];
|
279
279
|
display: {
|
280
280
|
name: string;
|
281
281
|
locale: string;
|
@@ -818,7 +818,7 @@ export declare const getEntityConfiguration: (entityBaseUrl: Parameters<typeof f
|
|
818
818
|
locale: string;
|
819
819
|
}[];
|
820
820
|
claims: {
|
821
|
-
path: string[];
|
821
|
+
path: (string | number | null)[];
|
822
822
|
display: {
|
823
823
|
name: string;
|
824
824
|
locale: string;
|