@janssenproject/cedarling_wasm 0.0.311-nodejs → 0.0.312

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.
@@ -155,13 +155,6 @@ export class Diagnostics {
155
155
  readonly reason: string[];
156
156
  }
157
157
 
158
- export class JsJsonLogic {
159
- free(): void;
160
- [Symbol.dispose](): void;
161
- apply(logic: any, data: any): any;
162
- constructor();
163
- }
164
-
165
158
  /**
166
159
  * A WASM wrapper for the Rust `cedarling::MultiIssuerAuthorizeResult` struct.
167
160
  * Represents the result of a multi-issuer authorization request.
@@ -234,3 +227,96 @@ export function init(config: any): Promise<Cedarling>;
234
227
  * ```
235
228
  */
236
229
  export function init_from_archive_bytes(config: any, archive_bytes: Uint8Array): Promise<Cedarling>;
230
+
231
+ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
232
+
233
+ export interface InitOutput {
234
+ readonly memory: WebAssembly.Memory;
235
+ readonly __wbg_cedarling_free: (a: number, b: number) => void;
236
+ readonly __wbg_multiissuerauthorizeresult_free: (a: number, b: number) => void;
237
+ readonly __wbg_get_multiissuerauthorizeresult_response: (a: number) => number;
238
+ readonly __wbg_set_multiissuerauthorizeresult_response: (a: number, b: number) => void;
239
+ readonly __wbg_get_multiissuerauthorizeresult_decision: (a: number) => number;
240
+ readonly __wbg_set_multiissuerauthorizeresult_decision: (a: number, b: number) => void;
241
+ readonly __wbg_get_multiissuerauthorizeresult_request_id: (a: number) => [number, number];
242
+ readonly __wbg_set_multiissuerauthorizeresult_request_id: (a: number, b: number, c: number) => void;
243
+ readonly multiissuerauthorizeresult_json_string: (a: number) => [number, number];
244
+ readonly init: (a: any) => any;
245
+ readonly init_from_archive_bytes: (a: any, b: any) => any;
246
+ readonly cedarling_new: (a: any) => any;
247
+ readonly cedarling_new_from_map: (a: any) => any;
248
+ readonly cedarling_authorize: (a: number, b: any) => any;
249
+ readonly cedarling_authorize_unsigned: (a: number, b: any) => any;
250
+ readonly cedarling_authorize_multi_issuer: (a: number, b: any) => any;
251
+ readonly cedarling_pop_logs: (a: number) => [number, number, number];
252
+ readonly cedarling_get_log_by_id: (a: number, b: number, c: number) => [number, number, number];
253
+ readonly cedarling_get_log_ids: (a: number) => any;
254
+ readonly cedarling_get_logs_by_tag: (a: number, b: number, c: number) => [number, number, number, number];
255
+ readonly cedarling_get_logs_by_request_id: (a: number, b: number, c: number) => [number, number, number, number];
256
+ readonly cedarling_get_logs_by_request_id_and_tag: (a: number, b: number, c: number, d: number, e: number) => [number, number, number, number];
257
+ readonly cedarling_shut_down: (a: number) => any;
258
+ readonly __wbg_authorizeresult_free: (a: number, b: number) => void;
259
+ readonly __wbg_get_authorizeresult_workload: (a: number) => number;
260
+ readonly __wbg_set_authorizeresult_workload: (a: number, b: number) => void;
261
+ readonly __wbg_get_authorizeresult_person: (a: number) => number;
262
+ readonly __wbg_set_authorizeresult_person: (a: number, b: number) => void;
263
+ readonly __wbg_get_authorizeresult_decision: (a: number) => number;
264
+ readonly __wbg_set_authorizeresult_decision: (a: number, b: number) => void;
265
+ readonly __wbg_get_authorizeresult_request_id: (a: number) => [number, number];
266
+ readonly __wbg_set_authorizeresult_request_id: (a: number, b: number, c: number) => void;
267
+ readonly authorizeresult_json_string: (a: number) => [number, number];
268
+ readonly authorizeresult_principal: (a: number, b: number, c: number) => number;
269
+ readonly __wbg_authorizeresultresponse_free: (a: number, b: number) => void;
270
+ readonly authorizeresultresponse_decision: (a: number) => number;
271
+ readonly authorizeresultresponse_diagnostics: (a: number) => number;
272
+ readonly __wbg_diagnostics_free: (a: number, b: number) => void;
273
+ readonly diagnostics_reason: (a: number) => [number, number];
274
+ readonly diagnostics_errors: (a: number) => [number, number];
275
+ readonly __wbg_policyevaluationerror_free: (a: number, b: number) => void;
276
+ readonly policyevaluationerror_id: (a: number) => [number, number];
277
+ readonly policyevaluationerror_error: (a: number) => [number, number];
278
+ readonly rust_zstd_wasm_shim_qsort: (a: number, b: number, c: number, d: number) => void;
279
+ readonly rust_zstd_wasm_shim_malloc: (a: number) => number;
280
+ readonly rust_zstd_wasm_shim_memcmp: (a: number, b: number, c: number) => number;
281
+ readonly rust_zstd_wasm_shim_calloc: (a: number, b: number) => number;
282
+ readonly rust_zstd_wasm_shim_free: (a: number) => void;
283
+ readonly rust_zstd_wasm_shim_memcpy: (a: number, b: number, c: number) => number;
284
+ readonly rust_zstd_wasm_shim_memmove: (a: number, b: number, c: number) => number;
285
+ readonly rust_zstd_wasm_shim_memset: (a: number, b: number, c: number) => number;
286
+ readonly wasm_bindgen__closure__destroy__h6040ec9204f8ec90: (a: number, b: number) => void;
287
+ readonly wasm_bindgen__closure__destroy__h5ca61ceeccdb4050: (a: number, b: number) => void;
288
+ readonly wasm_bindgen__convert__closures_____invoke__h662f8e0721b9d210: (a: number, b: number, c: any) => [number, number];
289
+ readonly wasm_bindgen__convert__closures_____invoke__hd96d811f18675791: (a: number, b: number, c: any, d: any) => void;
290
+ readonly wasm_bindgen__convert__closures_____invoke__h9354621fa201e4f1: (a: number, b: number) => void;
291
+ readonly __wbindgen_malloc: (a: number, b: number) => number;
292
+ readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
293
+ readonly __wbindgen_exn_store: (a: number) => void;
294
+ readonly __externref_table_alloc: () => number;
295
+ readonly __wbindgen_externrefs: WebAssembly.Table;
296
+ readonly __wbindgen_free: (a: number, b: number, c: number) => void;
297
+ readonly __externref_table_dealloc: (a: number) => void;
298
+ readonly __externref_drop_slice: (a: number, b: number) => void;
299
+ readonly __wbindgen_start: () => void;
300
+ }
301
+
302
+ export type SyncInitInput = BufferSource | WebAssembly.Module;
303
+
304
+ /**
305
+ * Instantiates the given `module`, which can either be bytes or
306
+ * a precompiled `WebAssembly.Module`.
307
+ *
308
+ * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
309
+ *
310
+ * @returns {InitOutput}
311
+ */
312
+ export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
313
+
314
+ /**
315
+ * If `module_or_path` is {RequestInfo} or {URL}, makes a request and
316
+ * for everything else, calls `WebAssembly.instantiate` directly.
317
+ *
318
+ * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
319
+ *
320
+ * @returns {Promise<InitOutput>}
321
+ */
322
+ export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
package/cedarling_wasm.js CHANGED
@@ -4,7 +4,7 @@
4
4
  * A WASM wrapper for the Rust `cedarling::AuthorizeResult` struct.
