@pagopa/io-react-native-wallet 2.0.0-next.0 → 2.0.0-next.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.
Files changed (77) hide show
  1. package/lib/commonjs/credential/issuance/02-evaluate-issuer-trust.js +2 -2
  2. package/lib/commonjs/credential/issuance/02-evaluate-issuer-trust.js.map +1 -1
  3. package/lib/commonjs/credential/presentation/02-evaluate-rp-trust.js +2 -2
  4. package/lib/commonjs/credential/presentation/02-evaluate-rp-trust.js.map +1 -1
  5. package/lib/commonjs/credential/presentation/05-verify-request-object.js.map +1 -1
  6. package/lib/commonjs/credential/presentation/08-send-authorization-response.js.map +1 -1
  7. package/lib/commonjs/trust/README.md +147 -0
  8. package/lib/commonjs/trust/build-chain.js +252 -0
  9. package/lib/commonjs/trust/build-chain.js.map +1 -0
  10. package/lib/commonjs/trust/errors.js +24 -1
  11. package/lib/commonjs/trust/errors.js.map +1 -1
  12. package/lib/commonjs/trust/index.js +11 -276
  13. package/lib/commonjs/trust/index.js.map +1 -1
  14. package/lib/commonjs/trust/utils.js +30 -1
  15. package/lib/commonjs/trust/utils.js.map +1 -1
  16. package/lib/commonjs/trust/{chain.js → verify-chain.js} +87 -15
  17. package/lib/commonjs/trust/verify-chain.js.map +1 -0
  18. package/lib/commonjs/utils/errors.js.map +1 -1
  19. package/lib/module/credential/issuance/02-evaluate-issuer-trust.js +1 -1
  20. package/lib/module/credential/issuance/02-evaluate-issuer-trust.js.map +1 -1
  21. package/lib/module/credential/presentation/02-evaluate-rp-trust.js +1 -1
  22. package/lib/module/credential/presentation/02-evaluate-rp-trust.js.map +1 -1
  23. package/lib/module/credential/presentation/05-verify-request-object.js.map +1 -1
  24. package/lib/module/credential/presentation/08-send-authorization-response.js +1 -1
  25. package/lib/module/credential/presentation/08-send-authorization-response.js.map +1 -1
  26. package/lib/module/trust/README.md +147 -0
  27. package/lib/module/trust/build-chain.js +235 -0
  28. package/lib/module/trust/build-chain.js.map +1 -0
  29. package/lib/module/trust/errors.js +23 -2
  30. package/lib/module/trust/errors.js.map +1 -1
  31. package/lib/module/trust/index.js +5 -262
  32. package/lib/module/trust/index.js.map +1 -1
  33. package/lib/module/trust/utils.js +27 -0
  34. package/lib/module/trust/utils.js.map +1 -1
  35. package/lib/module/trust/{chain.js → verify-chain.js} +85 -14
  36. package/lib/module/trust/verify-chain.js.map +1 -0
  37. package/lib/module/utils/errors.js +1 -1
  38. package/lib/module/utils/errors.js.map +1 -1
  39. package/lib/typescript/credential/issuance/02-evaluate-issuer-trust.d.ts.map +1 -1
  40. package/lib/typescript/credential/presentation/02-evaluate-rp-trust.d.ts.map +1 -1
  41. package/lib/typescript/credential/presentation/05-verify-request-object.d.ts +1 -1
  42. package/lib/typescript/credential/presentation/05-verify-request-object.d.ts.map +1 -1
  43. package/lib/typescript/credential/presentation/08-send-authorization-response.d.ts +2 -2
  44. package/lib/typescript/credential/presentation/08-send-authorization-response.d.ts.map +1 -1
  45. package/lib/typescript/credential/status/types.d.ts +6 -6
  46. package/lib/typescript/sd-jwt/index.d.ts +12 -12
  47. package/lib/typescript/sd-jwt/types.d.ts +6 -6
  48. package/lib/typescript/trust/build-chain.d.ts +1284 -0
  49. package/lib/typescript/trust/build-chain.d.ts.map +1 -0
  50. package/lib/typescript/trust/errors.d.ts +22 -0
  51. package/lib/typescript/trust/errors.d.ts.map +1 -1
  52. package/lib/typescript/trust/index.d.ts +5 -1299
  53. package/lib/typescript/trust/index.d.ts.map +1 -1
  54. package/lib/typescript/trust/types.d.ts +54 -54
  55. package/lib/typescript/trust/utils.d.ts +10 -0
  56. package/lib/typescript/trust/utils.d.ts.map +1 -1
  57. package/lib/typescript/trust/verify-chain.d.ts +39 -0
  58. package/lib/typescript/trust/verify-chain.d.ts.map +1 -0
  59. package/lib/typescript/utils/errors.d.ts +2 -2
  60. package/lib/typescript/utils/errors.d.ts.map +1 -1
  61. package/lib/typescript/wallet-instance-attestation/types.d.ts +21 -21
  62. package/package.json +2 -2
  63. package/src/credential/issuance/02-evaluate-issuer-trust.ts +1 -1
  64. package/src/credential/presentation/02-evaluate-rp-trust.ts +1 -1
  65. package/src/credential/presentation/05-verify-request-object.ts +1 -1
  66. package/src/credential/presentation/08-send-authorization-response.ts +4 -4
  67. package/src/trust/README.md +147 -0
  68. package/src/trust/build-chain.ts +395 -0
  69. package/src/trust/errors.ts +32 -1
  70. package/src/trust/index.ts +5 -435
  71. package/src/trust/utils.ts +35 -0
  72. package/src/trust/{chain.ts → verify-chain.ts} +132 -16
  73. package/src/utils/errors.ts +4 -4
  74. package/lib/commonjs/trust/chain.js.map +0 -1
  75. package/lib/module/trust/chain.js.map +0 -1
  76. package/lib/typescript/trust/chain.d.ts +0 -21
  77. package/lib/typescript/trust/chain.d.ts.map +0 -1
