@bitgo/wasm-utxo 1.11.0 → 1.13.0

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.
@@ -3,30 +3,44 @@ export function __wbg_set_wasm(val) {
3
3
  wasm = val;
4
4
  }
5
5
 
6
+ function addHeapObject(obj) {
7
+ if (heap_next === heap.length) heap.push(heap.length + 1);
8
+ const idx = heap_next;
9
+ heap_next = heap[idx];
6
10
 
7
- let cachedUint8ArrayMemory0 = null;
11
+ heap[idx] = obj;
12
+ return idx;
13
+ }
8
14
 
9
- function getUint8ArrayMemory0() {
10
- if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
11
- cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
15
+ function _assertClass(instance, klass) {
16
+ if (!(instance instanceof klass)) {
17
+ throw new Error(`expected instance of ${klass.name}`);
12
18
  }
13
- return cachedUint8ArrayMemory0;
14
19
  }
15
20
 
16
- let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
21
+ function addBorrowedObject(obj) {
22
+ if (stack_pointer == 1) throw new Error('out of js stack');
23
+ heap[--stack_pointer] = obj;
24
+ return stack_pointer;
25
+ }
17
26
 
18
- cachedTextDecoder.decode();
27
+ function dropObject(idx) {
28
+ if (idx < 132) return;
29
+ heap[idx] = heap_next;
30
+ heap_next = idx;
31
+ }
19
32
 
20
- const MAX_SAFARI_DECODE_BYTES = 2146435072;
21
- let numBytesDecoded = 0;
22
- function decodeText(ptr, len) {
23
- numBytesDecoded += len;
24
- if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
25
- cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
26
- cachedTextDecoder.decode();
27
- numBytesDecoded = len;
33
+ function getArrayU8FromWasm0(ptr, len) {
34
+ ptr = ptr >>> 0;
35
+ return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
36
+ }
37
+
38
+ let cachedDataViewMemory0 = null;
39
+ function getDataViewMemory0() {
40
+ if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
41
+ cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
28
42
  }
29
- return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
43
+ return cachedDataViewMemory0;
30
44
  }
31
45
 
32
46
  function getStringFromWasm0(ptr, len) {
@@ -34,19 +48,12 @@ function getStringFromWasm0(ptr, len) {
34
48
  return decodeText(ptr, len);
35
49
  }
36
50
 
37
- let heap = new Array(128).fill(undefined);
38
-
39
- heap.push(undefined, null, true, false);
40
-
41
- let heap_next = heap.length;
42
-
43
- function addHeapObject(obj) {
44
- if (heap_next === heap.length) heap.push(heap.length + 1);
45
- const idx = heap_next;
46
- heap_next = heap[idx];
47
-
48
- heap[idx] = obj;
49
- return idx;
51
+ let cachedUint8ArrayMemory0 = null;
52
+ function getUint8ArrayMemory0() {
53
+ if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
54
+ cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
55
+ }
56
+ return cachedUint8ArrayMemory0;
50
57
  }
51
58
 
52
59
  function getObject(idx) { return heap[idx]; }
@@ -55,57 +62,37 @@ function handleError(f, args) {
55
62
  try {
56
63
  return f.apply(this, args);
57
64
  } catch (e) {
58
- wasm.__wbindgen_export_0(addHeapObject(e));
65
+ wasm.__wbindgen_export3(addHeapObject(e));
59
66
  }
60
67
  }
61
68
 
62
- function getArrayU8FromWasm0(ptr, len) {
63
- ptr = ptr >>> 0;
64
- return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
65
- }
66
-
67
- function dropObject(idx) {
68
- if (idx < 132) return;
69
- heap[idx] = heap_next;
70
- heap_next = idx;
71
- }
69
+ let heap = new Array(128).fill(undefined);
70
+ heap.push(undefined, null, true, false);
72
71
 
73
- function takeObject(idx) {
74
- const ret = getObject(idx);
75
- dropObject(idx);
76
- return ret;
77
- }
72
+ let heap_next = heap.length;
78
73
 
79
74
  function isLikeNone(x) {
80
75
  return x === undefined || x === null;
81
76
  }
82
77
 
83
- let cachedDataViewMemory0 = null;
84
-
85
- function getDataViewMemory0() {
86
- if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
87
- cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
88
- }
89
- return cachedDataViewMemory0;
78
+ function passArray8ToWasm0(arg, malloc) {
79
+ const ptr = malloc(arg.length * 1, 1) >>> 0;
80
+ getUint8ArrayMemory0().set(arg, ptr / 1);
81
+ WASM_VECTOR_LEN = arg.length;
82
+ return ptr;
90
83
  }
91
84
 
92
- let WASM_VECTOR_LEN = 0;
93
-
94
- const cachedTextEncoder = new TextEncoder();
95
-
96
- if (!('encodeInto' in cachedTextEncoder)) {
97
- cachedTextEncoder.encodeInto = function (arg, view) {
98
- const buf = cachedTextEncoder.encode(arg);
99
- view.set(buf);
100
- return {
101
- read: arg.length,
102
- written: buf.length
103
- };
85
+ function passArrayJsValueToWasm0(array, malloc) {
86
+ const ptr = malloc(array.length * 4, 4) >>> 0;
87
+ const mem = getDataViewMemory0();
88
+ for (let i = 0; i < array.length; i++) {
89
+ mem.setUint32(ptr + 4 * i, addHeapObject(array[i]), true);
104
90
  }
91
+ WASM_VECTOR_LEN = array.length;
92
+ return ptr;
105
93
  }
106
94
 
107
95
  function passStringToWasm0(arg, malloc, realloc) {
108
-
109
96
  if (realloc === undefined) {
110
97
  const buf = cachedTextEncoder.encode(arg);
111
98
  const ptr = malloc(buf.length, 1) >>> 0;
@@ -126,7 +113,6 @@ function passStringToWasm0(arg, malloc, realloc) {
126
113
  if (code > 0x7F) break;
127
114
  mem[ptr + offset] = code;
128
115
  }
129
-
130
116
  if (offset !== len) {
131
117
  if (offset !== 0) {
132
118
  arg = arg.slice(offset);
@@ -143,50 +129,94 @@ function passStringToWasm0(arg, malloc, realloc) {
143
129
  return ptr;
144
130
  }
145
131
 
146
- function _assertClass(instance, klass) {
147
- if (!(instance instanceof klass)) {
148
- throw new Error(`expected instance of ${klass.name}`);
149
- }
150
- }
132
+ let stack_pointer = 128;
151
133
 
152
- function passArray8ToWasm0(arg, malloc) {
153
- const ptr = malloc(arg.length * 1, 1) >>> 0;
154
- getUint8ArrayMemory0().set(arg, ptr / 1);
155
- WASM_VECTOR_LEN = arg.length;
156
- return ptr;
134
+ function takeObject(idx) {
135
+ const ret = getObject(idx);
136
+ dropObject(idx);
137
+ return ret;
157
138
  }
158
139
 
159
- let stack_pointer = 128;
160
-
161
- function addBorrowedObject(obj) {
162
- if (stack_pointer == 1) throw new Error('out of js stack');
163
- heap[--stack_pointer] = obj;
164
- return stack_pointer;
140
+ let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
141
+ cachedTextDecoder.decode();
142
+ const MAX_SAFARI_DECODE_BYTES = 2146435072;
143
+ let numBytesDecoded = 0;
144
+ function decodeText(ptr, len) {
145
+ numBytesDecoded += len;
146
+ if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
147
+ cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
148
+ cachedTextDecoder.decode();
149
+ numBytesDecoded = len;
150
+ }
151
+ return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
165
152
  }
166
153
 
167
- function passArrayJsValueToWasm0(array, malloc) {
168
- const ptr = malloc(array.length * 4, 4) >>> 0;
169
- const mem = getDataViewMemory0();
170
- for (let i = 0; i < array.length; i++) {
171
- mem.setUint32(ptr + 4 * i, addHeapObject(array[i]), true);
154
+ const cachedTextEncoder = new TextEncoder();
155
+
156
+ if (!('encodeInto' in cachedTextEncoder)) {
157
+ cachedTextEncoder.encodeInto = function (arg, view) {
158
+ const buf = cachedTextEncoder.encode(arg);
159
+ view.set(buf);
160
+ return {
161
+ read: arg.length,
162
+ written: buf.length
163
+ };
172
164
  }
173
- WASM_VECTOR_LEN = array.length;
174
- return ptr;
175
165
  }
176
166
 
167
+ let WASM_VECTOR_LEN = 0;
168
+
177
169
  const AddressNamespaceFinalization = (typeof FinalizationRegistry === 'undefined')
178
170
  ? { register: () => {}, unregister: () => {} }
179
171
  : new FinalizationRegistry(ptr => wasm.__wbg_addressnamespace_free(ptr >>> 0, 1));
180
172
 
181
- export class AddressNamespace {
173
+ const BitGoPsbtFinalization = (typeof FinalizationRegistry === 'undefined')
174
+ ? { register: () => {}, unregister: () => {} }
175
+ : new FinalizationRegistry(ptr => wasm.__wbg_bitgopsbt_free(ptr >>> 0, 1));
176
+
177
+ const FixedScriptWalletNamespaceFinalization = (typeof FinalizationRegistry === 'undefined')
178
+ ? { register: () => {}, unregister: () => {} }
179
+ : new FinalizationRegistry(ptr => wasm.__wbg_fixedscriptwalletnamespace_free(ptr >>> 0, 1));
180
+
181
+ const UtxolibCompatNamespaceFinalization = (typeof FinalizationRegistry === 'undefined')
182
+ ? { register: () => {}, unregister: () => {} }
183
+ : new FinalizationRegistry(ptr => wasm.__wbg_utxolibcompatnamespace_free(ptr >>> 0, 1));
184
+
185
+ const WasmBIP32Finalization = (typeof FinalizationRegistry === 'undefined')
186
+ ? { register: () => {}, unregister: () => {} }
187
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmbip32_free(ptr >>> 0, 1));
188
+
189
+ const WasmECPairFinalization = (typeof FinalizationRegistry === 'undefined')
190
+ ? { register: () => {}, unregister: () => {} }
191
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmecpair_free(ptr >>> 0, 1));
192
+
193
+ const WasmReplayProtectionFinalization = (typeof FinalizationRegistry === 'undefined')
194
+ ? { register: () => {}, unregister: () => {} }
195
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmreplayprotection_free(ptr >>> 0, 1));
196
+
197
+ const WasmRootWalletKeysFinalization = (typeof FinalizationRegistry === 'undefined')
198
+ ? { register: () => {}, unregister: () => {} }
199
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmrootwalletkeys_free(ptr >>> 0, 1));
200
+
201
+ const WrapDescriptorFinalization = (typeof FinalizationRegistry === 'undefined')
202
+ ? { register: () => {}, unregister: () => {} }
203
+ : new FinalizationRegistry(ptr => wasm.__wbg_wrapdescriptor_free(ptr >>> 0, 1));
204
+
205
+ const WrapMiniscriptFinalization = (typeof FinalizationRegistry === 'undefined')
206
+ ? { register: () => {}, unregister: () => {} }
207
+ : new FinalizationRegistry(ptr => wasm.__wbg_wrapminiscript_free(ptr >>> 0, 1));
208
+
209
+ const WrapPsbtFinalization = (typeof FinalizationRegistry === 'undefined')
210
+ ? { register: () => {}, unregister: () => {} }
211
+ : new FinalizationRegistry(ptr => wasm.__wbg_wrappsbt_free(ptr >>> 0, 1));
182
212
 
213
+ export class AddressNamespace {
183
214
  __destroy_into_raw() {
184
215
  const ptr = this.__wbg_ptr;
185
216
  this.__wbg_ptr = 0;
186
217
  AddressNamespaceFinalization.unregister(this);
187
218
  return ptr;
188
219
  }
189
-
190
220
  free() {
191
221
  const ptr = this.__destroy_into_raw();
192
222
  wasm.__wbg_addressnamespace_free(ptr, 0);
@@ -199,9 +229,9 @@ export class AddressNamespace {
199
229
  static to_output_script_with_coin(address, coin) {
200
230
  try {
201
231
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
202
- const ptr0 = passStringToWasm0(address, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
232
+ const ptr0 = passStringToWasm0(address, wasm.__wbindgen_export, wasm.__wbindgen_export2);
203
233
  const len0 = WASM_VECTOR_LEN;
204
- const ptr1 = passStringToWasm0(coin, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
234
+ const ptr1 = passStringToWasm0(coin, wasm.__wbindgen_export, wasm.__wbindgen_export2);
205
235
  const len1 = WASM_VECTOR_LEN;
206
236
  wasm.addressnamespace_to_output_script_with_coin(retptr, ptr0, len0, ptr1, len1);
207
237
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -212,7 +242,7 @@ export class AddressNamespace {
212
242
  throw takeObject(r2);
213
243
  }
214
244
  var v3 = getArrayU8FromWasm0(r0, r1).slice();
215
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
245
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
216
246
  return v3;
217
247
  } finally {
218
248
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -229,11 +259,11 @@ export class AddressNamespace {
229
259
  let deferred5_1;
230
260
  try {
231
261
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
232
- const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export_1);
262
+ const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export);
233
263
  const len0 = WASM_VECTOR_LEN;
234
- const ptr1 = passStringToWasm0(coin, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
264
+ const ptr1 = passStringToWasm0(coin, wasm.__wbindgen_export, wasm.__wbindgen_export2);
235
265
  const len1 = WASM_VECTOR_LEN;
236
- var ptr2 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
266
+ var ptr2 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export, wasm.__wbindgen_export2);
237
267
  var len2 = WASM_VECTOR_LEN;
238
268
  wasm.addressnamespace_from_output_script_with_coin(retptr, ptr0, len0, ptr1, len1, ptr2, len2);
239
269
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -251,18 +281,13 @@ export class AddressNamespace {
251
281
  return getStringFromWasm0(ptr4, len4);
252
282
  } finally {
253
283
  wasm.__wbindgen_add_to_stack_pointer(16);
254
- wasm.__wbindgen_export_3(deferred5_0, deferred5_1, 1);
284
+ wasm.__wbindgen_export4(deferred5_0, deferred5_1, 1);
255
285
  }
256
286
  }
257
287
  }
258
288
  if (Symbol.dispose) AddressNamespace.prototype[Symbol.dispose] = AddressNamespace.prototype.free;
259
289
 
260
- const BitGoPsbtFinalization = (typeof FinalizationRegistry === 'undefined')
261
- ? { register: () => {}, unregister: () => {} }
262
- : new FinalizationRegistry(ptr => wasm.__wbg_bitgopsbt_free(ptr >>> 0, 1));
263
-
264
290
  export class BitGoPsbt {
265
-
266
291
  static __wrap(ptr) {
267
292
  ptr = ptr >>> 0;
268
293
  const obj = Object.create(BitGoPsbt.prototype);
@@ -270,14 +295,12 @@ export class BitGoPsbt {
270
295
  BitGoPsbtFinalization.register(obj, obj.__wbg_ptr, obj);
271
296
  return obj;
272
297
  }
273
-
274
298
  __destroy_into_raw() {
275
299
  const ptr = this.__wbg_ptr;
276
300
  this.__wbg_ptr = 0;
277
301
  BitGoPsbtFinalization.unregister(this);
278
302
  return ptr;
279
303
  }
280
-
281
304
  free() {
282
305
  const ptr = this.__destroy_into_raw();
283
306
  wasm.__wbg_bitgopsbt_free(ptr, 0);
@@ -291,9 +314,9 @@ export class BitGoPsbt {
291
314
  static from_bytes(bytes, network) {
292
315
  try {
293
316
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
294
- const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export_1);
317
+ const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export);
295
318
  const len0 = WASM_VECTOR_LEN;
296
- const ptr1 = passStringToWasm0(network, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
319
+ const ptr1 = passStringToWasm0(network, wasm.__wbindgen_export, wasm.__wbindgen_export2);
297
320
  const len1 = WASM_VECTOR_LEN;
298
321
  wasm.bitgopsbt_from_bytes(retptr, ptr0, len0, ptr1, len1);
299
322
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -324,7 +347,7 @@ export class BitGoPsbt {
324
347
  return getStringFromWasm0(r0, r1);
325
348
  } finally {
326
349
  wasm.__wbindgen_add_to_stack_pointer(16);
327
- wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
350
+ wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
328
351
  }
329
352
  }
330
353
  /**
@@ -420,7 +443,7 @@ export class BitGoPsbt {
420
443
  throw takeObject(r2);
421
444
  }
422
445
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
423
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
446
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
424
447
  return v1;
425
448
  } finally {
426
449
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -449,6 +472,38 @@ export class BitGoPsbt {
449
472
  wasm.__wbindgen_add_to_stack_pointer(16);
450
473
  }
451
474
  }
475
+ /**
476
+ * Add a PayGo attestation to a PSBT output
477
+ *
478
+ * # Arguments
479
+ * - `output_index`: The index of the output to add the attestation to
480
+ * - `entropy`: 64 bytes of entropy
481
+ * - `signature`: ECDSA signature bytes
482
+ *
483
+ * # Returns
484
+ * - `Ok(())` if the attestation was successfully added
485
+ * - `Err(WasmUtxoError)` if the output index is out of bounds or entropy is invalid
486
+ * @param {number} output_index
487
+ * @param {Uint8Array} entropy
488
+ * @param {Uint8Array} signature
489
+ */
490
+ add_paygo_attestation(output_index, entropy, signature) {
491
+ try {
492
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
493
+ const ptr0 = passArray8ToWasm0(entropy, wasm.__wbindgen_export);
494
+ const len0 = WASM_VECTOR_LEN;
495
+ const ptr1 = passArray8ToWasm0(signature, wasm.__wbindgen_export);
496
+ const len1 = WASM_VECTOR_LEN;
497
+ wasm.bitgopsbt_add_paygo_attestation(retptr, this.__wbg_ptr, output_index, ptr0, len0, ptr1, len1);
498
+ var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
499
+ var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
500
+ if (r1) {
501
+ throw takeObject(r0);
502
+ }
503
+ } finally {
504
+ wasm.__wbindgen_add_to_stack_pointer(16);
505
+ }
506
+ }
452
507
  /**
453
508
  * Combine/merge data from another PSBT into this one
454
509
  *
@@ -514,7 +569,7 @@ export class BitGoPsbt {
514
569
  try {
515
570
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
516
571
  _assertClass(xpriv, WasmBIP32);
517
- var ptr0 = isLikeNone(session_id_bytes) ? 0 : passArray8ToWasm0(session_id_bytes, wasm.__wbindgen_export_1);
572
+ var ptr0 = isLikeNone(session_id_bytes) ? 0 : passArray8ToWasm0(session_id_bytes, wasm.__wbindgen_export);
518
573
  var len0 = WASM_VECTOR_LEN;
519
574
  wasm.bitgopsbt_generate_musig2_nonces(retptr, this.__wbg_ptr, xpriv.__wbg_ptr, ptr0, len0);
520
575
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -606,13 +661,16 @@ export class BitGoPsbt {
606
661
  *
607
662
  * Note: This method does NOT validate wallet inputs. It only parses outputs.
608
663
  * @param {WasmRootWalletKeys} wallet_keys
664
+ * @param {WasmECPair[] | null} [paygo_pubkeys]
609
665
  * @returns {any}
610
666
  */
611
- parse_outputs_with_wallet_keys(wallet_keys) {
667
+ parse_outputs_with_wallet_keys(wallet_keys, paygo_pubkeys) {
612
668
  try {
613
669
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
614
670
  _assertClass(wallet_keys, WasmRootWalletKeys);
615
- wasm.bitgopsbt_parse_outputs_with_wallet_keys(retptr, this.__wbg_ptr, wallet_keys.__wbg_ptr);
671
+ var ptr0 = isLikeNone(paygo_pubkeys) ? 0 : passArrayJsValueToWasm0(paygo_pubkeys, wasm.__wbindgen_export);
672
+ var len0 = WASM_VECTOR_LEN;
673
+ wasm.bitgopsbt_parse_outputs_with_wallet_keys(retptr, this.__wbg_ptr, wallet_keys.__wbg_ptr, ptr0, len0);
616
674
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
617
675
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
618
676
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
@@ -628,14 +686,17 @@ export class BitGoPsbt {
628
686
  * Parse transaction with wallet keys to identify wallet inputs/outputs
629
687
  * @param {WasmRootWalletKeys} wallet_keys
630
688
  * @param {WasmReplayProtection} replay_protection
689
+ * @param {WasmECPair[] | null} [paygo_pubkeys]
631
690
  * @returns {any}
632
691
  */
633
- parse_transaction_with_wallet_keys(wallet_keys, replay_protection) {
692
+ parse_transaction_with_wallet_keys(wallet_keys, replay_protection, paygo_pubkeys) {
634
693
  try {
635
694
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
636
695
  _assertClass(wallet_keys, WasmRootWalletKeys);
637
696
  _assertClass(replay_protection, WasmReplayProtection);
638
- wasm.bitgopsbt_parse_transaction_with_wallet_keys(retptr, this.__wbg_ptr, wallet_keys.__wbg_ptr, replay_protection.__wbg_ptr);
697
+ var ptr0 = isLikeNone(paygo_pubkeys) ? 0 : passArrayJsValueToWasm0(paygo_pubkeys, wasm.__wbindgen_export);
698
+ var len0 = WASM_VECTOR_LEN;
699
+ wasm.bitgopsbt_parse_transaction_with_wallet_keys(retptr, this.__wbg_ptr, wallet_keys.__wbg_ptr, replay_protection.__wbg_ptr, ptr0, len0);
639
700
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
640
701
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
641
702
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
@@ -700,7 +761,7 @@ export class BitGoPsbt {
700
761
  return getStringFromWasm0(r0, r1);
701
762
  } finally {
702
763
  wasm.__wbindgen_add_to_stack_pointer(16);
703
- wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
764
+ wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
704
765
  }
705
766
  }
706
767
  /**
@@ -722,7 +783,7 @@ export class BitGoPsbt {
722
783
  throw takeObject(r2);
723
784
  }
724
785
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
725
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
786
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
726
787
  return v1;
727
788
  } finally {
728
789
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -731,19 +792,13 @@ export class BitGoPsbt {
731
792
  }
732
793
  if (Symbol.dispose) BitGoPsbt.prototype[Symbol.dispose] = BitGoPsbt.prototype.free;
733
794
 
734
- const FixedScriptWalletNamespaceFinalization = (typeof FinalizationRegistry === 'undefined')
735
- ? { register: () => {}, unregister: () => {} }
736
- : new FinalizationRegistry(ptr => wasm.__wbg_fixedscriptwalletnamespace_free(ptr >>> 0, 1));
737
-
738
795
  export class FixedScriptWalletNamespace {
739
-
740
796
  __destroy_into_raw() {
741
797
  const ptr = this.__wbg_ptr;
742
798
  this.__wbg_ptr = 0;
743
799
  FixedScriptWalletNamespaceFinalization.unregister(this);
744
800
  return ptr;
745
801
  }
746
-
747
802
  free() {
748
803
  const ptr = this.__destroy_into_raw();
749
804
  wasm.__wbg_fixedscriptwalletnamespace_free(ptr, 0);
@@ -768,7 +823,7 @@ export class FixedScriptWalletNamespace {
768
823
  throw takeObject(r2);
769
824
  }
770
825
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
771
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
826
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
772
827
  return v1;
773
828
  } finally {
774
829
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -788,7 +843,7 @@ export class FixedScriptWalletNamespace {
788
843
  try {
789
844
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
790
845
  _assertClass(keys, WasmRootWalletKeys);
791
- var ptr0 = isLikeNone(address_format) ? 0 : passStringToWasm0(address_format, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
846
+ var ptr0 = isLikeNone(address_format) ? 0 : passStringToWasm0(address_format, wasm.__wbindgen_export, wasm.__wbindgen_export2);
792
847
  var len0 = WASM_VECTOR_LEN;
793
848
  wasm.fixedscriptwalletnamespace_address(retptr, keys.__wbg_ptr, chain, index, addHeapObject(network), ptr0, len0);
794
849
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -806,25 +861,19 @@ export class FixedScriptWalletNamespace {
806
861
  return getStringFromWasm0(ptr2, len2);
807
862
  } finally {
808
863
  wasm.__wbindgen_add_to_stack_pointer(16);
809
- wasm.__wbindgen_export_3(deferred3_0, deferred3_1, 1);
864
+ wasm.__wbindgen_export4(deferred3_0, deferred3_1, 1);
810
865
  }
811
866
  }
812
867
  }
813
868
  if (Symbol.dispose) FixedScriptWalletNamespace.prototype[Symbol.dispose] = FixedScriptWalletNamespace.prototype.free;
814
869
 
815
- const UtxolibCompatNamespaceFinalization = (typeof FinalizationRegistry === 'undefined')
816
- ? { register: () => {}, unregister: () => {} }
817
- : new FinalizationRegistry(ptr => wasm.__wbg_utxolibcompatnamespace_free(ptr >>> 0, 1));
818
-
819
870
  export class UtxolibCompatNamespace {
820
-
821
871
  __destroy_into_raw() {
822
872
  const ptr = this.__wbg_ptr;
823
873
  this.__wbg_ptr = 0;
824
874
  UtxolibCompatNamespaceFinalization.unregister(this);
825
875
  return ptr;
826
876
  }
827
-
828
877
  free() {
829
878
  const ptr = this.__destroy_into_raw();
830
879
  wasm.__wbg_utxolibcompatnamespace_free(ptr, 0);
@@ -844,9 +893,9 @@ export class UtxolibCompatNamespace {
844
893
  static to_output_script(address, network, format) {
845
894
  try {
846
895
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
847
- const ptr0 = passStringToWasm0(address, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
896
+ const ptr0 = passStringToWasm0(address, wasm.__wbindgen_export, wasm.__wbindgen_export2);
848
897
  const len0 = WASM_VECTOR_LEN;
849
- var ptr1 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
898
+ var ptr1 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export, wasm.__wbindgen_export2);
850
899
  var len1 = WASM_VECTOR_LEN;
851
900
  wasm.utxolibcompatnamespace_to_output_script(retptr, ptr0, len0, addHeapObject(network), ptr1, len1);
852
901
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -857,7 +906,7 @@ export class UtxolibCompatNamespace {
857
906
  throw takeObject(r2);
858
907
  }
859
908
  var v3 = getArrayU8FromWasm0(r0, r1).slice();
860
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
909
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
861
910
  return v3;
862
911
  } finally {
863
912
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -880,9 +929,9 @@ export class UtxolibCompatNamespace {
880
929
  let deferred4_1;
881
930
  try {
882
931
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
883
- const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export_1);
932
+ const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export);
884
933
  const len0 = WASM_VECTOR_LEN;
885
- var ptr1 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
934
+ var ptr1 = isLikeNone(format) ? 0 : passStringToWasm0(format, wasm.__wbindgen_export, wasm.__wbindgen_export2);
886
935
  var len1 = WASM_VECTOR_LEN;
887
936
  wasm.utxolibcompatnamespace_from_output_script(retptr, ptr0, len0, addHeapObject(network), ptr1, len1);
888
937
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -900,21 +949,17 @@ export class UtxolibCompatNamespace {
900
949
  return getStringFromWasm0(ptr3, len3);
901
950
  } finally {
902
951
  wasm.__wbindgen_add_to_stack_pointer(16);
903
- wasm.__wbindgen_export_3(deferred4_0, deferred4_1, 1);
952
+ wasm.__wbindgen_export4(deferred4_0, deferred4_1, 1);
904
953
  }
905
954
  }
906
955
  }
907
956
  if (Symbol.dispose) UtxolibCompatNamespace.prototype[Symbol.dispose] = UtxolibCompatNamespace.prototype.free;
908
957
 
909
- const WasmBIP32Finalization = (typeof FinalizationRegistry === 'undefined')
910
- ? { register: () => {}, unregister: () => {} }
911
- : new FinalizationRegistry(ptr => wasm.__wbg_wasmbip32_free(ptr >>> 0, 1));
912
958
  /**
913
959
  * WASM wrapper for BIP32 extended keys (Xpub/Xpriv)
914
960
  * Implements the BIP32Interface TypeScript interface
915
961
  */
916
962
  export class WasmBIP32 {
917
-
918
963
  static __wrap(ptr) {
919
964
  ptr = ptr >>> 0;
920
965
  const obj = Object.create(WasmBIP32.prototype);
@@ -922,14 +967,12 @@ export class WasmBIP32 {
922
967
  WasmBIP32Finalization.register(obj, obj.__wbg_ptr, obj);
923
968
  return obj;
924
969
  }
925
-
926
970
  __destroy_into_raw() {
927
971
  const ptr = this.__wbg_ptr;
928
972
  this.__wbg_ptr = 0;
929
973
  WasmBIP32Finalization.unregister(this);
930
974
  return ptr;
931
975
  }
932
-
933
976
  free() {
934
977
  const ptr = this.__destroy_into_raw();
935
978
  wasm.__wbg_wasmbip32_free(ptr, 0);
@@ -966,7 +1009,7 @@ export class WasmBIP32 {
966
1009
  derive_path(path) {
967
1010
  try {
968
1011
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
969
- const ptr0 = passStringToWasm0(path, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1012
+ const ptr0 = passStringToWasm0(path, wasm.__wbindgen_export, wasm.__wbindgen_export2);
970
1013
  const len0 = WASM_VECTOR_LEN;
971
1014
  wasm.wasmbip32_derive_path(retptr, this.__wbg_ptr, ptr0, len0);
972
1015
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -996,7 +1039,7 @@ export class WasmBIP32 {
996
1039
  static from_base58(base58_str) {
997
1040
  try {
998
1041
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
999
- const ptr0 = passStringToWasm0(base58_str, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1042
+ const ptr0 = passStringToWasm0(base58_str, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1000
1043
  const len0 = WASM_VECTOR_LEN;
1001
1044
  wasm.wasmbip32_from_base58(retptr, ptr0, len0);
1002
1045
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1160,7 +1203,7 @@ export class WasmBIP32 {
1160
1203
  return getStringFromWasm0(ptr1, len1);
1161
1204
  } finally {
1162
1205
  wasm.__wbindgen_add_to_stack_pointer(16);
1163
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
1206
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
1164
1207
  }
1165
1208
  }
1166
1209
  /**
@@ -1180,9 +1223,9 @@ export class WasmBIP32 {
1180
1223
  static from_seed(seed, network) {
1181
1224
  try {
1182
1225
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1183
- const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_export_1);
1226
+ const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_export);
1184
1227
  const len0 = WASM_VECTOR_LEN;
1185
- var ptr1 = isLikeNone(network) ? 0 : passStringToWasm0(network, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1228
+ var ptr1 = isLikeNone(network) ? 0 : passStringToWasm0(network, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1186
1229
  var len1 = WASM_VECTOR_LEN;
1187
1230
  wasm.wasmbip32_from_seed(retptr, ptr0, len0, ptr1, len1);
1188
1231
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1204,7 +1247,7 @@ export class WasmBIP32 {
1204
1247
  static from_xprv(xprv_str) {
1205
1248
  try {
1206
1249
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1207
- const ptr0 = passStringToWasm0(xprv_str, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1250
+ const ptr0 = passStringToWasm0(xprv_str, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1208
1251
  const len0 = WASM_VECTOR_LEN;
1209
1252
  wasm.wasmbip32_from_xprv(retptr, ptr0, len0);
1210
1253
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1226,7 +1269,7 @@ export class WasmBIP32 {
1226
1269
  static from_xpub(xpub_str) {
1227
1270
  try {
1228
1271
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1229
- const ptr0 = passStringToWasm0(xpub_str, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1272
+ const ptr0 = passStringToWasm0(xpub_str, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1230
1273
  const len0 = WASM_VECTOR_LEN;
1231
1274
  wasm.wasmbip32_from_xpub(retptr, ptr0, len0);
1232
1275
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1257,20 +1300,16 @@ export class WasmBIP32 {
1257
1300
  return getStringFromWasm0(r0, r1);
1258
1301
  } finally {
1259
1302
  wasm.__wbindgen_add_to_stack_pointer(16);
1260
- wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
1303
+ wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
1261
1304
  }
1262
1305
  }
1263
1306
  }
1264
1307
  if (Symbol.dispose) WasmBIP32.prototype[Symbol.dispose] = WasmBIP32.prototype.free;
1265
1308
 
1266
- const WasmECPairFinalization = (typeof FinalizationRegistry === 'undefined')
1267
- ? { register: () => {}, unregister: () => {} }
1268
- : new FinalizationRegistry(ptr => wasm.__wbg_wasmecpair_free(ptr >>> 0, 1));
1269
1309
  /**
1270
1310
  * WASM wrapper for elliptic curve key pairs (always uses compressed keys)
1271
1311
  */
1272
1312
  export class WasmECPair {
1273
-
1274
1313
  static __wrap(ptr) {
1275
1314
  ptr = ptr >>> 0;
1276
1315
  const obj = Object.create(WasmECPair.prototype);
@@ -1278,14 +1317,18 @@ export class WasmECPair {
1278
1317
  WasmECPairFinalization.register(obj, obj.__wbg_ptr, obj);
1279
1318
  return obj;
1280
1319
  }
1281
-
1320
+ static __unwrap(jsValue) {
1321
+ if (!(jsValue instanceof WasmECPair)) {
1322
+ return 0;
1323
+ }
1324
+ return jsValue.__destroy_into_raw();
1325
+ }
1282
1326
  __destroy_into_raw() {
1283
1327
  const ptr = this.__wbg_ptr;
1284
1328
  this.__wbg_ptr = 0;
1285
1329
  WasmECPairFinalization.unregister(this);
1286
1330
  return ptr;
1287
1331
  }
1288
-
1289
1332
  free() {
1290
1333
  const ptr = this.__destroy_into_raw();
1291
1334
  wasm.__wbg_wasmecpair_free(ptr, 0);
@@ -1331,7 +1374,7 @@ export class WasmECPair {
1331
1374
  return getStringFromWasm0(ptr1, len1);
1332
1375
  } finally {
1333
1376
  wasm.__wbindgen_add_to_stack_pointer(16);
1334
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
1377
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
1335
1378
  }
1336
1379
  }
1337
1380
  /**
@@ -1359,7 +1402,7 @@ export class WasmECPair {
1359
1402
  return getStringFromWasm0(ptr1, len1);
1360
1403
  } finally {
1361
1404
  wasm.__wbindgen_add_to_stack_pointer(16);
1362
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
1405
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
1363
1406
  }
1364
1407
  }
1365
1408
  /**
@@ -1370,7 +1413,7 @@ export class WasmECPair {
1370
1413
  static from_public_key(public_key) {
1371
1414
  try {
1372
1415
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1373
- const ptr0 = passArray8ToWasm0(public_key, wasm.__wbindgen_export_1);
1416
+ const ptr0 = passArray8ToWasm0(public_key, wasm.__wbindgen_export);
1374
1417
  const len0 = WASM_VECTOR_LEN;
1375
1418
  wasm.wasmecpair_from_public_key(retptr, ptr0, len0);
1376
1419
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1392,7 +1435,7 @@ export class WasmECPair {
1392
1435
  static from_private_key(private_key) {
1393
1436
  try {
1394
1437
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1395
- const ptr0 = passArray8ToWasm0(private_key, wasm.__wbindgen_export_1);
1438
+ const ptr0 = passArray8ToWasm0(private_key, wasm.__wbindgen_export);
1396
1439
  const len0 = WASM_VECTOR_LEN;
1397
1440
  wasm.wasmecpair_from_private_key(retptr, ptr0, len0);
1398
1441
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1414,7 +1457,7 @@ export class WasmECPair {
1414
1457
  static from_wif_mainnet(wif_string) {
1415
1458
  try {
1416
1459
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1417
- const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1460
+ const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1418
1461
  const len0 = WASM_VECTOR_LEN;
1419
1462
  wasm.wasmecpair_from_wif_mainnet(retptr, ptr0, len0);
1420
1463
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1436,7 +1479,7 @@ export class WasmECPair {
1436
1479
  static from_wif_testnet(wif_string) {
1437
1480
  try {
1438
1481
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1439
- const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1482
+ const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1440
1483
  const len0 = WASM_VECTOR_LEN;
1441
1484
  wasm.wasmecpair_from_wif_testnet(retptr, ptr0, len0);
1442
1485
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1475,7 +1518,7 @@ export class WasmECPair {
1475
1518
  return getStringFromWasm0(ptr1, len1);
1476
1519
  } finally {
1477
1520
  wasm.__wbindgen_add_to_stack_pointer(16);
1478
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
1521
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
1479
1522
  }
1480
1523
  }
1481
1524
  /**
@@ -1486,7 +1529,7 @@ export class WasmECPair {
1486
1529
  static from_wif(wif_string) {
1487
1530
  try {
1488
1531
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1489
- const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1532
+ const ptr0 = passStringToWasm0(wif_string, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1490
1533
  const len0 = WASM_VECTOR_LEN;
1491
1534
  wasm.wasmecpair_from_wif(retptr, ptr0, len0);
1492
1535
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1503,14 +1546,10 @@ export class WasmECPair {
1503
1546
  }
1504
1547
  if (Symbol.dispose) WasmECPair.prototype[Symbol.dispose] = WasmECPair.prototype.free;
1505
1548
 
1506
- const WasmReplayProtectionFinalization = (typeof FinalizationRegistry === 'undefined')
1507
- ? { register: () => {}, unregister: () => {} }
1508
- : new FinalizationRegistry(ptr => wasm.__wbg_wasmreplayprotection_free(ptr >>> 0, 1));
1509
1549
  /**
1510
1550
  * WASM wrapper for ReplayProtection
1511
1551
  */
1512
1552
  export class WasmReplayProtection {
1513
-
1514
1553
  static __wrap(ptr) {
1515
1554
  ptr = ptr >>> 0;
1516
1555
  const obj = Object.create(WasmReplayProtection.prototype);
@@ -1518,14 +1557,12 @@ export class WasmReplayProtection {
1518
1557
  WasmReplayProtectionFinalization.register(obj, obj.__wbg_ptr, obj);
1519
1558
  return obj;
1520
1559
  }
1521
-
1522
1560
  __destroy_into_raw() {
1523
1561
  const ptr = this.__wbg_ptr;
1524
1562
  this.__wbg_ptr = 0;
1525
1563
  WasmReplayProtectionFinalization.unregister(this);
1526
1564
  return ptr;
1527
1565
  }
1528
-
1529
1566
  free() {
1530
1567
  const ptr = this.__destroy_into_raw();
1531
1568
  wasm.__wbg_wasmreplayprotection_free(ptr, 0);
@@ -1539,9 +1576,9 @@ export class WasmReplayProtection {
1539
1576
  static from_addresses(addresses, network) {
1540
1577
  try {
1541
1578
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1542
- const ptr0 = passArrayJsValueToWasm0(addresses, wasm.__wbindgen_export_1);
1579
+ const ptr0 = passArrayJsValueToWasm0(addresses, wasm.__wbindgen_export);
1543
1580
  const len0 = WASM_VECTOR_LEN;
1544
- const ptr1 = passStringToWasm0(network, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1581
+ const ptr1 = passStringToWasm0(network, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1545
1582
  const len1 = WASM_VECTOR_LEN;
1546
1583
  wasm.wasmreplayprotection_from_addresses(retptr, ptr0, len0, ptr1, len1);
1547
1584
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1563,7 +1600,7 @@ export class WasmReplayProtection {
1563
1600
  static from_public_keys(public_keys) {
1564
1601
  try {
1565
1602
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1566
- const ptr0 = passArrayJsValueToWasm0(public_keys, wasm.__wbindgen_export_1);
1603
+ const ptr0 = passArrayJsValueToWasm0(public_keys, wasm.__wbindgen_export);
1567
1604
  const len0 = WASM_VECTOR_LEN;
1568
1605
  wasm.wasmreplayprotection_from_public_keys(retptr, ptr0, len0);
1569
1606
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1583,7 +1620,7 @@ export class WasmReplayProtection {
1583
1620
  * @returns {WasmReplayProtection}
1584
1621
  */
1585
1622
  static from_output_scripts(output_scripts) {
1586
- const ptr0 = passArrayJsValueToWasm0(output_scripts, wasm.__wbindgen_export_1);
1623
+ const ptr0 = passArrayJsValueToWasm0(output_scripts, wasm.__wbindgen_export);
1587
1624
  const len0 = WASM_VECTOR_LEN;
1588
1625
  const ret = wasm.wasmreplayprotection_from_output_scripts(ptr0, len0);
1589
1626
  return WasmReplayProtection.__wrap(ret);
@@ -1591,15 +1628,11 @@ export class WasmReplayProtection {
1591
1628
  }
1592
1629
  if (Symbol.dispose) WasmReplayProtection.prototype[Symbol.dispose] = WasmReplayProtection.prototype.free;
1593
1630
 
1594
- const WasmRootWalletKeysFinalization = (typeof FinalizationRegistry === 'undefined')
1595
- ? { register: () => {}, unregister: () => {} }
1596
- : new FinalizationRegistry(ptr => wasm.__wbg_wasmrootwalletkeys_free(ptr >>> 0, 1));
1597
1631
  /**
1598
1632
  * WASM wrapper for RootWalletKeys
1599
1633
  * Represents a set of three extended public keys with their derivation prefixes
1600
1634
  */
1601
1635
  export class WasmRootWalletKeys {
1602
-
1603
1636
  static __wrap(ptr) {
1604
1637
  ptr = ptr >>> 0;
1605
1638
  const obj = Object.create(WasmRootWalletKeys.prototype);
@@ -1607,14 +1640,12 @@ export class WasmRootWalletKeys {
1607
1640
  WasmRootWalletKeysFinalization.register(obj, obj.__wbg_ptr, obj);
1608
1641
  return obj;
1609
1642
  }
1610
-
1611
1643
  __destroy_into_raw() {
1612
1644
  const ptr = this.__wbg_ptr;
1613
1645
  this.__wbg_ptr = 0;
1614
1646
  WasmRootWalletKeysFinalization.unregister(this);
1615
1647
  return ptr;
1616
1648
  }
1617
-
1618
1649
  free() {
1619
1650
  const ptr = this.__destroy_into_raw();
1620
1651
  wasm.__wbg_wasmrootwalletkeys_free(ptr, 0);
@@ -1651,11 +1682,11 @@ export class WasmRootWalletKeys {
1651
1682
  _assertClass(user, WasmBIP32);
1652
1683
  _assertClass(backup, WasmBIP32);
1653
1684
  _assertClass(bitgo, WasmBIP32);
1654
- const ptr0 = passStringToWasm0(user_derivation, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1685
+ const ptr0 = passStringToWasm0(user_derivation, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1655
1686
  const len0 = WASM_VECTOR_LEN;
1656
- const ptr1 = passStringToWasm0(backup_derivation, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1687
+ const ptr1 = passStringToWasm0(backup_derivation, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1657
1688
  const len1 = WASM_VECTOR_LEN;
1658
- const ptr2 = passStringToWasm0(bitgo_derivation, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1689
+ const ptr2 = passStringToWasm0(bitgo_derivation, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1659
1690
  const len2 = WASM_VECTOR_LEN;
1660
1691
  wasm.wasmrootwalletkeys_with_derivation_prefixes(retptr, user.__wbg_ptr, backup.__wbg_ptr, bitgo.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2);
1661
1692
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1720,12 +1751,7 @@ export class WasmRootWalletKeys {
1720
1751
  }
1721
1752
  if (Symbol.dispose) WasmRootWalletKeys.prototype[Symbol.dispose] = WasmRootWalletKeys.prototype.free;
1722
1753
 
1723
- const WrapDescriptorFinalization = (typeof FinalizationRegistry === 'undefined')
1724
- ? { register: () => {}, unregister: () => {} }
1725
- : new FinalizationRegistry(ptr => wasm.__wbg_wrapdescriptor_free(ptr >>> 0, 1));
1726
-
1727
1754
  export class WrapDescriptor {
1728
-
1729
1755
  static __wrap(ptr) {
1730
1756
  ptr = ptr >>> 0;
1731
1757
  const obj = Object.create(WrapDescriptor.prototype);
@@ -1733,14 +1759,12 @@ export class WrapDescriptor {
1733
1759
  WrapDescriptorFinalization.register(obj, obj.__wbg_ptr, obj);
1734
1760
  return obj;
1735
1761
  }
1736
-
1737
1762
  __destroy_into_raw() {
1738
1763
  const ptr = this.__wbg_ptr;
1739
1764
  this.__wbg_ptr = 0;
1740
1765
  WrapDescriptorFinalization.unregister(this);
1741
1766
  return ptr;
1742
1767
  }
1743
-
1744
1768
  free() {
1745
1769
  const ptr = this.__destroy_into_raw();
1746
1770
  wasm.__wbg_wrapdescriptor_free(ptr, 0);
@@ -1776,9 +1800,9 @@ export class WrapDescriptor {
1776
1800
  static fromString(descriptor, pk_type) {
1777
1801
  try {
1778
1802
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1779
- const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1803
+ const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1780
1804
  const len0 = WASM_VECTOR_LEN;
1781
- const ptr1 = passStringToWasm0(pk_type, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1805
+ const ptr1 = passStringToWasm0(pk_type, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1782
1806
  const len1 = WASM_VECTOR_LEN;
1783
1807
  wasm.wrapdescriptor_fromString(retptr, ptr0, len0, ptr1, len1);
1784
1808
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1814,7 +1838,7 @@ export class WrapDescriptor {
1814
1838
  throw takeObject(r2);
1815
1839
  }
1816
1840
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
1817
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
1841
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
1818
1842
  return v1;
1819
1843
  } finally {
1820
1844
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -1844,7 +1868,7 @@ export class WrapDescriptor {
1844
1868
  return getStringFromWasm0(ptr1, len1);
1845
1869
  } finally {
1846
1870
  wasm.__wbindgen_add_to_stack_pointer(16);
1847
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
1871
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
1848
1872
  }
1849
1873
  }
1850
1874
  /**
@@ -1914,7 +1938,7 @@ export class WrapDescriptor {
1914
1938
  static fromStringDetectType(descriptor) {
1915
1939
  try {
1916
1940
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1917
- const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
1941
+ const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1918
1942
  const len0 = WASM_VECTOR_LEN;
1919
1943
  wasm.wrapdescriptor_fromStringDetectType(retptr, ptr0, len0);
1920
1944
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -1961,7 +1985,7 @@ export class WrapDescriptor {
1961
1985
  throw takeObject(r2);
1962
1986
  }
1963
1987
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
1964
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
1988
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
1965
1989
  return v1;
1966
1990
  } finally {
1967
1991
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -2001,18 +2025,13 @@ export class WrapDescriptor {
2001
2025
  return getStringFromWasm0(r0, r1);
2002
2026
  } finally {
2003
2027
  wasm.__wbindgen_add_to_stack_pointer(16);
2004
- wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
2028
+ wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
2005
2029
  }
2006
2030
  }
2007
2031
  }
2008
2032
  if (Symbol.dispose) WrapDescriptor.prototype[Symbol.dispose] = WrapDescriptor.prototype.free;
2009
2033
 
2010
- const WrapMiniscriptFinalization = (typeof FinalizationRegistry === 'undefined')
2011
- ? { register: () => {}, unregister: () => {} }
2012
- : new FinalizationRegistry(ptr => wasm.__wbg_wrapminiscript_free(ptr >>> 0, 1));
2013
-
2014
2034
  export class WrapMiniscript {
2015
-
2016
2035
  static __wrap(ptr) {
2017
2036
  ptr = ptr >>> 0;
2018
2037
  const obj = Object.create(WrapMiniscript.prototype);
@@ -2020,14 +2039,12 @@ export class WrapMiniscript {
2020
2039
  WrapMiniscriptFinalization.register(obj, obj.__wbg_ptr, obj);
2021
2040
  return obj;
2022
2041
  }
2023
-
2024
2042
  __destroy_into_raw() {
2025
2043
  const ptr = this.__wbg_ptr;
2026
2044
  this.__wbg_ptr = 0;
2027
2045
  WrapMiniscriptFinalization.unregister(this);
2028
2046
  return ptr;
2029
2047
  }
2030
-
2031
2048
  free() {
2032
2049
  const ptr = this.__destroy_into_raw();
2033
2050
  wasm.__wbg_wrapminiscript_free(ptr, 0);
@@ -2040,9 +2057,9 @@ export class WrapMiniscript {
2040
2057
  static fromString(script, context_type) {
2041
2058
  try {
2042
2059
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
2043
- const ptr0 = passStringToWasm0(script, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
2060
+ const ptr0 = passStringToWasm0(script, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2044
2061
  const len0 = WASM_VECTOR_LEN;
2045
- const ptr1 = passStringToWasm0(context_type, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
2062
+ const ptr1 = passStringToWasm0(context_type, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2046
2063
  const len1 = WASM_VECTOR_LEN;
2047
2064
  wasm.wrapminiscript_fromString(retptr, ptr0, len0, ptr1, len1);
2048
2065
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -2080,7 +2097,7 @@ export class WrapMiniscript {
2080
2097
  return getStringFromWasm0(ptr1, len1);
2081
2098
  } finally {
2082
2099
  wasm.__wbindgen_add_to_stack_pointer(16);
2083
- wasm.__wbindgen_export_3(deferred2_0, deferred2_1, 1);
2100
+ wasm.__wbindgen_export4(deferred2_0, deferred2_1, 1);
2084
2101
  }
2085
2102
  }
2086
2103
  /**
@@ -2091,9 +2108,9 @@ export class WrapMiniscript {
2091
2108
  static fromBitcoinScript(script, context_type) {
2092
2109
  try {
2093
2110
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
2094
- const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export_1);
2111
+ const ptr0 = passArray8ToWasm0(script, wasm.__wbindgen_export);
2095
2112
  const len0 = WASM_VECTOR_LEN;
2096
- const ptr1 = passStringToWasm0(context_type, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
2113
+ const ptr1 = passStringToWasm0(context_type, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2097
2114
  const len1 = WASM_VECTOR_LEN;
2098
2115
  wasm.wrapminiscript_fromBitcoinScript(retptr, ptr0, len0, ptr1, len1);
2099
2116
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -2135,7 +2152,7 @@ export class WrapMiniscript {
2135
2152
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
2136
2153
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
2137
2154
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
2138
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
2155
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
2139
2156
  return v1;
2140
2157
  } finally {
2141
2158
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -2157,18 +2174,13 @@ export class WrapMiniscript {
2157
2174
  return getStringFromWasm0(r0, r1);
2158
2175
  } finally {
2159
2176
  wasm.__wbindgen_add_to_stack_pointer(16);
2160
- wasm.__wbindgen_export_3(deferred1_0, deferred1_1, 1);
2177
+ wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
2161
2178
  }
2162
2179
  }
2163
2180
  }
2164
2181
  if (Symbol.dispose) WrapMiniscript.prototype[Symbol.dispose] = WrapMiniscript.prototype.free;
2165
2182
 
2166
- const WrapPsbtFinalization = (typeof FinalizationRegistry === 'undefined')
2167
- ? { register: () => {}, unregister: () => {} }
2168
- : new FinalizationRegistry(ptr => wasm.__wbg_wrappsbt_free(ptr >>> 0, 1));
2169
-
2170
2183
  export class WrapPsbt {
2171
-
2172
2184
  static __wrap(ptr) {
2173
2185
  ptr = ptr >>> 0;
2174
2186
  const obj = Object.create(WrapPsbt.prototype);
@@ -2176,14 +2188,12 @@ export class WrapPsbt {
2176
2188
  WrapPsbtFinalization.register(obj, obj.__wbg_ptr, obj);
2177
2189
  return obj;
2178
2190
  }
2179
-
2180
2191
  __destroy_into_raw() {
2181
2192
  const ptr = this.__wbg_ptr;
2182
2193
  this.__wbg_ptr = 0;
2183
2194
  WrapPsbtFinalization.unregister(this);
2184
2195
  return ptr;
2185
2196
  }
2186
-
2187
2197
  free() {
2188
2198
  const ptr = this.__destroy_into_raw();
2189
2199
  wasm.__wbg_wrappsbt_free(ptr, 0);
@@ -2195,7 +2205,7 @@ export class WrapPsbt {
2195
2205
  static deserialize(psbt) {
2196
2206
  try {
2197
2207
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
2198
- const ptr0 = passArray8ToWasm0(psbt, wasm.__wbindgen_export_1);
2208
+ const ptr0 = passArray8ToWasm0(psbt, wasm.__wbindgen_export);
2199
2209
  const len0 = WASM_VECTOR_LEN;
2200
2210
  wasm.wrappsbt_deserialize(retptr, ptr0, len0);
2201
2211
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -2229,7 +2239,7 @@ export class WrapPsbt {
2229
2239
  signWithPrv(prv) {
2230
2240
  try {
2231
2241
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
2232
- const ptr0 = passArray8ToWasm0(prv, wasm.__wbindgen_export_1);
2242
+ const ptr0 = passArray8ToWasm0(prv, wasm.__wbindgen_export);
2233
2243
  const len0 = WASM_VECTOR_LEN;
2234
2244
  wasm.wrappsbt_signWithPrv(retptr, this.__wbg_ptr, ptr0, len0);
2235
2245
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -2250,7 +2260,7 @@ export class WrapPsbt {
2250
2260
  signWithXprv(xprv) {
2251
2261
  try {
2252
2262
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
2253
- const ptr0 = passStringToWasm0(xprv, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
2263
+ const ptr0 = passStringToWasm0(xprv, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2254
2264
  const len0 = WASM_VECTOR_LEN;
2255
2265
  wasm.wrappsbt_signWithXprv(retptr, this.__wbg_ptr, ptr0, len0);
2256
2266
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
@@ -2317,7 +2327,7 @@ export class WrapPsbt {
2317
2327
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
2318
2328
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
2319
2329
  var v1 = getArrayU8FromWasm0(r0, r1).slice();
2320
- wasm.__wbindgen_export_3(r0, r1 * 1, 1);
2330
+ wasm.__wbindgen_export4(r0, r1 * 1, 1);
2321
2331
  return v1;
2322
2332
  } finally {
2323
2333
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -2326,18 +2336,64 @@ export class WrapPsbt {
2326
2336
  }
2327
2337
  if (Symbol.dispose) WrapPsbt.prototype[Symbol.dispose] = WrapPsbt.prototype.free;
2328
2338
 
2329
- export function __wbg_Error_e17e777aac105295(arg0, arg1) {
2339
+ export function __wbg_Error_52673b7de5a0ca89(arg0, arg1) {
2330
2340
  const ret = Error(getStringFromWasm0(arg0, arg1));
2331
2341
  return addHeapObject(ret);
2332
2342
  };
2333
2343
 
2334
- export function __wbg_call_13410aac570ffff7() { return handleError(function (arg0, arg1) {
2335
- const ret = getObject(arg0).call(getObject(arg1));
2344
+ export function __wbg___wbindgen_is_function_8d400b8b1af978cd(arg0) {
2345
+ const ret = typeof(getObject(arg0)) === 'function';
2346
+ return ret;
2347
+ };
2348
+
2349
+ export function __wbg___wbindgen_is_null_dfda7d66506c95b5(arg0) {
2350
+ const ret = getObject(arg0) === null;
2351
+ return ret;
2352
+ };
2353
+
2354
+ export function __wbg___wbindgen_is_object_ce774f3490692386(arg0) {
2355
+ const val = getObject(arg0);
2356
+ const ret = typeof(val) === 'object' && val !== null;
2357
+ return ret;
2358
+ };
2359
+
2360
+ export function __wbg___wbindgen_is_string_704ef9c8fc131030(arg0) {
2361
+ const ret = typeof(getObject(arg0)) === 'string';
2362
+ return ret;
2363
+ };
2364
+
2365
+ export function __wbg___wbindgen_is_undefined_f6b95eab589e0269(arg0) {
2366
+ const ret = getObject(arg0) === undefined;
2367
+ return ret;
2368
+ };
2369
+
2370
+ export function __wbg___wbindgen_number_get_9619185a74197f95(arg0, arg1) {
2371
+ const obj = getObject(arg1);
2372
+ const ret = typeof(obj) === 'number' ? obj : undefined;
2373
+ getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
2374
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
2375
+ };
2376
+
2377
+ export function __wbg___wbindgen_string_get_a2a31e16edf96e42(arg0, arg1) {
2378
+ const obj = getObject(arg1);
2379
+ const ret = typeof(obj) === 'string' ? obj : undefined;
2380
+ var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2381
+ var len1 = WASM_VECTOR_LEN;
2382
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
2383
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2384
+ };
2385
+
2386
+ export function __wbg___wbindgen_throw_dd24417ed36fc46e(arg0, arg1) {
2387
+ throw new Error(getStringFromWasm0(arg0, arg1));
2388
+ };
2389
+
2390
+ export function __wbg_call_3020136f7a2d6e44() { return handleError(function (arg0, arg1, arg2) {
2391
+ const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
2336
2392
  return addHeapObject(ret);
2337
2393
  }, arguments) };
2338
2394
 
2339
- export function __wbg_call_a5400b25a865cfd8() { return handleError(function (arg0, arg1, arg2) {
2340
- const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
2395
+ export function __wbg_call_abb4ff46ce38be40() { return handleError(function (arg0, arg1) {
2396
+ const ret = getObject(arg0).call(getObject(arg1));
2341
2397
  return addHeapObject(ret);
2342
2398
  }, arguments) };
2343
2399
 
@@ -2350,12 +2406,12 @@ export function __wbg_getRandomValues_b8f5dbd5f3995a9e() { return handleError(fu
2350
2406
  getObject(arg0).getRandomValues(getObject(arg1));
2351
2407
  }, arguments) };
2352
2408
 
2353
- export function __wbg_get_458e874b43b18b25() { return handleError(function (arg0, arg1) {
2409
+ export function __wbg_get_af9dab7e9603ea93() { return handleError(function (arg0, arg1) {
2354
2410
  const ret = Reflect.get(getObject(arg0), getObject(arg1));
2355
2411
  return addHeapObject(ret);
2356
2412
  }, arguments) };
2357
2413
 
2358
- export function __wbg_length_6bb7e81f9d7713e4(arg0) {
2414
+ export function __wbg_length_22ac23eaec9d8053(arg0) {
2359
2415
  const ret = getObject(arg0).length;
2360
2416
  return ret;
2361
2417
  };
@@ -2365,37 +2421,37 @@ export function __wbg_msCrypto_a61aeb35a24c1329(arg0) {
2365
2421
  return addHeapObject(ret);
2366
2422
  };
2367
2423
 
2368
- export function __wbg_new_19c25a3f2fa63a02() {
2424
+ export function __wbg_new_1ba21ce319a06297() {
2369
2425
  const ret = new Object();
2370
2426
  return addHeapObject(ret);
2371
2427
  };
2372
2428
 
2373
- export function __wbg_new_1f3a344cf3123716() {
2429
+ export function __wbg_new_25f239778d6112b9() {
2374
2430
  const ret = new Array();
2375
2431
  return addHeapObject(ret);
2376
2432
  };
2377
2433
 
2378
- export function __wbg_new_638ebfaedbf32a5e(arg0) {
2434
+ export function __wbg_new_6421f6084cc5bc5a(arg0) {
2379
2435
  const ret = new Uint8Array(getObject(arg0));
2380
2436
  return addHeapObject(ret);
2381
2437
  };
2382
2438
 
2383
- export function __wbg_new_da9dc54c5db29dfa(arg0, arg1) {
2439
+ export function __wbg_new_df1173567d5ff028(arg0, arg1) {
2384
2440
  const ret = new Error(getStringFromWasm0(arg0, arg1));
2385
2441
  return addHeapObject(ret);
2386
2442
  };
2387
2443
 
2388
- export function __wbg_newfromslice_074c56947bd43469(arg0, arg1) {
2444
+ export function __wbg_new_from_slice_f9c22b9153b26992(arg0, arg1) {
2389
2445
  const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
2390
2446
  return addHeapObject(ret);
2391
2447
  };
2392
2448
 
2393
- export function __wbg_newnoargs_254190557c45b4ec(arg0, arg1) {
2449
+ export function __wbg_new_no_args_cb138f77cf6151ee(arg0, arg1) {
2394
2450
  const ret = new Function(getStringFromWasm0(arg0, arg1));
2395
2451
  return addHeapObject(ret);
2396
2452
  };
2397
2453
 
2398
- export function __wbg_newwithlength_a167dcc7aaa3ba77(arg0) {
2454
+ export function __wbg_new_with_length_aa5eaf41d35235e5(arg0) {
2399
2455
  const ret = new Uint8Array(arg0 >>> 0);
2400
2456
  return addHeapObject(ret);
2401
2457
  };
@@ -2410,11 +2466,11 @@ export function __wbg_process_dc0fbacc7c1c06f7(arg0) {
2410
2466
  return addHeapObject(ret);
2411
2467
  };
2412
2468
 
2413
- export function __wbg_prototypesetcall_3d4a26c1ed734349(arg0, arg1, arg2) {
2469
+ export function __wbg_prototypesetcall_dfe9b766cdc1f1fd(arg0, arg1, arg2) {
2414
2470
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
2415
2471
  };
2416
2472
 
2417
- export function __wbg_push_330b2eb93e4e1212(arg0, arg1) {
2473
+ export function __wbg_push_7d9be8f38fc13975(arg0, arg1) {
2418
2474
  const ret = getObject(arg0).push(getObject(arg1));
2419
2475
  return ret;
2420
2476
  };
@@ -2428,32 +2484,32 @@ export function __wbg_require_60cc747a6bc5215a() { return handleError(function (
2428
2484
  return addHeapObject(ret);
2429
2485
  }, arguments) };
2430
2486
 
2431
- export function __wbg_set_453345bcda80b89a() { return handleError(function (arg0, arg1, arg2) {
2487
+ export function __wbg_set_781438a03c0c3c81() { return handleError(function (arg0, arg1, arg2) {
2432
2488
  const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
2433
2489
  return ret;
2434
2490
  }, arguments) };
2435
2491
 
2436
- export function __wbg_static_accessor_GLOBAL_8921f820c2ce3f12() {
2492
+ export function __wbg_static_accessor_GLOBAL_769e6b65d6557335() {
2437
2493
  const ret = typeof global === 'undefined' ? null : global;
2438
2494
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2439
2495
  };
2440
2496
 
2441
- export function __wbg_static_accessor_GLOBAL_THIS_f0a4409105898184() {
2497
+ export function __wbg_static_accessor_GLOBAL_THIS_60cf02db4de8e1c1() {
2442
2498
  const ret = typeof globalThis === 'undefined' ? null : globalThis;
2443
2499
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2444
2500
  };
2445
2501
 
2446
- export function __wbg_static_accessor_SELF_995b214ae681ff99() {
2502
+ export function __wbg_static_accessor_SELF_08f5a74c69739274() {
2447
2503
  const ret = typeof self === 'undefined' ? null : self;
2448
2504
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2449
2505
  };
2450
2506
 
2451
- export function __wbg_static_accessor_WINDOW_cde3890479c675ea() {
2507
+ export function __wbg_static_accessor_WINDOW_a8924b26aa92d024() {
2452
2508
  const ret = typeof window === 'undefined' ? null : window;
2453
2509
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2454
2510
  };
2455
2511
 
2456
- export function __wbg_subarray_70fd07feefe14294(arg0, arg1, arg2) {
2512
+ export function __wbg_subarray_845f2f5bce7d061a(arg0, arg1, arg2) {
2457
2513
  const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);
2458
2514
  return addHeapObject(ret);
2459
2515
  };
@@ -2463,52 +2519,11 @@ export function __wbg_versions_c01dfd4722a88165(arg0) {
2463
2519
  return addHeapObject(ret);
2464
2520
  };
2465
2521
 
2466
- export function __wbg_wbindgenisfunction_8cee7dce3725ae74(arg0) {
2467
- const ret = typeof(getObject(arg0)) === 'function';
2468
- return ret;
2469
- };
2470
-
2471
- export function __wbg_wbindgenisnull_f3037694abe4d97a(arg0) {
2472
- const ret = getObject(arg0) === null;
2473
- return ret;
2474
- };
2475
-
2476
- export function __wbg_wbindgenisobject_307a53c6bd97fbf8(arg0) {
2477
- const val = getObject(arg0);
2478
- const ret = typeof(val) === 'object' && val !== null;
2479
- return ret;
2480
- };
2481
-
2482
- export function __wbg_wbindgenisstring_d4fa939789f003b0(arg0) {
2483
- const ret = typeof(getObject(arg0)) === 'string';
2484
- return ret;
2485
- };
2486
-
2487
- export function __wbg_wbindgenisundefined_c4b71d073b92f3c5(arg0) {
2488
- const ret = getObject(arg0) === undefined;
2522
+ export function __wbg_wasmecpair_unwrap(arg0) {
2523
+ const ret = WasmECPair.__unwrap(getObject(arg0));
2489
2524
  return ret;
2490
2525
  };
2491
2526
 
2492
- export function __wbg_wbindgennumberget_f74b4c7525ac05cb(arg0, arg1) {
2493
- const obj = getObject(arg1);
2494
- const ret = typeof(obj) === 'number' ? obj : undefined;
2495
- getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
2496
- getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
2497
- };
2498
-
2499
- export function __wbg_wbindgenstringget_0f16a6ddddef376f(arg0, arg1) {
2500
- const obj = getObject(arg1);
2501
- const ret = typeof(obj) === 'string' ? obj : undefined;
2502
- var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export_1, wasm.__wbindgen_export_2);
2503
- var len1 = WASM_VECTOR_LEN;
2504
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
2505
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2506
- };
2507
-
2508
- export function __wbg_wbindgenthrow_451ec1a8469d7eb6(arg0, arg1) {
2509
- throw new Error(getStringFromWasm0(arg0, arg1));
2510
- };
2511
-
2512
2527
  export function __wbindgen_cast_2241b6af4c4b2941(arg0, arg1) {
2513
2528
  // Cast intrinsic for `Ref(String) -> Externref`.
2514
2529
  const ret = getStringFromWasm0(arg0, arg1);
@@ -2541,4 +2556,3 @@ export function __wbindgen_object_clone_ref(arg0) {
2541
2556
  export function __wbindgen_object_drop_ref(arg0) {
2542
2557
  takeObject(arg0);
2543
2558
  };
2544
-