5
5
  * Represents the result of an authorization request.
6
6
  */
7
- class AuthorizeResult {
7
+ export class AuthorizeResult {
8
8
  static __wrap(ptr) {
9
9
  ptr = ptr >>> 0;
10
10
  const obj = Object.create(AuthorizeResult.prototype);
@@ -138,13 +138,12 @@ class AuthorizeResult {
138
138
  }
139
139
  }
140
140
  if (Symbol.dispose) AuthorizeResult.prototype[Symbol.dispose] = AuthorizeResult.prototype.free;
141
- exports.AuthorizeResult = AuthorizeResult;
142
141
 
143
142
  /**
144
143
  * A WASM wrapper for the Rust `cedar_policy::Response` struct.
145
144
  * Represents the result of an authorization request.
146
145
  */
147
- class AuthorizeResultResponse {
146
+ export class AuthorizeResultResponse {
148
147
  static __wrap(ptr) {
149
148
  ptr = ptr >>> 0;
150
149
  const obj = Object.create(AuthorizeResultResponse.prototype);
@@ -180,12 +179,11 @@ class AuthorizeResultResponse {
180
179
  }
181
180
  }
182
181
  if (Symbol.dispose) AuthorizeResultResponse.prototype[Symbol.dispose] = AuthorizeResultResponse.prototype.free;
183
- exports.AuthorizeResultResponse = AuthorizeResultResponse;
184
182
 
185
183
  /**
186
184
  * The instance of the Cedarling application.
187
185
  */
188
- class Cedarling {
186
+ export class Cedarling {
189
187
  static __wrap(ptr) {
190
188
  ptr = ptr >>> 0;
191
189
  const obj = Object.create(Cedarling.prototype);
@@ -354,7 +352,6 @@ class Cedarling {
354
352
  }
355
353
  }
356
354
  if (Symbol.dispose) Cedarling.prototype[Symbol.dispose] = Cedarling.prototype.free;
357
- exports.Cedarling = Cedarling;
358
355
 
359
356
  /**
360
357
  * Diagnostics
@@ -362,7 +359,7 @@ exports.Cedarling = Cedarling;
362
359
  *
363
360
  * Provides detailed information about how a policy decision was made, including policies that contributed to the decision and any errors encountered during evaluation.
364
361
  */
365
- class Diagnostics {
362
+ export class Diagnostics {
366
363
  static __wrap(ptr) {
367
364
  ptr = ptr >>> 0;
368
365
  const obj = Object.create(Diagnostics.prototype);
@@ -406,46 +403,12 @@ class Diagnostics {
406
403
  }
407
404
  }
408
405
  if (Symbol.dispose) Diagnostics.prototype[Symbol.dispose] = Diagnostics.prototype.free;
409
- exports.Diagnostics = Diagnostics;
410
-
411
- class JsJsonLogic {
412
- __destroy_into_raw() {
413
- const ptr = this.__wbg_ptr;
414
- this.__wbg_ptr = 0;
415
- JsJsonLogicFinalization.unregister(this);
416
- return ptr;
417
- }
418
- free() {
419
- const ptr = this.__destroy_into_raw();
420
- wasm.__wbg_jsjsonlogic_free(ptr, 0);
421
- }
422
- /**
423
- * @param {any} logic
424
- * @param {any} data
425
- * @returns {any}
426
- */
427
- apply(logic, data) {
428
- const ret = wasm.jsjsonlogic_apply(this.__wbg_ptr, logic, data);
429
- if (ret[2]) {
430
- throw takeFromExternrefTable0(ret[1]);
431
- }
432
- return takeFromExternrefTable0(ret[0]);
433
- }
434
- constructor() {
435
- const ret = wasm.jsjsonlogic_new();
436
- this.__wbg_ptr = ret >>> 0;
437
- JsJsonLogicFinalization.register(this, this.__wbg_ptr, this);
438
- return this;
439
- }
440
- }
441
- if (Symbol.dispose) JsJsonLogic.prototype[Symbol.dispose] = JsJsonLogic.prototype.free;
442
- exports.JsJsonLogic = JsJsonLogic;
443
406
 
444
407
  /**
445
408
  * A WASM wrapper for the Rust `cedarling::MultiIssuerAuthorizeResult` struct.
446
409
  * Represents the result of a multi-issuer authorization request.
447
410
  */
448
- class MultiIssuerAuthorizeResult {
411
+ export class MultiIssuerAuthorizeResult {
449
412
  static __wrap(ptr) {
450
413
  ptr = ptr >>> 0;
451
414
  const obj = Object.create(MultiIssuerAuthorizeResult.prototype);
@@ -542,7 +505,6 @@ class MultiIssuerAuthorizeResult {
542
505
  }
543
506
  }
544
507
  if (Symbol.dispose) MultiIssuerAuthorizeResult.prototype[Symbol.dispose] = MultiIssuerAuthorizeResult.prototype.free;
545
- exports.MultiIssuerAuthorizeResult = MultiIssuerAuthorizeResult;
546
508
 
547
509
  /**
548
510
  * PolicyEvaluationError
@@ -550,7 +512,7 @@ exports.MultiIssuerAuthorizeResult = MultiIssuerAuthorizeResult;
550
512
  *
551
513
  * Represents an error that occurred when evaluating a Cedar policy.
552
514
  */
553
- class PolicyEvaluationError {
515
+ export class PolicyEvaluationError {
554
516
  static __wrap(ptr) {
555
517
  ptr = ptr >>> 0;
556
518
  const obj = Object.create(PolicyEvaluationError.prototype);
@@ -602,7 +564,6 @@ class PolicyEvaluationError {
602
564
  }
603
565
  }
604
566
  if (Symbol.dispose) PolicyEvaluationError.prototype[Symbol.dispose] = PolicyEvaluationError.prototype.free;
605
- exports.PolicyEvaluationError = PolicyEvaluationError;
606
567
 
607
568
  /**
608
569
  * Create a new instance of the Cedarling application.
@@ -610,11 +571,10 @@ exports.PolicyEvaluationError = PolicyEvaluationError;
610
571
  * @param {any} config
611
572
  * @returns {Promise<Cedarling>}
612
573
  */
613
- function init(config) {
574
+ export function init(config) {
614
575
  const ret = wasm.init(config);
615
576
  return ret;
616
577
  }
617
- exports.init = init;
618
578
 
619
579
  /**
620
580
  * Create a new instance of the Cedarling application from archive bytes.
@@ -636,88 +596,80 @@ exports.init = init;
636
596
  * @param {Uint8Array} archive_bytes
637
597
  * @returns {Promise<Cedarling>}
638
598
  */
639
- function init_from_archive_bytes(config, archive_bytes) {
599
+ export function init_from_archive_bytes(config, archive_bytes) {
640
600
  const ret = wasm.init_from_archive_bytes(config, archive_bytes);
641
601
  return ret;
642
602
  }
643
- exports.init_from_archive_bytes = init_from_archive_bytes;
644
603
 
645
604
  function __wbg_get_imports() {
646
605
  const import0 = {
647
606
  __proto__: null,
648
- __wbg_Error_8c4e43fe74559d73: function(arg0, arg1) {
607
+ __wbg_Error_dbcd8782dbb273a2: function(arg0, arg1) {
649
608
  const ret = Error(getStringFromWasm0(arg0, arg1));
650
609
  return ret;
651
610
  },
652
- __wbg_Number_04624de7d0e8332d: function(arg0) {
611
+ __wbg_Number_012552ac4683228d: function(arg0) {
653
612
  const ret = Number(arg0);
654
613
  return ret;
655
614
  },
656
- __wbg_String_8f0eb39a4a4c2f66: function(arg0, arg1) {
657
- const ret = String(arg1);
658
- const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
659
- const len1 = WASM_VECTOR_LEN;
660
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
661
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
662
- },
663
- __wbg___wbindgen_bigint_get_as_i64_8fcf4ce7f1ca72a2: function(arg0, arg1) {
615
+ __wbg___wbindgen_bigint_get_as_i64_25c638f64ce0e2e0: function(arg0, arg1) {
664
616
  const v = arg1;
665
617
  const ret = typeof(v) === 'bigint' ? v : undefined;
666
618
  getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
667
619
  getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
668
620
  },
669
- __wbg___wbindgen_boolean_get_bbbb1c18aa2f5e25: function(arg0) {
621
+ __wbg___wbindgen_boolean_get_7f1c4dd217655ab6: function(arg0) {
670
622
  const v = arg0;
671
623
  const ret = typeof(v) === 'boolean' ? v : undefined;
672
624
  return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
673
625
  },
674
- __wbg___wbindgen_debug_string_0bc8482c6e3508ae: function(arg0, arg1) {
626
+ __wbg___wbindgen_debug_string_6cf0badf0b90f6ef: function(arg0, arg1) {
675
627
  const ret = debugString(arg1);
676
628
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
677
629
  const len1 = WASM_VECTOR_LEN;
678
630
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
679
631
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
680
632
  },
681
- __wbg___wbindgen_in_47fa6863be6f2f25: function(arg0, arg1) {
633
+ __wbg___wbindgen_in_e32cbbbf71fdc915: function(arg0, arg1) {
682
634
  const ret = arg0 in arg1;
683
635
  return ret;
684
636
  },
685
- __wbg___wbindgen_is_bigint_31b12575b56f32fc: function(arg0) {
637
+ __wbg___wbindgen_is_bigint_95f22c948ca1bbe1: function(arg0) {
686
638
  const ret = typeof(arg0) === 'bigint';
687
639
  return ret;
688
640
  },
689
- __wbg___wbindgen_is_function_0095a73b8b156f76: function(arg0) {
641
+ __wbg___wbindgen_is_function_4500d4795b15e70b: function(arg0) {
690
642
  const ret = typeof(arg0) === 'function';
691
643
  return ret;
692
644
  },
693
- __wbg___wbindgen_is_object_5ae8e5880f2c1fbd: function(arg0) {
645
+ __wbg___wbindgen_is_object_f8b6723c60349a13: function(arg0) {
694
646
  const val = arg0;
695
647
  const ret = typeof(val) === 'object' && val !== null;
696
648
  return ret;
697
649
  },
698
- __wbg___wbindgen_is_string_cd444516edc5b180: function(arg0) {
650
+ __wbg___wbindgen_is_string_89134e23eba104e4: function(arg0) {
699
651
  const ret = typeof(arg0) === 'string';
700
652
  return ret;
701
653
  },
702
- __wbg___wbindgen_is_undefined_9e4d92534c42d778: function(arg0) {
654
+ __wbg___wbindgen_is_undefined_1296fcc83c2da07a: function(arg0) {
703
655
  const ret = arg0 === undefined;
704
656
  return ret;
705
657
  },
706
- __wbg___wbindgen_jsval_eq_11888390b0186270: function(arg0, arg1) {
658
+ __wbg___wbindgen_jsval_eq_39cab0b49f8188e9: function(arg0, arg1) {
707
659
  const ret = arg0 === arg1;
708
660
  return ret;
709
661
  },
710
- __wbg___wbindgen_jsval_loose_eq_9dd77d8cd6671811: function(arg0, arg1) {
662
+ __wbg___wbindgen_jsval_loose_eq_3173dea557396a92: function(arg0, arg1) {
711
663
  const ret = arg0 == arg1;
712
664
  return ret;
713
665
  },
714
- __wbg___wbindgen_number_get_8ff4255516ccad3e: function(arg0, arg1) {
666
+ __wbg___wbindgen_number_get_3330675b4e5c3680: function(arg0, arg1) {
715
667
  const obj = arg1;
716
668
  const ret = typeof(obj) === 'number' ? obj : undefined;
717
669
  getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
718
670
  getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
719
671
  },
720
- __wbg___wbindgen_string_get_72fb696202c56729: function(arg0, arg1) {
672
+ __wbg___wbindgen_string_get_7b8bc463f6cbeefe: function(arg0, arg1) {
721
673
  const obj = arg1;
722
674
  const ret = typeof(obj) === 'string' ? obj : undefined;
723
675
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
@@ -725,22 +677,22 @@ function __wbg_get_imports() {
725
677
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
726
678
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
727
679
  },
728
- __wbg___wbindgen_throw_be289d5034ed271b: function(arg0, arg1) {
680
+ __wbg___wbindgen_throw_89ca9e2c67795ec1: function(arg0, arg1) {
729
681
  throw new Error(getStringFromWasm0(arg0, arg1));
730
682
  },
731
- __wbg__wbg_cb_unref_d9b87ff7982e3b21: function(arg0) {
683
+ __wbg__wbg_cb_unref_f00ff3c6385bd6fa: function(arg0) {
732
684
  arg0._wbg_cb_unref();
733
685
  },
734
- __wbg_abort_2f0584e03e8e3950: function(arg0) {
735
- arg0.abort();
736
- },
737
- __wbg_abort_d549b92d3c665de1: function(arg0, arg1) {
686
+ __wbg_abort_d5982476775d2739: function(arg0, arg1) {
738
687
  arg0.abort(arg1);
739
688
  },
740
- __wbg_append_a992ccc37aa62dc4: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
689
+ __wbg_abort_e6a92d5623297220: function(arg0) {
690
+ arg0.abort();
691
+ },
692
+ __wbg_append_bddb95024c591a53: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
741
693
  arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
742
694
  }, arguments); },
743
- __wbg_arrayBuffer_bb54076166006c39: function() { return handleError(function (arg0) {
695
+ __wbg_arrayBuffer_c95edc576c2724fe: function() { return handleError(function (arg0) {
744
696
  const ret = arg0.arrayBuffer();
745
697
  return ret;
746
698
  }, arguments); },
@@ -748,94 +700,106 @@ function __wbg_get_imports() {
748
700
  const ret = AuthorizeResult.__wrap(arg0);
749
701
  return ret;
750
702
  },
751
- __wbg_call_389efe28435a9388: function() { return handleError(function (arg0, arg1) {
752
- const ret = arg0.call(arg1);
703
+ __wbg_call_3eadb5cea0462653: function() { return handleError(function (arg0, arg1, arg2) {
704
+ const ret = arg0.call(arg1, arg2);
753
705
  return ret;
754
706
  }, arguments); },
755
- __wbg_call_4708e0c13bdc8e95: function() { return handleError(function (arg0, arg1, arg2) {
756
- const ret = arg0.call(arg1, arg2);
707
+ __wbg_call_eb691bc2f5533064: function() { return handleError(function (arg0, arg1) {
708
+ const ret = arg0.call(arg1);
757
709
  return ret;
758
710
  }, arguments); },
759
711
  __wbg_cedarling_new: function(arg0) {
760
712
  const ret = Cedarling.__wrap(arg0);
761
713
  return ret;
762
714
  },
763
- __wbg_clearTimeout_42d9ccd50822fd3a: function(arg0) {
715
+ __wbg_clearTimeout_2256f1e7b94ef517: function(arg0) {
764
716
  const ret = clearTimeout(arg0);
765
717
  return ret;
766
718
  },
767
- __wbg_crypto_86f2631e91b51511: function(arg0) {
719
+ __wbg_crypto_38df2bab126b63dc: function(arg0) {
768
720
  const ret = arg0.crypto;
769
721
  return ret;
770
722
  },
771
- __wbg_debug_8b4b5465cbd54cd3: function(arg0) {
723
+ __wbg_debug_4aa822a1af5d039c: function(arg0) {
772
724
  console.debug(...arg0);
773
725
  },
774
- __wbg_done_57b39ecd9addfe81: function(arg0) {
726
+ __wbg_done_82b14aeb31e98db6: function(arg0) {
775
727
  const ret = arg0.done;
776
728
  return ret;
777
729
  },
778
- __wbg_entries_200a450561fa274f: function(arg0) {
730
+ __wbg_entries_279f7c28f13d750a: function(arg0) {
779
731
  const ret = arg0.entries();
780
732
  return ret;
781
733
  },
782
- __wbg_entries_58c7934c745daac7: function(arg0) {
734
+ __wbg_entries_46c64fadfaa3b525: function(arg0) {
783
735
  const ret = Object.entries(arg0);
784
736
  return ret;
785
737
  },
786
- __wbg_error_62201eec3c0d66f9: function(arg0) {
738
+ __wbg_entries_70ed5a7af0d07177: function(arg0) {
739
+ const ret = arg0.entries();
740
+ return ret;
741
+ },
742
+ __wbg_error_5fc0bc226aeb2474: function(arg0) {
787
743
  console.error(...arg0);
788
744
  },
789
- __wbg_fetch_6bbc32f991730587: function(arg0) {
745
+ __wbg_fetch_43b2f110608a59ff: function(arg0) {
790
746
  const ret = fetch(arg0);
791
747
  return ret;
792
748
  },
793
- __wbg_fetch_afb6a4b6cacf876d: function(arg0, arg1) {
749
+ __wbg_fetch_c170c157e1a111d4: function(arg0, arg1) {
794
750
  const ret = arg0.fetch(arg1);
795
751
  return ret;
796
752
  },
797
- __wbg_fromEntries_7fb5bc874dbe50d5: function() { return handleError(function (arg0) {
753
+ __wbg_fromEntries_cdb610e02cd25f1c: function() { return handleError(function (arg0) {
798
754
  const ret = Object.fromEntries(arg0);
799
755
  return ret;
800
756
  }, arguments); },
801
- __wbg_getRandomValues_1c61fac11405ffdc: function() { return handleError(function (arg0, arg1) {
757
+ __wbg_getRandomValues_ab1935b403569652: function() { return handleError(function (arg0, arg1) {
802
758
  globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
803
759
  }, arguments); },
804
- __wbg_getRandomValues_b3f15fcbfabb0f8b: function() { return handleError(function (arg0, arg1) {
760
+ __wbg_getRandomValues_c44a50d8cfdaebeb: function() { return handleError(function (arg0, arg1) {
805
761
  arg0.getRandomValues(arg1);
806
762
  }, arguments); },
807
- __wbg_getTime_1e3cd1391c5c3995: function(arg0) {
763
+ __wbg_getTime_4b23931c93d819bb: function(arg0) {
808
764
  const ret = arg0.getTime();
809
765
  return ret;
810
766
  },
811
- __wbg_getTimezoneOffset_81776d10a4ec18a8: function(arg0) {
767
+ __wbg_getTimezoneOffset_4f1ae12e19a7e5cb: function(arg0) {
812
768
  const ret = arg0.getTimezoneOffset();
813
769
  return ret;
814
770
  },
815
- __wbg_get_9b94d73e6221f75c: function(arg0, arg1) {
771
+ __wbg_get_229657ec2da079cd: function(arg0, arg1) {
816
772
  const ret = arg0[arg1 >>> 0];
817
773
  return ret;
818
774
  },
819
- __wbg_get_b3ed3ad4be2bc8ac: function() { return handleError(function (arg0, arg1) {
775
+ __wbg_get_89f3a4c398b4872e: function() { return handleError(function (arg0, arg1) {
820
776
  const ret = Reflect.get(arg0, arg1);
821
777
  return ret;
822
778
  }, arguments); },
823
- __wbg_get_with_ref_key_1dc361bd10053bfe: function(arg0, arg1) {
779
+ __wbg_get_ed44f5f876f22351: function() { return handleError(function (arg0, arg1) {
780
+ const ret = Reflect.get(arg0, arg1);
781
+ return ret;
782
+ }, arguments); },
783
+ __wbg_get_unchecked_ae4d1600970be7c3: function(arg0, arg1) {
784
+ const ret = arg0[arg1 >>> 0];
785
+ return ret;
786
+ },
787
+ __wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
824
788
  const ret = arg0[arg1];
825
789
  return ret;
826
790
  },
827
- __wbg_has_d4e53238966c12b6: function() { return handleError(function (arg0, arg1) {
791
+ __wbg_has_01b31fbd88bb3e8f: function() { return handleError(function (arg0, arg1) {
828
792
  const ret = Reflect.has(arg0, arg1);
829
793
  return ret;
830
794
  }, arguments); },
831
- __wbg_headers_59a2938db9f80985: function(arg0) {
795
+ __wbg_headers_fa752b79db86f8b3: function(arg0) {
832
796
  const ret = arg0.headers;
833
797
  return ret;
834
798
  },
835
- __wbg_info_eb43cb09e10f8150: function(arg0) {
799
+ __wbg_info_93be0cc78448065a: function(arg0) {
836
800
  console.info(...arg0);
837
801
  },
838
- __wbg_instanceof_ArrayBuffer_c367199e2fa2aa04: function(arg0) {
802
+ __wbg_instanceof_ArrayBuffer_4f2b9b5ed416155d: function(arg0) {
839
803
  let result;
840
804
  try {
841
805
  result = arg0 instanceof ArrayBuffer;
@@ -845,7 +809,7 @@ function __wbg_get_imports() {
845
809
  const ret = result;
846
810
  return ret;
847
811
  },
848
- __wbg_instanceof_Array_d9eac779cd191cbc: function(arg0) {
812
+ __wbg_instanceof_Array_c6fd13bcae830167: function(arg0) {
849
813
  let result;
850
814
  try {
851
815
  result = arg0 instanceof Array;
@@ -855,7 +819,7 @@ function __wbg_get_imports() {
855
819
  const ret = result;
856
820
  return ret;
857
821
  },
858
- __wbg_instanceof_Map_53af74335dec57f4: function(arg0) {
822
+ __wbg_instanceof_Map_3ad422261e078a42: function(arg0) {
859
823
  let result;
860
824
  try {
861
825
  result = arg0 instanceof Map;
@@ -865,7 +829,7 @@ function __wbg_get_imports() {
865
829
  const ret = result;
866
830
  return ret;
867
831
  },
868
- __wbg_instanceof_Response_ee1d54d79ae41977: function(arg0) {
832
+ __wbg_instanceof_Response_1844be67dbd5e161: function(arg0) {
869
833
  let result;
870
834
  try {
871
835
  result = arg0 instanceof Response;
@@ -875,7 +839,7 @@ function __wbg_get_imports() {
875
839
  const ret = result;
876
840
  return ret;
877
841
  },
878
- __wbg_instanceof_Uint8Array_9b9075935c74707c: function(arg0) {
842
+ __wbg_instanceof_Uint8Array_6482c66fce35827d: function(arg0) {
879
843
  let result;
880
844
  try {
881
845
  result = arg0 instanceof Uint8Array;
@@ -885,34 +849,34 @@ function __wbg_get_imports() {
885
849
  const ret = result;
886
850
  return ret;
887
851
  },
888
- __wbg_isArray_d314bb98fcf08331: function(arg0) {
852
+ __wbg_isArray_fe5201bfdab7e39d: function(arg0) {
889
853
  const ret = Array.isArray(arg0);
890
854
  return ret;
891
855
  },
892
- __wbg_isSafeInteger_bfbc7332a9768d2a: function(arg0) {
856
+ __wbg_isSafeInteger_d6215c7562dbc4db: function(arg0) {
893
857
  const ret = Number.isSafeInteger(arg0);
894
858
  return ret;
895
859
  },
896
- __wbg_iterator_6ff6560ca1568e55: function() {
860
+ __wbg_iterator_63c3a1857203cf2f: function() {
897
861
  const ret = Symbol.iterator;
898
862
  return ret;
899
863
  },
900
- __wbg_keys_b50a709a76add04e: function(arg0) {
864
+ __wbg_keys_31cd32ffa3aa3d32: function(arg0) {
901
865
  const ret = Object.keys(arg0);
902
866
  return ret;
903
867
  },
904
- __wbg_length_32ed9a279acd054c: function(arg0) {
868
+ __wbg_length_f875d3a041bab91a: function(arg0) {
905
869
  const ret = arg0.length;
906
870
  return ret;
907
871
  },
908
- __wbg_length_35a7bace40f36eac: function(arg0) {
872
+ __wbg_length_feaf2a40e5f9755a: function(arg0) {
909
873
  const ret = arg0.length;
910
874
  return ret;
911
875
  },
912
- __wbg_log_aa96eafb763b3303: function(arg0) {
876
+ __wbg_log_c6f597dffc84d4f3: function(arg0) {
913
877
  console.log(...arg0);
914
878
  },
915
- __wbg_msCrypto_d562bbe83e0d4b91: function(arg0) {
879
+ __wbg_msCrypto_bd5a034af96bcba6: function(arg0) {
916
880
  const ret = arg0.msCrypto;
917
881
  return ret;
918
882
  },
@@ -920,34 +884,50 @@ function __wbg_get_imports() {
920
884
  const ret = MultiIssuerAuthorizeResult.__wrap(arg0);
921
885
  return ret;
922
886
  },
923
- __wbg_new_0_73afc35eb544e539: function() {
887
+ __wbg_new_08d33c204155a3e2: function() { return handleError(function () {
888
+ const ret = new AbortController();
889
+ return ret;
890
+ }, arguments); },
891
+ __wbg_new_0_e8782c8df6122565: function() {
924
892
  const ret = new Date();
925
893
  return ret;
926
894
  },
927
- __wbg_new_245cd5c49157e602: function(arg0) {
895
+ __wbg_new_5947ca72f3fee3e6: function() {
896
+ const ret = new Map();
897
+ return ret;
898
+ },
899
+ __wbg_new_61cfa1e9627505e2: function(arg0) {
928
900
  const ret = new Date(arg0);
929
901
  return ret;
930
902
  },
931
- __wbg_new_361308b2356cecd0: function() {
932
- const ret = new Object();
903
+ __wbg_new_6e7681a5f6f98ceb: function(arg0) {
904
+ const ret = new Uint8Array(arg0);
933
905
  return ret;
934
906
  },
935
- __wbg_new_3eb36ae241fe6f44: function() {
936
- const ret = new Array();
907
+ __wbg_new_6feff3e11e4d0799: function() {
908
+ const ret = new Object();
937
909
  return ret;
938
910
  },
939
- __wbg_new_64284bd487f9d239: function() { return handleError(function () {
911
+ __wbg_new_e88efd8ca5aef956: function() { return handleError(function () {
940
912
  const ret = new Headers();
941
913
  return ret;
942
914
  }, arguments); },
943
- __wbg_new_b5d9e2fb389fef91: function(arg0, arg1) {
915
+ __wbg_new_ff7f9cc4c9a4a0cf: function() {
916
+ const ret = new Array();
917
+ return ret;
918
+ },
919
+ __wbg_new_from_slice_a5be53238f31f9f7: function(arg0, arg1) {
920
+ const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
921
+ return ret;
922
+ },
923
+ __wbg_new_typed_f79896f0ea5f7de8: function(arg0, arg1) {
944
924
  try {
945
925
  var state0 = {a: arg0, b: arg1};
946
926
  var cb0 = (arg0, arg1) => {
947
927
  const a = state0.a;
948
928
  state0.a = 0;
949
929
  try {
950
- return wasm_bindgen__convert__closures_____invoke__h5ea28dde88fe4fc5(a, state0.b, arg0, arg1);
930
+ return wasm_bindgen__convert__closures_____invoke__hd96d811f18675791(a, state0.b, arg0, arg1);
951
931
  } finally {
952
932
  state0.a = a;
953
933
  }
@@ -958,47 +938,23 @@ function __wbg_get_imports() {
958
938
  state0.a = state0.b = 0;
959
939
  }
960
940
  },
961
- __wbg_new_b949e7f56150a5d1: function() { return handleError(function () {
962
- const ret = new AbortController();
963
- return ret;
964
- }, arguments); },
965
- __wbg_new_dca287b076112a51: function() {
966
- const ret = new Map();
967
- return ret;
968
- },
969
- __wbg_new_dd2b680c8bf6ae29: function(arg0) {
970
- const ret = new Uint8Array(arg0);
971
- return ret;
972
- },
973
- __wbg_new_from_slice_a3d2629dc1826784: function(arg0, arg1) {
974
- const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
975
- return ret;
976
- },
977
- __wbg_new_no_args_1c7c842f08d00ebb: function(arg0, arg1) {
978
- const ret = new Function(getStringFromWasm0(arg0, arg1));
979
- return ret;
980
- },
981
- __wbg_new_with_args_7bba34e94b1cfa40: function(arg0, arg1, arg2, arg3) {
982
- const ret = new Function(getStringFromWasm0(arg0, arg1), getStringFromWasm0(arg2, arg3));
983
- return ret;
984
- },
985
- __wbg_new_with_length_a2c39cbe88fd8ff1: function(arg0) {
941
+ __wbg_new_with_length_3217a89bbca17214: function(arg0) {
986
942
  const ret = new Uint8Array(arg0 >>> 0);
987
943
  return ret;
988
944
  },
989
- __wbg_new_with_str_and_init_a61cbc6bdef21614: function() { return handleError(function (arg0, arg1, arg2) {
945
+ __wbg_new_with_str_and_init_66de5344635d3590: function() { return handleError(function (arg0, arg1, arg2) {
990
946
  const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
991
947
  return ret;
992
948
  }, arguments); },
993
- __wbg_next_3482f54c49e8af19: function() { return handleError(function (arg0) {
949
+ __wbg_next_ae5b710aea83f41e: function() { return handleError(function (arg0) {
994
950
  const ret = arg0.next();
995
951
  return ret;
996
952
  }, arguments); },
997
- __wbg_next_418f80d8f5303233: function(arg0) {
953
+ __wbg_next_f577b3e02c9be709: function(arg0) {
998
954
  const ret = arg0.next;
999
955
  return ret;
1000
956
  },
1001
- __wbg_node_e1f24f89a7336c2e: function(arg0) {
957
+ __wbg_node_84ea875411254db1: function(arg0) {
1002
958
  const ret = arg0.node;
1003
959
  return ret;
1004
960
  },
@@ -1006,147 +962,143 @@ function __wbg_get_imports() {
1006
962
  const ret = PolicyEvaluationError.__wrap(arg0);
1007
963
  return ret;
1008
964
  },
1009
- __wbg_process_3975fd6c72f520aa: function(arg0) {
965
+ __wbg_process_44c7a14e11e9f69e: function(arg0) {
1010
966
  const ret = arg0.process;
1011
967
  return ret;
1012
968
  },
1013
- __wbg_prototypesetcall_bdcdcc5842e4d77d: function(arg0, arg1, arg2) {
969
+ __wbg_prototypesetcall_37f00e1be5c4015a: function(arg0, arg1, arg2) {
1014
970
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
1015
971
  },
1016
- __wbg_push_8ffdcb2063340ba5: function(arg0, arg1) {
972
+ __wbg_push_3584053bd77475ee: function(arg0, arg1) {
1017
973
  const ret = arg0.push(arg1);
1018
974
  return ret;
1019
975
  },
1020
- __wbg_queueMicrotask_0aa0a927f78f5d98: function(arg0) {
976
+ __wbg_queueMicrotask_5e387cf4d8e3f63e: function(arg0) {
977
+ queueMicrotask(arg0);
978
+ },
979
+ __wbg_queueMicrotask_77bf5a3ad712168b: function(arg0) {
1021
980
  const ret = arg0.queueMicrotask;
1022
981
  return ret;
1023
982
  },
1024
- __wbg_queueMicrotask_5bb536982f78a56f: function(arg0) {
1025
- queueMicrotask(arg0);
1026
- },
1027
- __wbg_randomFillSync_f8c153b79f285817: function() { return handleError(function (arg0, arg1) {
983
+ __wbg_randomFillSync_6c25eac9869eb53c: function() { return handleError(function (arg0, arg1) {
1028
984
  arg0.randomFillSync(arg1);
1029
985
  }, arguments); },
1030
- __wbg_require_b74f47fc2d022fd6: function() { return handleError(function () {
986
+ __wbg_require_b4edbdcf3e2a1ef0: function() { return handleError(function () {
1031
987
  const ret = module.require;
1032
988
  return ret;
1033
989
  }, arguments); },
1034
- __wbg_resolve_002c4b7d9d8f6b64: function(arg0) {
990
+ __wbg_resolve_2e8556632715b12f: function(arg0) {
1035
991
  const ret = Promise.resolve(arg0);
1036
992
  return ret;
1037
993
  },
1038
- __wbg_setTimeout_4ec014681668a581: function(arg0, arg1) {
994
+ __wbg_setTimeout_b188b3bcc8977c7d: function(arg0, arg1) {
1039
995
  const ret = setTimeout(arg0, arg1);
1040
996
  return ret;
1041
997
  },
1042
- __wbg_set_1eb0999cf5d27fc8: function(arg0, arg1, arg2) {
1043
- const ret = arg0.set(arg1, arg2);
998
+ __wbg_set_409333732b484ee7: function() { return handleError(function (arg0, arg1, arg2) {
999
+ const ret = Reflect.set(arg0, arg1, arg2);
1044
1000
  return ret;
1001
+ }, arguments); },
1002
+ __wbg_set_601f3e1d081df3ac: function(arg0, arg1, arg2) {
1003
+ arg0[arg1 >>> 0] = arg2;
1045
1004
  },
1046
- __wbg_set_3f1d0b984ed272ed: function(arg0, arg1, arg2) {
1005
+ __wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
1047
1006
  arg0[arg1] = arg2;
1048
1007
  },
1049
- __wbg_set_6cb8631f80447a67: function() { return handleError(function (arg0, arg1, arg2) {
1050
- const ret = Reflect.set(arg0, arg1, arg2);
1008
+ __wbg_set_b1226382f10be917: function(arg0, arg1, arg2) {
1009
+ const ret = arg0.set(arg1, arg2);
1051
1010
  return ret;
1052
- }, arguments); },
1053
- __wbg_set_body_9a7e00afe3cfe244: function(arg0, arg1) {
1011
+ },
1012
+ __wbg_set_body_42d5ed933a1840a1: function(arg0, arg1) {
1054
1013
  arg0.body = arg1;
1055
1014
  },
1056
- __wbg_set_cache_315a3ed773a41543: function(arg0, arg1) {
1015
+ __wbg_set_cache_546c3dda0e43ae0c: function(arg0, arg1) {
1057
1016
  arg0.cache = __wbindgen_enum_RequestCache[arg1];
1058
1017
  },
1059
- __wbg_set_credentials_c4a58d2e05ef24fb: function(arg0, arg1) {
1018
+ __wbg_set_credentials_328fbf29cfdfa342: function(arg0, arg1) {
1060
1019
  arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
1061
1020
  },
1062
- __wbg_set_f43e577aea94465b: function(arg0, arg1, arg2) {
1063
- arg0[arg1 >>> 0] = arg2;
1064
- },
1065
- __wbg_set_headers_cfc5f4b2c1f20549: function(arg0, arg1) {
1021
+ __wbg_set_headers_1f8bdee11d576059: function(arg0, arg1) {
1066
1022
  arg0.headers = arg1;
1067
1023
  },
1068
- __wbg_set_method_c3e20375f5ae7fac: function(arg0, arg1, arg2) {
1024
+ __wbg_set_method_5a35896632ca213d: function(arg0, arg1, arg2) {
1069
1025
  arg0.method = getStringFromWasm0(arg1, arg2);
1070
1026
  },
1071
- __wbg_set_mode_b13642c312648202: function(arg0, arg1) {
1027
+ __wbg_set_mode_6fa10db5d133ac26: function(arg0, arg1) {
1072
1028
  arg0.mode = __wbindgen_enum_RequestMode[arg1];
1073
1029
  },
1074
- __wbg_set_signal_f2d3f8599248896d: function(arg0, arg1) {
1030
+ __wbg_set_signal_0d93209e168efc85: function(arg0, arg1) {
1075
1031
  arg0.signal = arg1;
1076
1032
  },
1077
- __wbg_signal_d1285ecab4ebc5ad: function(arg0) {
1033
+ __wbg_signal_a0d9fead74a07e34: function(arg0) {
1078
1034
  const ret = arg0.signal;
1079
1035
  return ret;
1080
1036
  },
1081
- __wbg_static_accessor_GLOBAL_12837167ad935116: function() {
1037
+ __wbg_static_accessor_GLOBAL_280fe6a619bbfbf6: function() {
1082
1038
  const ret = typeof global === 'undefined' ? null : global;
1083
1039
  return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1084
1040
  },
1085
- __wbg_static_accessor_GLOBAL_THIS_e628e89ab3b1c95f: function() {
1041
+ __wbg_static_accessor_GLOBAL_THIS_12c1f4811ec605d1: function() {
1086
1042
  const ret = typeof globalThis === 'undefined' ? null : globalThis;
1087
1043
  return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1088
1044
  },
1089
- __wbg_static_accessor_SELF_a621d3dfbb60d0ce: function() {
1045
+ __wbg_static_accessor_SELF_3a156961626f54d9: function() {
1090
1046
  const ret = typeof self === 'undefined' ? null : self;
1091
1047
  return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1092
1048
  },
1093
- __wbg_static_accessor_WINDOW_f8727f0cf888e0bd: function() {
1049
+ __wbg_static_accessor_WINDOW_210015b3eb6018a4: function() {
1094
1050
  const ret = typeof window === 'undefined' ? null : window;
1095
1051
  return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
1096
1052
  },
1097
- __wbg_status_89d7e803db911ee7: function(arg0) {
1053
+ __wbg_status_1544422a8c64aef0: function(arg0) {
1098
1054
  const ret = arg0.status;
1099
1055
  return ret;
1100
1056
  },
1101
- __wbg_stringify_8d1cc6ff383e8bae: function() { return handleError(function (arg0) {
1102
- const ret = JSON.stringify(arg0);
1103
- return ret;
1104
- }, arguments); },
1105
- __wbg_subarray_a96e1fef17ed23cb: function(arg0, arg1, arg2) {
1057
+ __wbg_subarray_a61f483a625b1793: function(arg0, arg1, arg2) {
1106
1058
  const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
1107
1059
  return ret;
1108
1060
  },
1109
- __wbg_text_083b8727c990c8c0: function() { return handleError(function (arg0) {
1061
+ __wbg_text_667415a14b08e789: function() { return handleError(function (arg0) {
1110
1062
  const ret = arg0.text();
1111
1063
  return ret;
1112
1064
  }, arguments); },
1113
- __wbg_then_0d9fe2c7b1857d32: function(arg0, arg1, arg2) {
1114
- const ret = arg0.then(arg1, arg2);
1065
+ __wbg_then_5ce48a9e69c0d3cd: function(arg0, arg1) {
1066
+ const ret = arg0.then(arg1);
1115
1067
  return ret;
1116
1068
  },
1117
- __wbg_then_b9e7b3b5f1a9e1b5: function(arg0, arg1) {
1118
- const ret = arg0.then(arg1);
1069
+ __wbg_then_f73127af3894d61c: function(arg0, arg1, arg2) {
1070
+ const ret = arg0.then(arg1, arg2);
1119
1071
  return ret;
1120
1072
  },
1121
- __wbg_trace_21a493b80d415f00: function(arg0) {
1073
+ __wbg_trace_62f38a2e54f4cc2a: function(arg0) {
1122
1074
  console.trace(...arg0);
1123
1075
  },
1124
- __wbg_url_c484c26b1fbf5126: function(arg0, arg1) {
1076
+ __wbg_url_271945e420831f05: function(arg0, arg1) {
1125
1077
  const ret = arg1.url;
1126
1078
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1127
1079
  const len1 = WASM_VECTOR_LEN;
1128
1080
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
1129
1081
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1130
1082
  },
1131
- __wbg_value_0546255b415e96c1: function(arg0) {
1083
+ __wbg_value_3e1fdb73e1353fb3: function(arg0) {
1132
1084
  const ret = arg0.value;
1133
1085
  return ret;
1134
1086
  },
1135
- __wbg_versions_4e31226f5e8dc909: function(arg0) {
1087
+ __wbg_versions_276b2795b1c6a219: function(arg0) {
1136
1088
  const ret = arg0.versions;
1137
1089
  return ret;
1138
1090
  },
1139
- __wbg_warn_f3657073f42e55b4: function(arg0) {
1091
+ __wbg_warn_3af8b0e50ab410d5: function(arg0) {
1140
1092
  console.warn(...arg0);
1141
1093
  },
1142
1094
  __wbindgen_cast_0000000000000001: function(arg0, arg1) {
1143
- // Cast intrinsic for `Closure(Closure { dtor_idx: 553, function: Function { arguments: [], shim_idx: 554, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1144
- const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h81df99cf5fb23bb4, wasm_bindgen__convert__closures_____invoke__h06cf10571db3fb4b);
1095
+ // Cast intrinsic for `Closure(Closure { dtor_idx: 577, function: Function { arguments: [], shim_idx: 578, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1096
+ const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h6040ec9204f8ec90, wasm_bindgen__convert__closures_____invoke__h9354621fa201e4f1);
1145
1097
  return ret;
1146
1098
  },
1147
1099
  __wbindgen_cast_0000000000000002: function(arg0, arg1) {
1148
- // Cast intrinsic for `Closure(Closure { dtor_idx: 597, function: Function { arguments: [Externref], shim_idx: 598, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1149
- const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__he589cbad438baf01, wasm_bindgen__convert__closures_____invoke__h30e9622b2b4b0718);
1100
+ // Cast intrinsic for `Closure(Closure { dtor_idx: 621, function: Function { arguments: [Externref], shim_idx: 2034, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1101
+ const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h5ca61ceeccdb4050, wasm_bindgen__convert__closures_____invoke__h662f8e0721b9d210);
1150
1102
  return ret;
1151
1103
  },
1152
1104
  __wbindgen_cast_0000000000000003: function(arg0) {
@@ -1190,16 +1142,19 @@ function __wbg_get_imports() {
1190
1142
  };
1191
1143
  }
1192
1144
 
1193
- function wasm_bindgen__convert__closures_____invoke__h06cf10571db3fb4b(arg0, arg1) {
1194
- wasm.wasm_bindgen__convert__closures_____invoke__h06cf10571db3fb4b(arg0, arg1);
1145
+ function wasm_bindgen__convert__closures_____invoke__h9354621fa201e4f1(arg0, arg1) {
1146
+ wasm.wasm_bindgen__convert__closures_____invoke__h9354621fa201e4f1(arg0, arg1);
1195
1147
  }
1196
1148
 
1197
- function wasm_bindgen__convert__closures_____invoke__h30e9622b2b4b0718(arg0, arg1, arg2) {
1198
- wasm.wasm_bindgen__convert__closures_____invoke__h30e9622b2b4b0718(arg0, arg1, arg2);
1149
+ function wasm_bindgen__convert__closures_____invoke__h662f8e0721b9d210(arg0, arg1, arg2) {
1150
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h662f8e0721b9d210(arg0, arg1, arg2);
1151
+ if (ret[1]) {
1152
+ throw takeFromExternrefTable0(ret[0]);
1153
+ }
1199
1154
  }
1200
1155
 
1201
- function wasm_bindgen__convert__closures_____invoke__h5ea28dde88fe4fc5(arg0, arg1, arg2, arg3) {
1202
- wasm.wasm_bindgen__convert__closures_____invoke__h5ea28dde88fe4fc5(arg0, arg1, arg2, arg3);
1156
+ function wasm_bindgen__convert__closures_____invoke__hd96d811f18675791(arg0, arg1, arg2, arg3) {
1157
+ wasm.wasm_bindgen__convert__closures_____invoke__hd96d811f18675791(arg0, arg1, arg2, arg3);
1203
1158
  }
1204
1159
 
1205
1160
 
@@ -1222,9 +1177,6 @@ const CedarlingFinalization = (typeof FinalizationRegistry === 'undefined')
1222
1177
  const DiagnosticsFinalization = (typeof FinalizationRegistry === 'undefined')
1223
1178
  ? { register: () => {}, unregister: () => {} }
1224
1179
  : new FinalizationRegistry(ptr => wasm.__wbg_diagnostics_free(ptr >>> 0, 1));
1225
- const JsJsonLogicFinalization = (typeof FinalizationRegistry === 'undefined')
1226
- ? { register: () => {}, unregister: () => {} }
1227
- : new FinalizationRegistry(ptr => wasm.__wbg_jsjsonlogic_free(ptr >>> 0, 1));
1228
1180
  const MultiIssuerAuthorizeResultFinalization = (typeof FinalizationRegistry === 'undefined')
1229
1181
  ? { register: () => {}, unregister: () => {} }
1230
1182
  : new FinalizationRegistry(ptr => wasm.__wbg_multiissuerauthorizeresult_free(ptr >>> 0, 1));
@@ -1436,7 +1388,15 @@ function takeFromExternrefTable0(idx) {
1436
1388
 
1437
1389
  let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1438
1390
  cachedTextDecoder.decode();
1391
+ const MAX_SAFARI_DECODE_BYTES = 2146435072;
1392
+ let numBytesDecoded = 0;
1439
1393
  function decodeText(ptr, len) {
1394
+ numBytesDecoded += len;
1395
+ if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
1396
+ cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1397
+ cachedTextDecoder.decode();
1398
+ numBytesDecoded = len;
1399
+ }
1440
1400
  return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
1441
1401
  }
1442
1402
 
@@ -1455,8 +1415,95 @@ if (!('encodeInto' in cachedTextEncoder)) {
1455
1415
 
1456
1416
  let WASM_VECTOR_LEN = 0;
1457
1417
 
1458
- const wasmPath = `${__dirname}/cedarling_wasm_bg.wasm`;
1459
- const wasmBytes = require('fs').readFileSync(wasmPath);
1460
- const wasmModule = new WebAssembly.Module(wasmBytes);
1461
- const wasm = new WebAssembly.Instance(wasmModule, __wbg_get_imports()).exports;
1462
- wasm.__wbindgen_start();
1418
+ let wasmModule, wasm;
1419
+ function __wbg_finalize_init(instance, module) {
1420
+ wasm = instance.exports;
1421
+ wasmModule = module;
1422
+ cachedDataViewMemory0 = null;
1423
+ cachedUint8ArrayMemory0 = null;
1424
+ wasm.__wbindgen_start();
1425
+ return wasm;
1426
+ }
1427
+
1428
+ async function __wbg_load(module, imports) {
1429
+ if (typeof Response === 'function' && module instanceof Response) {
1430
+ if (typeof WebAssembly.instantiateStreaming === 'function') {
1431
+ try {
1432
+ return await WebAssembly.instantiateStreaming(module, imports);
1433
+ } catch (e) {
1434
+ const validResponse = module.ok && expectedResponseType(module.type);
1435
+
1436
+ if (validResponse && module.headers.get('Content-Type') !== 'application/wasm') {
1437
+ console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n", e);
1438
+
1439
+ } else { throw e; }
1440
+ }
1441
+ }
1442
+
1443
+ const bytes = await module.arrayBuffer();
1444
+ return await WebAssembly.instantiate(bytes, imports);
1445
+ } else {
1446
+ const instance = await WebAssembly.instantiate(module, imports);
1447
+
1448
+ if (instance instanceof WebAssembly.Instance) {
1449
+ return { instance, module };
1450
+ } else {
1451
+ return instance;
1452
+ }
1453
+ }
1454
+
1455
+ function expectedResponseType(type) {
1456
+ switch (type) {
1457
+ case 'basic': case 'cors': case 'default': return true;
1458
+ }
1459
+ return false;
1460
+ }
1461
+ }
1462
+
1463
+ function initSync(module) {
1464
+ if (wasm !== undefined) return wasm;
1465
+
1466
+
1467
+ if (module !== undefined) {
1468
+ if (Object.getPrototypeOf(module) === Object.prototype) {
1469
+ ({module} = module)
1470
+ } else {
1471
+ console.warn('using deprecated parameters for `initSync()`; pass a single object instead')
1472
+ }
1473
+ }
1474
+
1475
+ const imports = __wbg_get_imports();
1476
+ if (!(module instanceof WebAssembly.Module)) {
1477
+ module = new WebAssembly.Module(module);
1478
+ }
1479
+ const instance = new WebAssembly.Instance(module, imports);
1480
+ return __wbg_finalize_init(instance, module);
1481
+ }
1482
+
1483
+ async function __wbg_init(module_or_path) {
1484
+ if (wasm !== undefined) return wasm;
1485
+
1486
+
1487
+ if (module_or_path !== undefined) {
1488
+ if (Object.getPrototypeOf(module_or_path) === Object.prototype) {
1489
+ ({module_or_path} = module_or_path)
1490
+ } else {
1491
+ console.warn('using deprecated parameters for the initialization function; pass a single object instead')
1492
+ }
1493
+ }
1494
+
1495
+ if (module_or_path === undefined) {
1496
+ module_or_path = new URL('cedarling_wasm_bg.wasm', import.meta.url);
1497
+ }
1498
+ const imports = __wbg_get_imports();
1499
+
1500
+ if (typeof module_or_path === 'string' || (typeof Request === 'function' && module_or_path instanceof Request) || (typeof URL === 'function' && module_or_path instanceof URL)) {
1501
+ module_or_path = fetch(module_or_path);
1502
+ }
1503
+
1504
+ const { instance, module } = await __wbg_load(await module_or_path, imports);
1505
+
1506
+ return __wbg_finalize_init(instance, module);
1507
+ }
1508
+
1509
+ export { initSync, __wbg_init as default };
Binary file
package/package.json CHANGED
@@ -1,7 +1,8 @@
1
1
  {
2
2
  "name": "@janssenproject/cedarling_wasm",
3
+ "type": "module",
3
4
  "description": "The Cedarling is a performant local authorization service that runs the Rust Cedar Engine",
4
- "version": "0.0.311-nodejs",
5
+ "version": "0.0.312",
5
6
  "license": "Apache-2.0",
6
7
  "repository": {
7
8
  "type": "git",
@@ -13,5 +14,8 @@
13
14
  "cedarling_wasm.d.ts"
14
15
  ],
15
16
  "main": "cedarling_wasm.js",
16
- "types": "cedarling_wasm.d.ts"
17
+ "types": "cedarling_wasm.d.ts",
18
+ "sideEffects": [
19
+ "./snippets/*"
20
+ ]
17
21
  }