@@ -1,1300 +1,6 @@
1
- import { CredentialIssuerEntityConfiguration, EntityConfiguration, EntityStatement, RelyingPartyEntityConfiguration, TrustAnchorEntityConfiguration, WalletProviderEntityConfiguration } from "./types";
2
- import { validateTrustChain } from "./chain";
3
- import type { JWK } from "../utils/jwk";
4
- export type { WalletProviderEntityConfiguration, TrustAnchorEntityConfiguration, CredentialIssuerEntityConfiguration, RelyingPartyEntityConfiguration, EntityConfiguration, EntityStatement, };
5
- /**
6
- * Verify a given trust chain is actually valid.
7
- * It can handle fast chain renewal, which means we try to fetch a fresh version of each statement.
8
- *
9
- * @param trustAnchorEntity The entity configuration of the known trust anchor
10
- * @param chain The chain of statements to be validated
11
- * @param renewOnFail Whether to renew the provided chain if the validation fails at first. Default: true
12
- * @param appFetch Fetch api implementation. Default: the built-in implementation
13
- * @returns The result of the chain validation
14
- * @throws {FederationError} If the chain is not valid
15
- */
16
- export declare function verifyTrustChain(trustAnchorEntity: TrustAnchorEntityConfiguration, chain: string[], { appFetch, renewOnFail, }?: {
17
- appFetch?: GlobalFetch["fetch"];
18
- renewOnFail?: boolean;
19
- }): Promise<ReturnType<typeof validateTrustChain>>;
20
- /**
21
- * Fetch the signed entity configuration token for an entity
22
- *
23
- * @param entityBaseUrl The url of the entity to fetch
24
- * @param appFetch (optional) fetch api implementation
25
- * @returns The signed Entity Configuration token
26
- */
27
- export declare function getSignedEntityConfiguration(entityBaseUrl: string, { appFetch, }?: {
28
- appFetch?: GlobalFetch["fetch"];
29
- }): Promise<string>;
30
- /**
31
- * Fetch and parse the entity configuration document for a given federation entity.
32
- * This is an inner method to serve public interfaces.
33
- *
34
- * To add another entity configuration type (example: Foo entity type):
35
- * - create its zod schema and type by inherit from the base type (example: FooEntityConfiguration = BaseEntityConfiguration.and(...))
36
- * - add such type to EntityConfiguration union
37
- * - add an overload to this function
38
- * - create a public function which use such type (example: getFooEntityConfiguration = (url, options) => Promise<FooEntityConfiguration>)
39
- *
40
- * @param entityBaseUrl The base url of the entity.
41
- * @param schema The expected schema of the entity configuration, according to the kind of entity we are fetching from.
42
- * @param options An optional object with additional options.
43
- * @param options.appFetch An optional instance of the http client to be used.
44
- * @returns The parsed entity configuration object
45
- * @throws {IoWalletError} If the http request fails
46
- * @throws Parse error if the document is not in the expected shape.
47
- */
48
- declare function fetchAndParseEntityConfiguration(entityBaseUrl: string, schema: typeof WalletProviderEntityConfiguration, options?: {
49
- appFetch?: GlobalFetch["fetch"];
50
- }): Promise<WalletProviderEntityConfiguration>;
51
- declare function fetchAndParseEntityConfiguration(entityBaseUrl: string, schema: typeof RelyingPartyEntityConfiguration, options?: {
52
- appFetch?: GlobalFetch["fetch"];
53
- }): Promise<RelyingPartyEntityConfiguration>;
54
- declare function fetchAndParseEntityConfiguration(entityBaseUrl: string, schema: typeof TrustAnchorEntityConfiguration, options?: {
55
- appFetch?: GlobalFetch["fetch"];
56
- }): Promise<TrustAnchorEntityConfiguration>;
57
- declare function fetchAndParseEntityConfiguration(entityBaseUrl: string, schema: typeof CredentialIssuerEntityConfiguration, options?: {
58
- appFetch?: GlobalFetch["fetch"];
59
- }): Promise<CredentialIssuerEntityConfiguration>;
60
- declare function fetchAndParseEntityConfiguration(entityBaseUrl: string, schema: typeof EntityConfiguration, options?: {
61
- appFetch?: GlobalFetch["fetch"];
62
- }): Promise<EntityConfiguration>;
63
- export declare const getWalletProviderEntityConfiguration: (entityBaseUrl: Parameters<typeof fetchAndParseEntityConfiguration>[0], options?: Parameters<typeof fetchAndParseEntityConfiguration>[2]) => Promise<{
64
- payload: {
65
- iss: string;
66
- sub: string;
67
- iat: number;
68
- exp: number;
69
- jwks: {
70
- keys: {
71
- kty: "RSA" | "EC";
72
- alg?: string | undefined;
73
- crv?: string | undefined;
74
- d?: string | undefined;
75
- dp?: string | undefined;
76
- dq?: string | undefined;
77
- e?: string | undefined;
78
- ext?: boolean | undefined;
79
- k?: string | undefined;
80
- key_ops?: string[] | undefined;
81
- kid?: string | undefined;
82
- n?: string | undefined;
83
- p?: string | undefined;
84
- q?: string | undefined;
85
- qi?: string | undefined;
86
- use?: string | undefined;
87
- x?: string | undefined;
88
- y?: string | undefined;
89
- x5c?: string[] | undefined;
90
- x5t?: string | undefined;
91
- "x5t#S256"?: string | undefined;
92
- x5u?: string | undefined;
93
- }[];
94
- };
95
- metadata: {
96
- federation_entity: {
97
- federation_fetch_endpoint?: string | undefined;
98
- federation_list_endpoint?: string | undefined;
99
- federation_resolve_endpoint?: string | undefined;
100
- federation_trust_mark_status_endpoint?: string | undefined;
101
- federation_trust_mark_list_endpoint?: string | undefined;
102
- federation_trust_mark_endpoint?: string | undefined;
103
- federation_historical_keys_endpoint?: string | undefined;
104
- endpoint_auth_signing_alg_values_supported?: string | undefined;
105
- organization_name?: string | undefined;
106
- homepage_uri?: string | undefined;
107
- policy_uri?: string | undefined;
108
- logo_uri?: string | undefined;
109
- contacts?: string[] | undefined;
110
- } & {
111
- [k: string]: unknown;
112
- };
113
- } & {
114
- [k: string]: unknown;
115
- };
116
- authority_hints?: string[] | undefined;
117
- } & {
118
- [k: string]: unknown;
119
- };
120
- header: {
121
- alg: string;
122
- kid: string;
123
- typ: "entity-statement+jwt";
124
- };
125
- } & {
126
- payload: {
127
- metadata: {
128
- wallet_provider: {
129
- jwks: {
130
- keys: {
131
- kty: "RSA" | "EC";
132
- alg?: string | undefined;
133
- crv?: string | undefined;
134
- d?: string | undefined;
135
- dp?: string | undefined;
136
- dq?: string | undefined;
137
- e?: string | undefined;
138
- ext?: boolean | undefined;
139
- k?: string | undefined;
140
- key_ops?: string[] | undefined;
141
- kid?: string | undefined;
142
- n?: string | undefined;
143
- p?: string | undefined;
144
- q?: string | undefined;
145
- qi?: string | undefined;
146
- use?: string | undefined;
147
- x?: string | undefined;
148
- y?: string | undefined;
149
- x5c?: string[] | undefined;
150
- x5t?: string | undefined;
151
- "x5t#S256"?: string | undefined;
152
- x5u?: string | undefined;
153
- }[];
154
- };
155
- token_endpoint: string;
156
- grant_types_supported: string[];
157
- token_endpoint_auth_methods_supported: string[];
158
- token_endpoint_auth_signing_alg_values_supported: string[];
159
- aal_values_supported?: string[] | undefined;
160
- } & {
161
- [k: string]: unknown;
162
- };
163
- };
164
- };
165
- }>;
166
- export declare const getCredentialIssuerEntityConfiguration: (entityBaseUrl: Parameters<typeof fetchAndParseEntityConfiguration>[0], options?: Parameters<typeof fetchAndParseEntityConfiguration>[2]) => Promise<{
167
- payload: {
168
- iss: string;
169
- sub: string;
170
- iat: number;
171
- exp: number;
172
- jwks: {
173
- keys: {
174
- kty: "RSA" | "EC";
175
- alg?: string | undefined;
176
- crv?: string | undefined;
177
- d?: string | undefined;
178
- dp?: string | undefined;
179
- dq?: string | undefined;
180
- e?: string | undefined;
181
- ext?: boolean | undefined;
182
- k?: string | undefined;
183
- key_ops?: string[] | undefined;
184
- kid?: string | undefined;
185
- n?: string | undefined;
186
- p?: string | undefined;
187
- q?: string | undefined;
188
- qi?: string | undefined;
189
- use?: string | undefined;
190
- x?: string | undefined;
191
- y?: string | undefined;
192
- x5c?: string[] | undefined;
193
- x5t?: string | undefined;
194
- "x5t#S256"?: string | undefined;
195
- x5u?: string | undefined;
196
- }[];
197
- };
198
- metadata: {
199
- federation_entity: {
200
- federation_fetch_endpoint?: string | undefined;
201
- federation_list_endpoint?: string | undefined;
202
- federation_resolve_endpoint?: string | undefined;
203
- federation_trust_mark_status_endpoint?: string | undefined;
204
- federation_trust_mark_list_endpoint?: string | undefined;
205
- federation_trust_mark_endpoint?: string | undefined;
206
- federation_historical_keys_endpoint?: string | undefined;
207
- endpoint_auth_signing_alg_values_supported?: string | undefined;
208
- organization_name?: string | undefined;
209
- homepage_uri?: string | undefined;
210
- policy_uri?: string | undefined;
211
- logo_uri?: string | undefined;
212
- contacts?: string[] | undefined;
213
- } & {
214
- [k: string]: unknown;
215
- };
216
- } & {
217
- [k: string]: unknown;
218
- };
219
- authority_hints?: string[] | undefined;
220
- } & {
221
- [k: string]: unknown;
222
- };
223
- header: {
224
- alg: string;
225
- kid: string;
226
- typ: "entity-statement+jwt";
227
- };
228
- } & {
229
- payload: {
230
- jwks: {
231
- keys: {
232
- kty: "RSA" | "EC";
233
- alg?: string | undefined;
234
- crv?: string | undefined;
235
- d?: string | undefined;
236
- dp?: string | undefined;
237
- dq?: string | undefined;
238
- e?: string | undefined;
239
- ext?: boolean | undefined;
240
- k?: string | undefined;
241
- key_ops?: string[] | undefined;
242
- kid?: string | undefined;
243
- n?: string | undefined;
244
- p?: string | undefined;
245
- q?: string | undefined;
246
- qi?: string | undefined;
247
- use?: string | undefined;
248
- x?: string | undefined;
249
- y?: string | undefined;
250
- x5c?: string[] | undefined;
251
- x5t?: string | undefined;
252
- "x5t#S256"?: string | undefined;
253
- x5u?: string | undefined;
254
- }[];
255
- };
256
- metadata: {
257
- openid_credential_issuer: {
258
- jwks: {
259
- keys: {
260
- kty: "RSA" | "EC";
261
- alg?: string | undefined;
262
- crv?: string | undefined;
263
- d?: string | undefined;
264
- dp?: string | undefined;
265
- dq?: string | undefined;
266
- e?: string | undefined;
267
- ext?: boolean | undefined;
268
- k?: string | undefined;
269
- key_ops?: string[] | undefined;
270
- kid?: string | undefined;
271
- n?: string | undefined;
272
- p?: string | undefined;
273
- q?: string | undefined;
274
- qi?: string | undefined;
275
- use?: string | undefined;
276
- x?: string | undefined;
277
- y?: string | undefined;
278
- x5c?: string[] | undefined;
279
- x5t?: string | undefined;
280
- "x5t#S256"?: string | undefined;
281
- x5u?: string | undefined;
282
- }[];
283
- };
284
- display: {
285
- name: string;
286
- locale: string;
287
- }[];
288
- credential_issuer: string;
289
- credential_endpoint: string;
290
- revocation_endpoint: string;
291
- status_attestation_endpoint: string;
292
- credential_configurations_supported: Record<string, {
293
- format: "vc+sd-jwt" | "vc+mdoc-cbor";
294
- scope: string;
295
- display: {
296
- name: string;
297
- locale: string;
298
- }[];
299
- claims: Record<string, {
300
- value_type: string;
301
- display: {
302
- name: string;
303
- locale: string;
304
- }[];
305
- }>;
306
- cryptographic_binding_methods_supported: string[];
307
- credential_signing_alg_values_supported: string[];
308
- authentic_source?: string | undefined;
309
- issuance_errors_supported?: Record<string, {
310
- display: {
311
- locale: string;
312
- title: string;
313
- description: string;
314
- }[];
315
- }> | undefined;
316
- }>;
317
- };
318
- oauth_authorization_server: {
319
- request_object_signing_alg_values_supported: string[];
320
- jwks: {
321
- keys: {
322
- kty: "RSA" | "EC";
323
- alg?: string | undefined;
324
- crv?: string | undefined;
325
- d?: string | undefined;
326
- dp?: string | undefined;
327
- dq?: string | undefined;
328
- e?: string | undefined;
329
- ext?: boolean | undefined;
330
- k?: string | undefined;
331
- key_ops?: string[] | undefined;
332
- kid?: string | undefined;
333
- n?: string | undefined;
334
- p?: string | undefined;
335
- q?: string | undefined;
336
- qi?: string | undefined;
337
- use?: string | undefined;
338
- x?: string | undefined;
339
- y?: string | undefined;
340
- x5c?: string[] | undefined;
341
- x5t?: string | undefined;
342
- "x5t#S256"?: string | undefined;
343
- x5u?: string | undefined;
344
- }[];
345
- };
346
- authorization_endpoint: string;
347
- pushed_authorization_request_endpoint: string;
348
- token_endpoint: string;
349
- client_registration_types_supported: string[];
350
- code_challenge_methods_supported: string[];
351
- acr_values_supported: string[];
352
- grant_types_supported: string[];
353
- issuer: string;
354
- scopes_supported: string[];
355
- response_modes_supported: string[];
356
- token_endpoint_auth_methods_supported: string[];
357
- token_endpoint_auth_signing_alg_values_supported: string[];
358
- };
359
- openid_credential_verifier?: {
360
- jwks: {
361
- keys: {
362
- kty: "RSA" | "EC";
363
- alg?: string | undefined;
364
- crv?: string | undefined;
365
- d?: string | undefined;
366
- dp?: string | undefined;
367
- dq?: string | undefined;
368
- e?: string | undefined;
369
- ext?: boolean | undefined;
370
- k?: string | undefined;
371
- key_ops?: string[] | undefined;
372
- kid?: string | undefined;
373
- n?: string | undefined;
374
- p?: string | undefined;
375
- q?: string | undefined;
376
- qi?: string | undefined;
377
- use?: string | undefined;
378
- x?: string | undefined;
379
- y?: string | undefined;
380
- x5c?: string[] | undefined;
381
- x5t?: string | undefined;
382
- "x5t#S256"?: string | undefined;
383
- x5u?: string | undefined;
384
- }[];
385
- };
386
- application_type?: string | undefined;
387
- client_id?: string | undefined;
388
- client_name?: string | undefined;
389
- contacts?: string[] | undefined;
390
- presentation_definition?: {
391
- id: string;
392
- input_descriptors: {
393
- id: string;
394
- constraints: {
395
- fields?: {
396
- path: string[];
397
- id?: string | undefined;
398
- purpose?: string | undefined;
399
- name?: string | undefined;
400
- filter?: any;
401
- optional?: boolean | undefined;
402
- intent_to_retain?: boolean | undefined;
403
- }[] | undefined;
404
- limit_disclosure?: "required" | "preferred" | undefined;
405
- };
406
- name?: string | undefined;
407
- purpose?: string | undefined;
408
- format?: Record<string, any> | undefined;
409
- group?: string | undefined;
410
- }[];
411
- name?: string | undefined;
412
- purpose?: string | undefined;
413
- submission_requirements?: {
414
- rule: string;
415
- name?: string | undefined;
416
- purpose?: string | undefined;
417
- from?: string | undefined;
418
- from_nested?: {
419
- rule: string;
420
- from: string;
421
- name?: string | undefined;
422
- purpose?: string | undefined;
423
- }[] | undefined;
424
- count?: number | undefined;
425
- }[] | undefined;
426
- } | undefined;
427
- request_uris?: string[] | undefined;
428
- authorization_signed_response_alg?: string | undefined;
429
- authorization_encrypted_response_alg?: string | undefined;
430
- authorization_encrypted_response_enc?: string | undefined;
431
- } | undefined;
432
- };
433
- };
434
- }>;
435
- export declare const getTrustAnchorEntityConfiguration: (entityBaseUrl: Parameters<typeof fetchAndParseEntityConfiguration>[0], options?: Parameters<typeof fetchAndParseEntityConfiguration>[2]) => Promise<{
436
- payload: {
437
- iss: string;
438
- sub: string;
439
- iat: number;
440
- exp: number;
441
- jwks: {
442
- keys: {
443
- kty: "RSA" | "EC";
444
- alg?: string | undefined;
445
- crv?: string | undefined;
446
- d?: string | undefined;
447
- dp?: string | undefined;
448
- dq?: string | undefined;
449
- e?: string | undefined;
450
- ext?: boolean | undefined;
451
- k?: string | undefined;
452
- key_ops?: string[] | undefined;
453
- kid?: string | undefined;
454
- n?: string | undefined;
455
- p?: string | undefined;
456
- q?: string | undefined;
457
- qi?: string | undefined;
458
- use?: string | undefined;
459
- x?: string | undefined;
460
- y?: string | undefined;
461
- x5c?: string[] | undefined;
462
- x5t?: string | undefined;
463
- "x5t#S256"?: string | undefined;
464
- x5u?: string | undefined;
465
- }[];
466
- };
467
- metadata: {
468
- federation_entity: {
469
- federation_fetch_endpoint?: string | undefined;
470
- federation_list_endpoint?: string | undefined;
471
- federation_resolve_endpoint?: string | undefined;
472
- federation_trust_mark_status_endpoint?: string | undefined;
473
- federation_trust_mark_list_endpoint?: string | undefined;
474
- federation_trust_mark_endpoint?: string | undefined;
475
- federation_historical_keys_endpoint?: string | undefined;
476
- endpoint_auth_signing_alg_values_supported?: string | undefined;
477
- organization_name?: string | undefined;
478
- homepage_uri?: string | undefined;
479
- policy_uri?: string | undefined;
480
- logo_uri?: string | undefined;
481
- contacts?: string[] | undefined;
482
- } & {
483
- [k: string]: unknown;
484
- };
485
- } & {
486
- [k: string]: unknown;
487
- };
488
- authority_hints?: string[] | undefined;
489
- } & {
490
- [k: string]: unknown;
491
- };
492
- header: {
493
- alg: string;
494
- kid: string;
495
- typ: "entity-statement+jwt";
496
- };
497
- }>;
498
- export declare const getRelyingPartyEntityConfiguration: (entityBaseUrl: Parameters<typeof fetchAndParseEntityConfiguration>[0], options?: Parameters<typeof fetchAndParseEntityConfiguration>[2]) => Promise<{
499
- payload: {
500
- iss: string;
501
- sub: string;
502
- iat: number;
503
- exp: number;
504
- jwks: {
505
- keys: {
506
- kty: "RSA" | "EC";
507
- alg?: string | undefined;
508
- crv?: string | undefined;
509
- d?: string | undefined;
510
- dp?: string | undefined;
511
- dq?: string | undefined;
512
- e?: string | undefined;
513
- ext?: boolean | undefined;
514
- k?: string | undefined;
515
- key_ops?: string[] | undefined;
516
- kid?: string | undefined;
517
- n?: string | undefined;
518
- p?: string | undefined;
519
- q?: string | undefined;
520
- qi?: string | undefined;
521
- use?: string | undefined;
522
- x?: string | undefined;
523
- y?: string | undefined;
524
- x5c?: string[] | undefined;
525
- x5t?: string | undefined;
526
- "x5t#S256"?: string | undefined;
527
- x5u?: string | undefined;
528
- }[];
529
- };
530
- metadata: {
531
- federation_entity: {
532
- federation_fetch_endpoint?: string | undefined;
533
- federation_list_endpoint?: string | undefined;
534
- federation_resolve_endpoint?: string | undefined;
535
- federation_trust_mark_status_endpoint?: string | undefined;
536
- federation_trust_mark_list_endpoint?: string | undefined;
537
- federation_trust_mark_endpoint?: string | undefined;
538
- federation_historical_keys_endpoint?: string | undefined;
539
- endpoint_auth_signing_alg_values_supported?: string | undefined;
540
- organization_name?: string | undefined;
541
- homepage_uri?: string | undefined;
542
- policy_uri?: string | undefined;
543
- logo_uri?: string | undefined;
544
- contacts?: string[] | undefined;
545
- } & {
546
- [k: string]: unknown;
547
- };
548
- } & {
549
- [k: string]: unknown;
550
- };
551
- authority_hints?: string[] | undefined;
552
- } & {
553
- [k: string]: unknown;
554
- };
555
- header: {
556
- alg: string;
557
- kid: string;
558
- typ: "entity-statement+jwt";
559
- };
560
- } & {
561
- payload: {
562
- metadata: {
563
- openid_credential_verifier: {
564
- jwks: {
565
- keys: {
566
- kty: "RSA" | "EC";
567
- alg?: string | undefined;
568
- crv?: string | undefined;
569
- d?: string | undefined;
570
- dp?: string | undefined;
571
- dq?: string | undefined;
572
- e?: string | undefined;
573
- ext?: boolean | undefined;
574
- k?: string | undefined;
575
- key_ops?: string[] | undefined;
576
- kid?: string | undefined;
577
- n?: string | undefined;
578
- p?: string | undefined;
579
- q?: string | undefined;
580
- qi?: string | undefined;
581
- use?: string | undefined;
582
- x?: string | undefined;
583
- y?: string | undefined;
584
- x5c?: string[] | undefined;
585
- x5t?: string | undefined;
586
- "x5t#S256"?: string | undefined;
587
- x5u?: string | undefined;
588
- }[];
589
- };
590
- application_type?: string | undefined;
591
- client_id?: string | undefined;
592
- client_name?: string | undefined;
593
- contacts?: string[] | undefined;
594
- presentation_definition?: {
595
- id: string;
596
- input_descriptors: {
597
- id: string;
598
- constraints: {
599
- fields?: {
600
- path: string[];
601
- id?: string | undefined;
602
- purpose?: string | undefined;
603
- name?: string | undefined;
604
- filter?: any;
605
- optional?: boolean | undefined;
606
- intent_to_retain?: boolean | undefined;
607
- }[] | undefined;
608
- limit_disclosure?: "required" | "preferred" | undefined;
609
- };
610
- name?: string | undefined;
611
- purpose?: string | undefined;
612
- format?: Record<string, any> | undefined;
613
- group?: string | undefined;
614
- }[];
615
- name?: string | undefined;
616
- purpose?: string | undefined;
617
- submission_requirements?: {
618
- rule: string;
619
- name?: string | undefined;
620
- purpose?: string | undefined;
621
- from?: string | undefined;
622
- from_nested?: {
623
- rule: string;
624
- from: string;
625
- name?: string | undefined;
626
- purpose?: string | undefined;
627
- }[] | undefined;
628
- count?: number | undefined;
629
- }[] | undefined;
630
- } | undefined;
631
- request_uris?: string[] | undefined;
632
- authorization_signed_response_alg?: string | undefined;
633
- authorization_encrypted_response_alg?: string | undefined;
634
- authorization_encrypted_response_enc?: string | undefined;
635
- };
636
- };
637
- };
638
- }>;
639
- export declare const getEntityConfiguration: (entityBaseUrl: Parameters<typeof fetchAndParseEntityConfiguration>[0], options?: Parameters<typeof fetchAndParseEntityConfiguration>[2]) => Promise<{
640
- payload: {
641
- iss: string;
642
- sub: string;
643
- iat: number;
644
- exp: number;
645
- jwks: {
646
- keys: {
647
- kty: "RSA" | "EC";
648
- alg?: string | undefined;
649
- crv?: string | undefined;
650
- d?: string | undefined;
651
- dp?: string | undefined;
652
- dq?: string | undefined;
653
- e?: string | undefined;
654
- ext?: boolean | undefined;
655
- k?: string | undefined;
656
- key_ops?: string[] | undefined;
657
- kid?: string | undefined;
658
- n?: string | undefined;
659
- p?: string | undefined;
660
- q?: string | undefined;
661
- qi?: string | undefined;
662
- use?: string | undefined;
663
- x?: string | undefined;
664
- y?: string | undefined;
665
- x5c?: string[] | undefined;
666
- x5t?: string | undefined;
667
- "x5t#S256"?: string | undefined;
668
- x5u?: string | undefined;
669
- }[];
670
- };
671
- metadata: {
672
- federation_entity: {
673
- federation_fetch_endpoint?: string | undefined;
674
- federation_list_endpoint?: string | undefined;
675
- federation_resolve_endpoint?: string | undefined;
676
- federation_trust_mark_status_endpoint?: string | undefined;
677
- federation_trust_mark_list_endpoint?: string | undefined;
678
- federation_trust_mark_endpoint?: string | undefined;
679
- federation_historical_keys_endpoint?: string | undefined;
680
- endpoint_auth_signing_alg_values_supported?: string | undefined;
681
- organization_name?: string | undefined;
682
- homepage_uri?: string | undefined;
683
- policy_uri?: string | undefined;
684
- logo_uri?: string | undefined;
685
- contacts?: string[] | undefined;
686
- } & {
687
- [k: string]: unknown;
688
- };
689
- } & {
690
- [k: string]: unknown;
691
- };
692
- authority_hints?: string[] | undefined;
693
- } & {
694
- [k: string]: unknown;
695
- };
696
- header: {
697
- alg: string;
698
- kid: string;
699
- typ: "entity-statement+jwt";
700
- };
701
- } | ({
702
- payload: {
703
- iss: string;
704
- sub: string;
705
- iat: number;
706
- exp: number;
707
- jwks: {
708
- keys: {
709
- kty: "RSA" | "EC";
710
- alg?: string | undefined;
711
- crv?: string | undefined;
712
- d?: string | undefined;
713
- dp?: string | undefined;
714
- dq?: string | undefined;
715
- e?: string | undefined;
716
- ext?: boolean | undefined;
717
- k?: string | undefined;
718
- key_ops?: string[] | undefined;
719
- kid?: string | undefined;
720
- n?: string | undefined;
721
- p?: string | undefined;
722
- q?: string | undefined;
723
- qi?: string | undefined;
724
- use?: string | undefined;
725
- x?: string | undefined;
726
- y?: string | undefined;
727
- x5c?: string[] | undefined;
728
- x5t?: string | undefined;
729
- "x5t#S256"?: string | undefined;
730
- x5u?: string | undefined;
731
- }[];
732
- };
733
- metadata: {
734
- federation_entity: {
735
- federation_fetch_endpoint?: string | undefined;
736
- federation_list_endpoint?: string | undefined;
737
- federation_resolve_endpoint?: string | undefined;
738
- federation_trust_mark_status_endpoint?: string | undefined;
739
- federation_trust_mark_list_endpoint?: string | undefined;
740
- federation_trust_mark_endpoint?: string | undefined;
741
- federation_historical_keys_endpoint?: string | undefined;
742
- endpoint_auth_signing_alg_values_supported?: string | undefined;
743
- organization_name?: string | undefined;
744
- homepage_uri?: string | undefined;
745
- policy_uri?: string | undefined;
746
- logo_uri?: string | undefined;
747
- contacts?: string[] | undefined;
748
- } & {
749
- [k: string]: unknown;
750
- };
751
- } & {
752
- [k: string]: unknown;
753
- };
754
- authority_hints?: string[] | undefined;
755
- } & {
756
- [k: string]: unknown;
757
- };
758
- header: {
759
- alg: string;
760
- kid: string;
761
- typ: "entity-statement+jwt";
762
- };
763
- } & {
764
- payload: {
765
- jwks: {
766
- keys: {
767
- kty: "RSA" | "EC";
768
- alg?: string | undefined;
769
- crv?: string | undefined;
770
- d?: string | undefined;
771
- dp?: string | undefined;
772
- dq?: string | undefined;
773
- e?: string | undefined;
774
- ext?: boolean | undefined;
775
- k?: string | undefined;
776
- key_ops?: string[] | undefined;
777
- kid?: string | undefined;
778
- n?: string | undefined;
779
- p?: string | undefined;
780
- q?: string | undefined;
781
- qi?: string | undefined;
782
- use?: string | undefined;
783
- x?: string | undefined;
784
- y?: string | undefined;
785
- x5c?: string[] | undefined;
786
- x5t?: string | undefined;
787
- "x5t#S256"?: string | undefined;
788
- x5u?: string | undefined;
789
- }[];
790
- };
791
- metadata: {
792
- openid_credential_issuer: {
793
- jwks: {
794
- keys: {
795
- kty: "RSA" | "EC";
796
- alg?: string | undefined;
797
- crv?: string | undefined;
798
- d?: string | undefined;
799
- dp?: string | undefined;
800
- dq?: string | undefined;
801
- e?: string | undefined;
802
- ext?: boolean | undefined;
803
- k?: string | undefined;
804
- key_ops?: string[] | undefined;
805
- kid?: string | undefined;
806
- n?: string | undefined;
807
- p?: string | undefined;
808
- q?: string | undefined;
809
- qi?: string | undefined;
810
- use?: string | undefined;
811
- x?: string | undefined;
812
- y?: string | undefined;
813
- x5c?: string[] | undefined;
814
- x5t?: string | undefined;
815
- "x5t#S256"?: string | undefined;
816
- x5u?: string | undefined;
817
- }[];
818
- };
819
- display: {
820
- name: string;
821
- locale: string;
822
- }[];
823
- credential_issuer: string;
824
- credential_endpoint: string;
825
- revocation_endpoint: string;
826
- status_attestation_endpoint: string;
827
- credential_configurations_supported: Record<string, {
828
- format: "vc+sd-jwt" | "vc+mdoc-cbor";
829
- scope: string;
830
- display: {
831
- name: string;
832
- locale: string;
833
- }[];
834
- claims: Record<string, {
835
- value_type: string;
836
- display: {
837
- name: string;
838
- locale: string;
839
- }[];
840
- }>;
841
- cryptographic_binding_methods_supported: string[];
842
- credential_signing_alg_values_supported: string[];
843
- authentic_source?: string | undefined;
844
- issuance_errors_supported?: Record<string, {
845
- display: {
846
- locale: string;
847
- title: string;
848
- description: string;
849
- }[];
850
- }> | undefined;
851
- }>;
852
- };
853
- oauth_authorization_server: {
854
- request_object_signing_alg_values_supported: string[];
855
- jwks: {
856
- keys: {
857
- kty: "RSA" | "EC";
858
- alg?: string | undefined;
859
- crv?: string | undefined;
860
- d?: string | undefined;
861
- dp?: string | undefined;
862
- dq?: string | undefined;
863
- e?: string | undefined;
864
- ext?: boolean | undefined;
865
- k?: string | undefined;
866
- key_ops?: string[] | undefined;
867
- kid?: string | undefined;
868
- n?: string | undefined;
869
- p?: string | undefined;
870
- q?: string | undefined;
871
- qi?: string | undefined;
872
- use?: string | undefined;
873
- x?: string | undefined;
874
- y?: string | undefined;
875
- x5c?: string[] | undefined;
876
- x5t?: string | undefined;
877
- "x5t#S256"?: string | undefined;
878
- x5u?: string | undefined;
879
- }[];
880
- };
881
- authorization_endpoint: string;
882
- pushed_authorization_request_endpoint: string;
883
- token_endpoint: string;
884
- client_registration_types_supported: string[];
885
- code_challenge_methods_supported: string[];
886
- acr_values_supported: string[];
887
- grant_types_supported: string[];
888
- issuer: string;
889
- scopes_supported: string[];
890
- response_modes_supported: string[];
891
- token_endpoint_auth_methods_supported: string[];
892
- token_endpoint_auth_signing_alg_values_supported: string[];
893
- };
894
- openid_credential_verifier?: {
895
- jwks: {
896
- keys: {
897
- kty: "RSA" | "EC";
898
- alg?: string | undefined;
899
- crv?: string | undefined;
900
- d?: string | undefined;
901
- dp?: string | undefined;
902
- dq?: string | undefined;
903
- e?: string | undefined;
904
- ext?: boolean | undefined;
905
- k?: string | undefined;
906
- key_ops?: string[] | undefined;
907
- kid?: string | undefined;
908
- n?: string | undefined;
909
- p?: string | undefined;
910
- q?: string | undefined;
911
- qi?: string | undefined;
912
- use?: string | undefined;
913
- x?: string | undefined;
914
- y?: string | undefined;
915
- x5c?: string[] | undefined;
916
- x5t?: string | undefined;
917
- "x5t#S256"?: string | undefined;
918
- x5u?: string | undefined;
919
- }[];
920
- };
921
- application_type?: string | undefined;
922
- client_id?: string | undefined;
923
- client_name?: string | undefined;
924
- contacts?: string[] | undefined;
925
- presentation_definition?: {
926
- id: string;
927
- input_descriptors: {
928
- id: string;
929
- constraints: {
930
- fields?: {
931
- path: string[];
932
- id?: string | undefined;
933
- purpose?: string | undefined;
934
- name?: string | undefined;
935
- filter?: any;
936
- optional?: boolean | undefined;
937
- intent_to_retain?: boolean | undefined;
938
- }[] | undefined;
939
- limit_disclosure?: "required" | "preferred" | undefined;
940
- };
941
- name?: string | undefined;
942
- purpose?: string | undefined;
943
- format?: Record<string, any> | undefined;
944
- group?: string | undefined;
945
- }[];
946
- name?: string | undefined;
947
- purpose?: string | undefined;
948
- submission_requirements?: {
949
- rule: string;
950
- name?: string | undefined;
951
- purpose?: string | undefined;
952
- from?: string | undefined;
953
- from_nested?: {
954
- rule: string;
955
- from: string;
956
- name?: string | undefined;
957
- purpose?: string | undefined;
958
- }[] | undefined;
959
- count?: number | undefined;
960
- }[] | undefined;
961
- } | undefined;
962
- request_uris?: string[] | undefined;
963
- authorization_signed_response_alg?: string | undefined;
964
- authorization_encrypted_response_alg?: string | undefined;
965
- authorization_encrypted_response_enc?: string | undefined;
966
- } | undefined;
967
- };
968
- };
969
- }) | ({
970
- payload: {
971
- iss: string;
972
- sub: string;
973
- iat: number;
974
- exp: number;
975
- jwks: {
976
- keys: {
977
- kty: "RSA" | "EC";
978
- alg?: string | undefined;
979
- crv?: string | undefined;
980
- d?: string | undefined;
981
- dp?: string | undefined;
982
- dq?: string | undefined;
983
- e?: string | undefined;
984
- ext?: boolean | undefined;
985
- k?: string | undefined;
986
- key_ops?: string[] | undefined;
987
- kid?: string | undefined;
988
- n?: string | undefined;
989
- p?: string | undefined;
990
- q?: string | undefined;
991
- qi?: string | undefined;
992
- use?: string | undefined;
993
- x?: string | undefined;
994
- y?: string | undefined;
995
- x5c?: string[] | undefined;
996
- x5t?: string | undefined;
997
- "x5t#S256"?: string | undefined;
998
- x5u?: string | undefined;
999
- }[];
1000
- };
1001
- metadata: {
1002
- federation_entity: {
1003
- federation_fetch_endpoint?: string | undefined;
1004
- federation_list_endpoint?: string | undefined;
1005
- federation_resolve_endpoint?: string | undefined;
1006
- federation_trust_mark_status_endpoint?: string | undefined;
1007
- federation_trust_mark_list_endpoint?: string | undefined;
1008
- federation_trust_mark_endpoint?: string | undefined;
1009
- federation_historical_keys_endpoint?: string | undefined;
1010
- endpoint_auth_signing_alg_values_supported?: string | undefined;
1011
- organization_name?: string | undefined;
1012
- homepage_uri?: string | undefined;
1013
- policy_uri?: string | undefined;
1014
- logo_uri?: string | undefined;
1015
- contacts?: string[] | undefined;
1016
- } & {
1017
- [k: string]: unknown;
1018
- };
1019
- } & {
1020
- [k: string]: unknown;
1021
- };
1022
- authority_hints?: string[] | undefined;
1023
- } & {
1024
- [k: string]: unknown;
1025
- };
1026
- header: {
1027
- alg: string;
1028
- kid: string;
1029
- typ: "entity-statement+jwt";
1030
- };
1031
- } & {
1032
- payload: {
1033
- metadata: {
1034
- openid_credential_verifier: {
1035
- jwks: {
1036
- keys: {
1037
- kty: "RSA" | "EC";
1038
- alg?: string | undefined;
1039
- crv?: string | undefined;
1040
- d?: string | undefined;
1041
- dp?: string | undefined;
1042
- dq?: string | undefined;
1043
- e?: string | undefined;
1044
- ext?: boolean | undefined;
1045
- k?: string | undefined;
1046
- key_ops?: string[] | undefined;
1047
- kid?: string | undefined;
1048
- n?: string | undefined;
1049
- p?: string | undefined;
1050
- q?: string | undefined;
1051
- qi?: string | undefined;
1052
- use?: string | undefined;
1053
- x?: string | undefined;
1054
- y?: string | undefined;
1055
- x5c?: string[] | undefined;
1056
- x5t?: string | undefined;
1057
- "x5t#S256"?: string | undefined;
1058
- x5u?: string | undefined;
1059
- }[];
1060
- };
1061
- application_type?: string | undefined;
1062
- client_id?: string | undefined;
1063
- client_name?: string | undefined;
1064
- contacts?: string[] | undefined;
1065
- presentation_definition?: {
1066
- id: string;
1067
- input_descriptors: {
1068
- id: string;
1069
- constraints: {
1070
- fields?: {
1071
- path: string[];
1072
- id?: string | undefined;
1073
- purpose?: string | undefined;
1074
- name?: string | undefined;
1075
- filter?: any;
1076
- optional?: boolean | undefined;
1077
- intent_to_retain?: boolean | undefined;
1078
- }[] | undefined;
1079
- limit_disclosure?: "required" | "preferred" | undefined;
1080
- };
1081
- name?: string | undefined;
1082
- purpose?: string | undefined;
1083
- format?: Record<string, any> | undefined;
1084
- group?: string | undefined;
1085
- }[];
1086
- name?: string | undefined;
1087
- purpose?: string | undefined;
1088
- submission_requirements?: {
1089
- rule: string;
1090
- name?: string | undefined;
1091
- purpose?: string | undefined;
1092
- from?: string | undefined;
1093
- from_nested?: {
1094
- rule: string;
1095
- from: string;
1096
- name?: string | undefined;
1097
- purpose?: string | undefined;
1098
- }[] | undefined;
1099
- count?: number | undefined;
1100
- }[] | undefined;
1101
- } | undefined;
1102
- request_uris?: string[] | undefined;
1103
- authorization_signed_response_alg?: string | undefined;
1104
- authorization_encrypted_response_alg?: string | undefined;
1105
- authorization_encrypted_response_enc?: string | undefined;
1106
- };
1107
- };
1108
- };
1109
- }) | ({
1110
- payload: {
1111
- iss: string;
1112
- sub: string;
1113
- iat: number;
1114
- exp: number;
1115
- jwks: {
1116
- keys: {
1117
- kty: "RSA" | "EC";
1118
- alg?: string | undefined;
1119
- crv?: string | undefined;
1120
- d?: string | undefined;
1121
- dp?: string | undefined;
1122
- dq?: string | undefined;
1123
- e?: string | undefined;
1124
- ext?: boolean | undefined;
1125
- k?: string | undefined;
1126
- key_ops?: string[] | undefined;
1127
- kid?: string | undefined;
1128
- n?: string | undefined;
1129
- p?: string | undefined;
1130
- q?: string | undefined;
1131
- qi?: string | undefined;
1132
- use?: string | undefined;
1133
- x?: string | undefined;
1134
- y?: string | undefined;
1135
- x5c?: string[] | undefined;
1136
- x5t?: string | undefined;
1137
- "x5t#S256"?: string | undefined;
1138
- x5u?: string | undefined;
1139
- }[];
1140
- };
1141
- metadata: {
1142
- federation_entity: {
1143
- federation_fetch_endpoint?: string | undefined;
1144
- federation_list_endpoint?: string | undefined;
1145
- federation_resolve_endpoint?: string | undefined;
1146
- federation_trust_mark_status_endpoint?: string | undefined;
1147
- federation_trust_mark_list_endpoint?: string | undefined;
1148
- federation_trust_mark_endpoint?: string | undefined;
1149
- federation_historical_keys_endpoint?: string | undefined;
1150
- endpoint_auth_signing_alg_values_supported?: string | undefined;
1151
- organization_name?: string | undefined;
1152
- homepage_uri?: string | undefined;
1153
- policy_uri?: string | undefined;
1154
- logo_uri?: string | undefined;
1155
- contacts?: string[] | undefined;
1156
- } & {
1157
- [k: string]: unknown;
1158
- };
1159
- } & {
1160
- [k: string]: unknown;
1161
- };
1162
- authority_hints?: string[] | undefined;
1163
- } & {
1164
- [k: string]: unknown;
1165
- };
1166
- header: {
1167
- alg: string;
1168
- kid: string;
1169
- typ: "entity-statement+jwt";
1170
- };
1171
- } & {
1172
- payload: {
1173
- metadata: {
1174
- wallet_provider: {
1175
- jwks: {
1176
- keys: {
1177
- kty: "RSA" | "EC";
1178
- alg?: string | undefined;
1179
- crv?: string | undefined;
1180
- d?: string | undefined;
1181
- dp?: string | undefined;
1182
- dq?: string | undefined;
1183
- e?: string | undefined;
1184
- ext?: boolean | undefined;
1185
- k?: string | undefined;
1186
- key_ops?: string[] | undefined;
1187
- kid?: string | undefined;
1188
- n?: string | undefined;
1189
- p?: string | undefined;
1190
- q?: string | undefined;
1191
- qi?: string | undefined;
1192
- use?: string | undefined;
1193
- x?: string | undefined;
1194
- y?: string | undefined;
1195
- x5c?: string[] | undefined;
1196
- x5t?: string | undefined;
1197
- "x5t#S256"?: string | undefined;
1198
- x5u?: string | undefined;
1199
- }[];
1200
- };
1201
- token_endpoint: string;
1202
- grant_types_supported: string[];
1203
- token_endpoint_auth_methods_supported: string[];
1204
- token_endpoint_auth_signing_alg_values_supported: string[];
1205
- aal_values_supported?: string[] | undefined;
1206
- } & {
1207
- [k: string]: unknown;
1208
- };
1209
- };
1210
- };
1211
- })>;
1212
- /**
1213
- * Fetch and parse the entity statement document for a given federation entity.
1214
- *
1215
- * @param accreditationBodyBaseUrl The base url of the accreditation body which holds and signs the required entity statement
1216
- * @param subordinatedEntityBaseUrl The url that identifies the subordinate entity
1217
- * @param appFetch An optional instance of the http client to be used.
1218
- * @returns The parsed entity configuration object
1219
- * @throws {IoWalletError} If the http request fails
1220
- */
1221
- export declare function getEntityStatement(accreditationBodyBaseUrl: string, subordinatedEntityBaseUrl: string, { appFetch, }?: {
1222
- appFetch?: GlobalFetch["fetch"];
1223
- }): Promise<{
1224
- payload: {
1225
- iss: string;
1226
- sub: string;
1227
- iat: number;
1228
- exp: number;
1229
- jwks: {
1230
- keys: {
1231
- kty: "RSA" | "EC";
1232
- alg?: string | undefined;
1233
- crv?: string | undefined;
1234
- d?: string | undefined;
1235
- dp?: string | undefined;
1236
- dq?: string | undefined;
1237
- e?: string | undefined;
1238
- ext?: boolean | undefined;
1239
- k?: string | undefined;
1240
- key_ops?: string[] | undefined;
1241
- kid?: string | undefined;
1242
- n?: string | undefined;
1243
- p?: string | undefined;
1244
- q?: string | undefined;
1245
- qi?: string | undefined;
1246
- use?: string | undefined;
1247
- x?: string | undefined;
1248
- y?: string | undefined;
1249
- x5c?: string[] | undefined;
1250
- x5t?: string | undefined;
1251
- "x5t#S256"?: string | undefined;
1252
- x5u?: string | undefined;
1253
- }[];
1254
- };
1255
- trust_marks?: {
1256
- id: string;
1257
- trust_mark: string;
1258
- }[] | undefined;
1259
- };
1260
- header: {
1261
- alg: string;
1262
- kid: string;
1263
- typ: "entity-statement+jwt";
1264
- };
1265
- }>;
1266
- /**
1267
- * Fetch the entity statement document for a given federation entity.
1268
- *
1269
- * @param federationFetchEndpoint The exact endpoint provided by the parent EC's metadata.
1270
- * @param subordinatedEntityBaseUrl The url that identifies the subordinate entity.
1271
- * @param appFetch An optional instance of the http client to be used.
1272
- * @returns The signed entity statement token.
1273
- * @throws {IoWalletError} If the http request fails.
1274
- */
1275
- export declare function getSignedEntityStatement(federationFetchEndpoint: string, subordinatedEntityBaseUrl: string, { appFetch, }?: {
1276
- appFetch?: GlobalFetch["fetch"];
1277
- }): Promise<string>;
1278
- /**
1279
- * Fetch the federation list document from a given endpoint.
1280
- *
1281
- * @param federationListEndpoint The URL of the federation list endpoint.
1282
- * @param appFetch An optional instance of the http client to be used.
1283
- * @returns The federation list as an array of strings.
1284
- * @throws {IoWalletError} If the HTTP request fails.
1285
- * @throws {FederationError} If the result is not in the expected format.
1286
- */
1287
- export declare function getFederationList(federationListEndpoint: string, { appFetch, }?: {
1288
- appFetch?: GlobalFetch["fetch"];
1289
- }): Promise<string[]>;
1290
- /**
1291
- * Build a not-verified trust chain for a given Relying Party (RP) entity.
1292
- *
1293
- * @param relyingPartyEntityBaseUrl The base URL of the RP entity
1294
- * @param trustAnchorKey The public key of the Trust Anchor (TA) entity
1295
- * @param appFetch An optional instance of the http client to be used.
1296
- * @returns A list of signed tokens that represent the trust chain, in the order of the chain (from the RP to the Trust Anchor)
1297
- * @throws {FederationError} When an element of the chain fails to parse or other build steps fail.
1298
- */
1299
- export declare function buildTrustChain(relyingPartyEntityBaseUrl: string, trustAnchorKey: JWK, appFetch?: GlobalFetch["fetch"]): Promise<string[]>;
1
+ import * as Build from "./build-chain";
2
+ import * as Verify from "./verify-chain";
3
+ import * as Errors from "./errors";
4
+ import * as Types from "./types";
5
+ export { Build, Verify, Errors, Types };
1300
6
  //# sourceMappingURL=index.d.ts.map