@premai/reticle 0.4.0 → 0.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/reticle.d.ts +101 -115
- package/reticle.js +2 -2
- package/reticle_bg.js +662 -663
- package/reticle_bg.wasm +0 -0
- package/reticle_main.js +677 -671
package/reticle_bg.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import { realFetch } from './snippets/reticle-f25e928bd9723d28/src/fetchShim.js';
|
|
2
|
+
|
|
3
|
+
|
|
1
4
|
export class AttestHeaders {
|
|
2
5
|
static __wrap(ptr) {
|
|
3
|
-
ptr = ptr >>> 0;
|
|
4
6
|
const obj = Object.create(AttestHeaders.prototype);
|
|
5
7
|
obj.__wbg_ptr = ptr;
|
|
6
8
|
AttestHeadersFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -35,7 +37,6 @@ if (Symbol.dispose) AttestHeaders.prototype[Symbol.dispose] = AttestHeaders.prot
|
|
|
35
37
|
|
|
36
38
|
export class AttestResult {
|
|
37
39
|
static __wrap(ptr) {
|
|
38
|
-
ptr = ptr >>> 0;
|
|
39
40
|
const obj = Object.create(AttestResult.prototype);
|
|
40
41
|
obj.__wbg_ptr = ptr;
|
|
41
42
|
AttestResultFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -68,9 +69,57 @@ export class AttestResult {
|
|
|
68
69
|
}
|
|
69
70
|
if (Symbol.dispose) AttestResult.prototype[Symbol.dispose] = AttestResult.prototype.free;
|
|
70
71
|
|
|
72
|
+
/**
|
|
73
|
+
* A parsed certificate revocation list
|
|
74
|
+
*/
|
|
75
|
+
export class CRL {
|
|
76
|
+
static __wrap(ptr) {
|
|
77
|
+
const obj = Object.create(CRL.prototype);
|
|
78
|
+
obj.__wbg_ptr = ptr;
|
|
79
|
+
CRLFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
80
|
+
return obj;
|
|
81
|
+
}
|
|
82
|
+
__destroy_into_raw() {
|
|
83
|
+
const ptr = this.__wbg_ptr;
|
|
84
|
+
this.__wbg_ptr = 0;
|
|
85
|
+
CRLFinalization.unregister(this);
|
|
86
|
+
return ptr;
|
|
87
|
+
}
|
|
88
|
+
free() {
|
|
89
|
+
const ptr = this.__destroy_into_raw();
|
|
90
|
+
wasm.__wbg_crl_free(ptr, 0);
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Passes if the certificates are not in the certificate revocation list
|
|
94
|
+
* Throws `AttestationError` on fail
|
|
95
|
+
* @param {VerifiedChain} chain
|
|
96
|
+
*/
|
|
97
|
+
check_chain(chain) {
|
|
98
|
+
_assertClass(chain, VerifiedChain);
|
|
99
|
+
const ret = wasm.crl_check_chain(this.__wbg_ptr, chain.__wbg_ptr);
|
|
100
|
+
if (ret[1]) {
|
|
101
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Parses a certificate revocation list from DER format binary data
|
|
106
|
+
* @param {Uint8Array} list
|
|
107
|
+
* @returns {CRL}
|
|
108
|
+
*/
|
|
109
|
+
static from_der(list) {
|
|
110
|
+
const ptr0 = passArray8ToWasm0(list, wasm.__wbindgen_malloc);
|
|
111
|
+
const len0 = WASM_VECTOR_LEN;
|
|
112
|
+
const ret = wasm.crl_from_der(ptr0, len0);
|
|
113
|
+
if (ret[2]) {
|
|
114
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
115
|
+
}
|
|
116
|
+
return CRL.__wrap(ret[0]);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
if (Symbol.dispose) CRL.prototype[Symbol.dispose] = CRL.prototype.free;
|
|
120
|
+
|
|
71
121
|
export class Client {
|
|
72
122
|
static __wrap(ptr) {
|
|
73
|
-
ptr = ptr >>> 0;
|
|
74
123
|
const obj = Object.create(Client.prototype);
|
|
75
124
|
obj.__wbg_ptr = ptr;
|
|
76
125
|
ClientFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -187,7 +236,6 @@ if (Symbol.dispose) Client.prototype[Symbol.dispose] = Client.prototype.free;
|
|
|
187
236
|
|
|
188
237
|
export class ClientBuilder {
|
|
189
238
|
static __wrap(ptr) {
|
|
190
|
-
ptr = ptr >>> 0;
|
|
191
239
|
const obj = Object.create(ClientBuilder.prototype);
|
|
192
240
|
obj.__wbg_ptr = ptr;
|
|
193
241
|
ClientBuilderFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -218,7 +266,7 @@ export class ClientBuilder {
|
|
|
218
266
|
const ptr0 = passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
219
267
|
const len0 = WASM_VECTOR_LEN;
|
|
220
268
|
const ret = wasm.clientbuilder_new(ptr0, len0);
|
|
221
|
-
this.__wbg_ptr = ret
|
|
269
|
+
this.__wbg_ptr = ret;
|
|
222
270
|
ClientBuilderFinalization.register(this, this.__wbg_ptr, this);
|
|
223
271
|
return this;
|
|
224
272
|
}
|
|
@@ -278,7 +326,6 @@ if (Symbol.dispose) ClientBuilder.prototype[Symbol.dispose] = ClientBuilder.prot
|
|
|
278
326
|
|
|
279
327
|
export class Collateral {
|
|
280
328
|
static __wrap(ptr) {
|
|
281
|
-
ptr = ptr >>> 0;
|
|
282
329
|
const obj = Object.create(Collateral.prototype);
|
|
283
330
|
obj.__wbg_ptr = ptr;
|
|
284
331
|
CollateralFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -305,9 +352,147 @@ export const CpuModule = Object.freeze({
|
|
|
305
352
|
Tdx: 1, "1": "Tdx",
|
|
306
353
|
});
|
|
307
354
|
|
|
355
|
+
export class DecodedClaims {
|
|
356
|
+
static __wrap(ptr) {
|
|
357
|
+
const obj = Object.create(DecodedClaims.prototype);
|
|
358
|
+
obj.__wbg_ptr = ptr;
|
|
359
|
+
DecodedClaimsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
360
|
+
return obj;
|
|
361
|
+
}
|
|
362
|
+
__destroy_into_raw() {
|
|
363
|
+
const ptr = this.__wbg_ptr;
|
|
364
|
+
this.__wbg_ptr = 0;
|
|
365
|
+
DecodedClaimsFinalization.unregister(this);
|
|
366
|
+
return ptr;
|
|
367
|
+
}
|
|
368
|
+
free() {
|
|
369
|
+
const ptr = this.__destroy_into_raw();
|
|
370
|
+
wasm.__wbg_decodedclaims_free(ptr, 0);
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
if (Symbol.dispose) DecodedClaims.prototype[Symbol.dispose] = DecodedClaims.prototype.free;
|
|
374
|
+
|
|
375
|
+
export class EATToken {
|
|
376
|
+
static __wrap(ptr) {
|
|
377
|
+
const obj = Object.create(EATToken.prototype);
|
|
378
|
+
obj.__wbg_ptr = ptr;
|
|
379
|
+
EATTokenFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
380
|
+
return obj;
|
|
381
|
+
}
|
|
382
|
+
__destroy_into_raw() {
|
|
383
|
+
const ptr = this.__wbg_ptr;
|
|
384
|
+
this.__wbg_ptr = 0;
|
|
385
|
+
EATTokenFinalization.unregister(this);
|
|
386
|
+
return ptr;
|
|
387
|
+
}
|
|
388
|
+
free() {
|
|
389
|
+
const ptr = this.__destroy_into_raw();
|
|
390
|
+
wasm.__wbg_eattoken_free(ptr, 0);
|
|
391
|
+
}
|
|
392
|
+
/**
|
|
393
|
+
* @param {string} from
|
|
394
|
+
* @returns {EATToken}
|
|
395
|
+
*/
|
|
396
|
+
static parse(from) {
|
|
397
|
+
const ptr0 = passStringToWasm0(from, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
398
|
+
const len0 = WASM_VECTOR_LEN;
|
|
399
|
+
const ret = wasm.eattoken_parse(ptr0, len0);
|
|
400
|
+
if (ret[2]) {
|
|
401
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
402
|
+
}
|
|
403
|
+
return EATToken.__wrap(ret[0]);
|
|
404
|
+
}
|
|
405
|
+
/**
|
|
406
|
+
* @param {KeyChain} keys
|
|
407
|
+
* @param {NvidiaNonce} nonce
|
|
408
|
+
* @returns {DecodedClaims}
|
|
409
|
+
*/
|
|
410
|
+
verify(keys, nonce) {
|
|
411
|
+
const ptr = this.__destroy_into_raw();
|
|
412
|
+
_assertClass(keys, KeyChain);
|
|
413
|
+
_assertClass(nonce, NvidiaNonce);
|
|
414
|
+
const ret = wasm.eattoken_verify(ptr, keys.__wbg_ptr, nonce.__wbg_ptr);
|
|
415
|
+
if (ret[2]) {
|
|
416
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
417
|
+
}
|
|
418
|
+
return DecodedClaims.__wrap(ret[0]);
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
if (Symbol.dispose) EATToken.prototype[Symbol.dispose] = EATToken.prototype.free;
|
|
422
|
+
|
|
423
|
+
export class ExportPem {
|
|
424
|
+
static __wrap(ptr) {
|
|
425
|
+
const obj = Object.create(ExportPem.prototype);
|
|
426
|
+
obj.__wbg_ptr = ptr;
|
|
427
|
+
ExportPemFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
428
|
+
return obj;
|
|
429
|
+
}
|
|
430
|
+
__destroy_into_raw() {
|
|
431
|
+
const ptr = this.__wbg_ptr;
|
|
432
|
+
this.__wbg_ptr = 0;
|
|
433
|
+
ExportPemFinalization.unregister(this);
|
|
434
|
+
return ptr;
|
|
435
|
+
}
|
|
436
|
+
free() {
|
|
437
|
+
const ptr = this.__destroy_into_raw();
|
|
438
|
+
wasm.__wbg_exportpem_free(ptr, 0);
|
|
439
|
+
}
|
|
440
|
+
/**
|
|
441
|
+
* @returns {Uint8Array}
|
|
442
|
+
*/
|
|
443
|
+
get ark() {
|
|
444
|
+
const ret = wasm.__wbg_get_exportpem_ark(this.__wbg_ptr);
|
|
445
|
+
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
446
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
447
|
+
return v1;
|
|
448
|
+
}
|
|
449
|
+
/**
|
|
450
|
+
* @returns {Uint8Array}
|
|
451
|
+
*/
|
|
452
|
+
get ask() {
|
|
453
|
+
const ret = wasm.__wbg_get_exportpem_ask(this.__wbg_ptr);
|
|
454
|
+
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
455
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
456
|
+
return v1;
|
|
457
|
+
}
|
|
458
|
+
/**
|
|
459
|
+
* @returns {Uint8Array}
|
|
460
|
+
*/
|
|
461
|
+
get vek() {
|
|
462
|
+
const ret = wasm.__wbg_get_exportpem_vek(this.__wbg_ptr);
|
|
463
|
+
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
464
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
465
|
+
return v1;
|
|
466
|
+
}
|
|
467
|
+
/**
|
|
468
|
+
* @param {Uint8Array} arg0
|
|
469
|
+
*/
|
|
470
|
+
set ark(arg0) {
|
|
471
|
+
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
472
|
+
const len0 = WASM_VECTOR_LEN;
|
|
473
|
+
wasm.__wbg_set_exportpem_ark(this.__wbg_ptr, ptr0, len0);
|
|
474
|
+
}
|
|
475
|
+
/**
|
|
476
|
+
* @param {Uint8Array} arg0
|
|
477
|
+
*/
|
|
478
|
+
set ask(arg0) {
|
|
479
|
+
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
480
|
+
const len0 = WASM_VECTOR_LEN;
|
|
481
|
+
wasm.__wbg_set_exportpem_ask(this.__wbg_ptr, ptr0, len0);
|
|
482
|
+
}
|
|
483
|
+
/**
|
|
484
|
+
* @param {Uint8Array} arg0
|
|
485
|
+
*/
|
|
486
|
+
set vek(arg0) {
|
|
487
|
+
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
488
|
+
const len0 = WASM_VECTOR_LEN;
|
|
489
|
+
wasm.__wbg_set_exportpem_vek(this.__wbg_ptr, ptr0, len0);
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
if (Symbol.dispose) ExportPem.prototype[Symbol.dispose] = ExportPem.prototype.free;
|
|
493
|
+
|
|
308
494
|
export class GatewayError {
|
|
309
495
|
static __wrap(ptr) {
|
|
310
|
-
ptr = ptr >>> 0;
|
|
311
496
|
const obj = Object.create(GatewayError.prototype);
|
|
312
497
|
obj.__wbg_ptr = ptr;
|
|
313
498
|
GatewayErrorFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -356,9 +541,75 @@ export const GpuModule = Object.freeze({
|
|
|
356
541
|
Nvidia: 0, "0": "Nvidia",
|
|
357
542
|
});
|
|
358
543
|
|
|
544
|
+
export class Kds {
|
|
545
|
+
__destroy_into_raw() {
|
|
546
|
+
const ptr = this.__wbg_ptr;
|
|
547
|
+
this.__wbg_ptr = 0;
|
|
548
|
+
KdsFinalization.unregister(this);
|
|
549
|
+
return ptr;
|
|
550
|
+
}
|
|
551
|
+
free() {
|
|
552
|
+
const ptr = this.__destroy_into_raw();
|
|
553
|
+
wasm.__wbg_kds_free(ptr, 0);
|
|
554
|
+
}
|
|
555
|
+
/**
|
|
556
|
+
* @param {ParsedAttestation} attestation
|
|
557
|
+
* @returns {Promise<VerifiedChain>}
|
|
558
|
+
*/
|
|
559
|
+
fetch_certificates(attestation) {
|
|
560
|
+
_assertClass(attestation, ParsedAttestation);
|
|
561
|
+
const ret = wasm.kds_fetch_certificates(this.__wbg_ptr, attestation.__wbg_ptr);
|
|
562
|
+
return ret;
|
|
563
|
+
}
|
|
564
|
+
/**
|
|
565
|
+
* Fetches the certificate revocation list from AMD's KDS
|
|
566
|
+
* @param {ParsedAttestation} attestation
|
|
567
|
+
* @returns {Promise<CRL>}
|
|
568
|
+
*/
|
|
569
|
+
fetch_crl(attestation) {
|
|
570
|
+
_assertClass(attestation, ParsedAttestation);
|
|
571
|
+
const ret = wasm.kds_fetch_crl(this.__wbg_ptr, attestation.__wbg_ptr);
|
|
572
|
+
return ret;
|
|
573
|
+
}
|
|
574
|
+
/**
|
|
575
|
+
* @param {string} cache_url
|
|
576
|
+
*/
|
|
577
|
+
constructor(cache_url) {
|
|
578
|
+
const ptr0 = passStringToWasm0(cache_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
579
|
+
const len0 = WASM_VECTOR_LEN;
|
|
580
|
+
const ret = wasm.kds_new(ptr0, len0);
|
|
581
|
+
if (ret[2]) {
|
|
582
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
583
|
+
}
|
|
584
|
+
this.__wbg_ptr = ret[0];
|
|
585
|
+
KdsFinalization.register(this, this.__wbg_ptr, this);
|
|
586
|
+
return this;
|
|
587
|
+
}
|
|
588
|
+
}
|
|
589
|
+
if (Symbol.dispose) Kds.prototype[Symbol.dispose] = Kds.prototype.free;
|
|
590
|
+
|
|
591
|
+
export class KeyChain {
|
|
592
|
+
static __wrap(ptr) {
|
|
593
|
+
const obj = Object.create(KeyChain.prototype);
|
|
594
|
+
obj.__wbg_ptr = ptr;
|
|
595
|
+
KeyChainFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
596
|
+
return obj;
|
|
597
|
+
}
|
|
598
|
+
__destroy_into_raw() {
|
|
599
|
+
const ptr = this.__wbg_ptr;
|
|
600
|
+
this.__wbg_ptr = 0;
|
|
601
|
+
KeyChainFinalization.unregister(this);
|
|
602
|
+
return ptr;
|
|
603
|
+
}
|
|
604
|
+
free() {
|
|
605
|
+
const ptr = this.__destroy_into_raw();
|
|
606
|
+
wasm.__wbg_keychain_free(ptr, 0);
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
if (Symbol.dispose) KeyChain.prototype[Symbol.dispose] = KeyChain.prototype.free;
|
|
610
|
+
|
|
359
611
|
export class Modules {
|
|
360
612
|
static __wrap(ptr) {
|
|
361
|
-
ptr = ptr >>> 0;
|
|
362
613
|
const obj = Object.create(Modules.prototype);
|
|
363
614
|
obj.__wbg_ptr = ptr;
|
|
364
615
|
ModulesFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -400,7 +651,6 @@ if (Symbol.dispose) Modules.prototype[Symbol.dispose] = Modules.prototype.free;
|
|
|
400
651
|
|
|
401
652
|
export class NvidiaAttestResult {
|
|
402
653
|
static __wrap(ptr) {
|
|
403
|
-
ptr = ptr >>> 0;
|
|
404
654
|
const obj = Object.create(NvidiaAttestResult.prototype);
|
|
405
655
|
obj.__wbg_ptr = ptr;
|
|
406
656
|
NvidiaAttestResultFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -419,205 +669,29 @@ export class NvidiaAttestResult {
|
|
|
419
669
|
}
|
|
420
670
|
if (Symbol.dispose) NvidiaAttestResult.prototype[Symbol.dispose] = NvidiaAttestResult.prototype.free;
|
|
421
671
|
|
|
422
|
-
export class
|
|
672
|
+
export class NvidiaNonce {
|
|
673
|
+
static __wrap(ptr) {
|
|
674
|
+
const obj = Object.create(NvidiaNonce.prototype);
|
|
675
|
+
obj.__wbg_ptr = ptr;
|
|
676
|
+
NvidiaNonceFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
677
|
+
return obj;
|
|
678
|
+
}
|
|
423
679
|
__destroy_into_raw() {
|
|
424
680
|
const ptr = this.__wbg_ptr;
|
|
425
681
|
this.__wbg_ptr = 0;
|
|
426
|
-
|
|
682
|
+
NvidiaNonceFinalization.unregister(this);
|
|
427
683
|
return ptr;
|
|
428
684
|
}
|
|
429
685
|
free() {
|
|
430
686
|
const ptr = this.__destroy_into_raw();
|
|
431
|
-
wasm.
|
|
687
|
+
wasm.__wbg_nvidianonce_free(ptr, 0);
|
|
432
688
|
}
|
|
433
689
|
/**
|
|
434
|
-
* @
|
|
435
|
-
* @returns {Promise<Collateral>}
|
|
690
|
+
* @returns {NvidiaNonce}
|
|
436
691
|
*/
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
return ret;
|
|
441
|
-
}
|
|
442
|
-
/**
|
|
443
|
-
* @param {string} base_url
|
|
444
|
-
*/
|
|
445
|
-
constructor(base_url) {
|
|
446
|
-
const ptr0 = passStringToWasm0(base_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
447
|
-
const len0 = WASM_VECTOR_LEN;
|
|
448
|
-
const ret = wasm.pcs_new(ptr0, len0);
|
|
449
|
-
if (ret[2]) {
|
|
450
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
451
|
-
}
|
|
452
|
-
this.__wbg_ptr = ret[0] >>> 0;
|
|
453
|
-
PcsFinalization.register(this, this.__wbg_ptr, this);
|
|
454
|
-
return this;
|
|
455
|
-
}
|
|
456
|
-
}
|
|
457
|
-
if (Symbol.dispose) Pcs.prototype[Symbol.dispose] = Pcs.prototype.free;
|
|
458
|
-
|
|
459
|
-
/**
|
|
460
|
-
* Generic per-request query parameters.
|
|
461
|
-
*
|
|
462
|
-
* The `nonce` key is reserved and will be rejected.
|
|
463
|
-
*/
|
|
464
|
-
export class QueryParams {
|
|
465
|
-
static __wrap(ptr) {
|
|
466
|
-
ptr = ptr >>> 0;
|
|
467
|
-
const obj = Object.create(QueryParams.prototype);
|
|
468
|
-
obj.__wbg_ptr = ptr;
|
|
469
|
-
QueryParamsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
470
|
-
return obj;
|
|
471
|
-
}
|
|
472
|
-
__destroy_into_raw() {
|
|
473
|
-
const ptr = this.__wbg_ptr;
|
|
474
|
-
this.__wbg_ptr = 0;
|
|
475
|
-
QueryParamsFinalization.unregister(this);
|
|
476
|
-
return ptr;
|
|
477
|
-
}
|
|
478
|
-
free() {
|
|
479
|
-
const ptr = this.__destroy_into_raw();
|
|
480
|
-
wasm.__wbg_queryparams_free(ptr, 0);
|
|
481
|
-
}
|
|
482
|
-
constructor() {
|
|
483
|
-
const ret = wasm.queryparams_new();
|
|
484
|
-
this.__wbg_ptr = ret >>> 0;
|
|
485
|
-
QueryParamsFinalization.register(this, this.__wbg_ptr, this);
|
|
486
|
-
return this;
|
|
487
|
-
}
|
|
488
|
-
/**
|
|
489
|
-
* Appends a query parameter.
|
|
490
|
-
*
|
|
491
|
-
* Reserved keywords for specific queries will get overwritten
|
|
492
|
-
* @param {string} key
|
|
493
|
-
* @param {string} value
|
|
494
|
-
* @returns {QueryParams}
|
|
495
|
-
*/
|
|
496
|
-
with(key, value) {
|
|
497
|
-
const ptr = this.__destroy_into_raw();
|
|
498
|
-
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
499
|
-
const len0 = WASM_VECTOR_LEN;
|
|
500
|
-
const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
501
|
-
const len1 = WASM_VECTOR_LEN;
|
|
502
|
-
const ret = wasm.queryparams_with(ptr, ptr0, len0, ptr1, len1);
|
|
503
|
-
return QueryParams.__wrap(ret);
|
|
504
|
-
}
|
|
505
|
-
}
|
|
506
|
-
if (Symbol.dispose) QueryParams.prototype[Symbol.dispose] = QueryParams.prototype.free;
|
|
507
|
-
|
|
508
|
-
export class QuoteVerifier {
|
|
509
|
-
__destroy_into_raw() {
|
|
510
|
-
const ptr = this.__wbg_ptr;
|
|
511
|
-
this.__wbg_ptr = 0;
|
|
512
|
-
QuoteVerifierFinalization.unregister(this);
|
|
513
|
-
return ptr;
|
|
514
|
-
}
|
|
515
|
-
free() {
|
|
516
|
-
const ptr = this.__destroy_into_raw();
|
|
517
|
-
wasm.__wbg_quoteverifier_free(ptr, 0);
|
|
518
|
-
}
|
|
519
|
-
/**
|
|
520
|
-
* @param {Collateral} collateral
|
|
521
|
-
* @param {TdxQuote} quote
|
|
522
|
-
*/
|
|
523
|
-
constructor(collateral, quote) {
|
|
524
|
-
_assertClass(collateral, Collateral);
|
|
525
|
-
var ptr0 = collateral.__destroy_into_raw();
|
|
526
|
-
_assertClass(quote, TdxQuote);
|
|
527
|
-
var ptr1 = quote.__destroy_into_raw();
|
|
528
|
-
const ret = wasm.quoteverifier_new(ptr0, ptr1);
|
|
529
|
-
this.__wbg_ptr = ret >>> 0;
|
|
530
|
-
QuoteVerifierFinalization.register(this, this.__wbg_ptr, this);
|
|
531
|
-
return this;
|
|
532
|
-
}
|
|
533
|
-
/**
|
|
534
|
-
* @param {TdxNonce} nonce
|
|
535
|
-
*/
|
|
536
|
-
verify(nonce) {
|
|
537
|
-
_assertClass(nonce, TdxNonce);
|
|
538
|
-
const ret = wasm.quoteverifier_verify(this.__wbg_ptr, nonce.__wbg_ptr);
|
|
539
|
-
if (ret[1]) {
|
|
540
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
541
|
-
}
|
|
542
|
-
}
|
|
543
|
-
}
|
|
544
|
-
if (Symbol.dispose) QuoteVerifier.prototype[Symbol.dispose] = QuoteVerifier.prototype.free;
|
|
545
|
-
|
|
546
|
-
export class ResponseHeaders {
|
|
547
|
-
static __wrap(ptr) {
|
|
548
|
-
ptr = ptr >>> 0;
|
|
549
|
-
const obj = Object.create(ResponseHeaders.prototype);
|
|
550
|
-
obj.__wbg_ptr = ptr;
|
|
551
|
-
ResponseHeadersFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
552
|
-
return obj;
|
|
553
|
-
}
|
|
554
|
-
__destroy_into_raw() {
|
|
555
|
-
const ptr = this.__wbg_ptr;
|
|
556
|
-
this.__wbg_ptr = 0;
|
|
557
|
-
ResponseHeadersFinalization.unregister(this);
|
|
558
|
-
return ptr;
|
|
559
|
-
}
|
|
560
|
-
free() {
|
|
561
|
-
const ptr = this.__destroy_into_raw();
|
|
562
|
-
wasm.__wbg_responseheaders_free(ptr, 0);
|
|
563
|
-
}
|
|
564
|
-
/**
|
|
565
|
-
* @param {string} name
|
|
566
|
-
* @returns {string | undefined}
|
|
567
|
-
*/
|
|
568
|
-
get(name) {
|
|
569
|
-
const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
570
|
-
const len0 = WASM_VECTOR_LEN;
|
|
571
|
-
const ret = wasm.responseheaders_get(this.__wbg_ptr, ptr0, len0);
|
|
572
|
-
let v2;
|
|
573
|
-
if (ret[0] !== 0) {
|
|
574
|
-
v2 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
575
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
576
|
-
}
|
|
577
|
-
return v2;
|
|
578
|
-
}
|
|
579
|
-
/**
|
|
580
|
-
* @returns {string[]}
|
|
581
|
-
*/
|
|
582
|
-
keys() {
|
|
583
|
-
const ret = wasm.responseheaders_keys(this.__wbg_ptr);
|
|
584
|
-
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
585
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
586
|
-
return v1;
|
|
587
|
-
}
|
|
588
|
-
}
|
|
589
|
-
if (Symbol.dispose) ResponseHeaders.prototype[Symbol.dispose] = ResponseHeaders.prototype.free;
|
|
590
|
-
|
|
591
|
-
export class TcbLevels {
|
|
592
|
-
__destroy_into_raw() {
|
|
593
|
-
const ptr = this.__wbg_ptr;
|
|
594
|
-
this.__wbg_ptr = 0;
|
|
595
|
-
TcbLevelsFinalization.unregister(this);
|
|
596
|
-
return ptr;
|
|
597
|
-
}
|
|
598
|
-
free() {
|
|
599
|
-
const ptr = this.__destroy_into_raw();
|
|
600
|
-
wasm.__wbg_tcblevels_free(ptr, 0);
|
|
601
|
-
}
|
|
602
|
-
}
|
|
603
|
-
if (Symbol.dispose) TcbLevels.prototype[Symbol.dispose] = TcbLevels.prototype.free;
|
|
604
|
-
|
|
605
|
-
export class TdxNonce {
|
|
606
|
-
__destroy_into_raw() {
|
|
607
|
-
const ptr = this.__wbg_ptr;
|
|
608
|
-
this.__wbg_ptr = 0;
|
|
609
|
-
TdxNonceFinalization.unregister(this);
|
|
610
|
-
return ptr;
|
|
611
|
-
}
|
|
612
|
-
free() {
|
|
613
|
-
const ptr = this.__destroy_into_raw();
|
|
614
|
-
wasm.__wbg_tdxnonce_free(ptr, 0);
|
|
615
|
-
}
|
|
616
|
-
constructor() {
|
|
617
|
-
const ret = wasm.tdxnonce_generate();
|
|
618
|
-
this.__wbg_ptr = ret >>> 0;
|
|
619
|
-
TdxNonceFinalization.register(this, this.__wbg_ptr, this);
|
|
620
|
-
return this;
|
|
692
|
+
static generate() {
|
|
693
|
+
const ret = wasm.nvidianonce_generate();
|
|
694
|
+
return NvidiaNonce.__wrap(ret);
|
|
621
695
|
}
|
|
622
696
|
/**
|
|
623
697
|
* @returns {string}
|
|
@@ -626,7 +700,7 @@ export class TdxNonce {
|
|
|
626
700
|
let deferred1_0;
|
|
627
701
|
let deferred1_1;
|
|
628
702
|
try {
|
|
629
|
-
const ret = wasm.
|
|
703
|
+
const ret = wasm.nvidianonce_to_hex(this.__wbg_ptr);
|
|
630
704
|
deferred1_0 = ret[0];
|
|
631
705
|
deferred1_1 = ret[1];
|
|
632
706
|
return getStringFromWasm0(ret[0], ret[1]);
|
|
@@ -635,431 +709,242 @@ export class TdxNonce {
|
|
|
635
709
|
}
|
|
636
710
|
}
|
|
637
711
|
}
|
|
638
|
-
if (Symbol.dispose)
|
|
712
|
+
if (Symbol.dispose) NvidiaNonce.prototype[Symbol.dispose] = NvidiaNonce.prototype.free;
|
|
639
713
|
|
|
640
|
-
|
|
714
|
+
/**
|
|
715
|
+
* Represents a parsed attestation report with some already
|
|
716
|
+
* parsed commonly accessed fields
|
|
717
|
+
*/
|
|
718
|
+
export class ParsedAttestation {
|
|
641
719
|
static __wrap(ptr) {
|
|
642
|
-
|
|
643
|
-
const obj = Object.create(TdxQuote.prototype);
|
|
720
|
+
const obj = Object.create(ParsedAttestation.prototype);
|
|
644
721
|
obj.__wbg_ptr = ptr;
|
|
645
|
-
|
|
722
|
+
ParsedAttestationFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
646
723
|
return obj;
|
|
647
724
|
}
|
|
648
725
|
__destroy_into_raw() {
|
|
649
726
|
const ptr = this.__wbg_ptr;
|
|
650
727
|
this.__wbg_ptr = 0;
|
|
651
|
-
|
|
728
|
+
ParsedAttestationFinalization.unregister(this);
|
|
652
729
|
return ptr;
|
|
653
730
|
}
|
|
654
731
|
free() {
|
|
655
732
|
const ptr = this.__destroy_into_raw();
|
|
656
|
-
wasm.
|
|
733
|
+
wasm.__wbg_parsedattestation_free(ptr, 0);
|
|
657
734
|
}
|
|
658
735
|
/**
|
|
659
|
-
*
|
|
660
|
-
* @param {Uint8Array} quote
|
|
661
|
-
* @returns {TdxQuote}
|
|
736
|
+
* @returns {number}
|
|
662
737
|
*/
|
|
663
|
-
|
|
664
|
-
const
|
|
665
|
-
|
|
666
|
-
const ret = wasm.tdxquote_from_bytes(ptr0, len0);
|
|
667
|
-
if (ret[2]) {
|
|
668
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
669
|
-
}
|
|
670
|
-
return TdxQuote.__wrap(ret[0]);
|
|
671
|
-
}
|
|
672
|
-
}
|
|
673
|
-
if (Symbol.dispose) TdxQuote.prototype[Symbol.dispose] = TdxQuote.prototype.free;
|
|
674
|
-
|
|
675
|
-
class DecodedClaims {
|
|
676
|
-
static __wrap(ptr) {
|
|
677
|
-
ptr = ptr >>> 0;
|
|
678
|
-
const obj = Object.create(DecodedClaims.prototype);
|
|
679
|
-
obj.__wbg_ptr = ptr;
|
|
680
|
-
DecodedClaimsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
681
|
-
return obj;
|
|
682
|
-
}
|
|
683
|
-
__destroy_into_raw() {
|
|
684
|
-
const ptr = this.__wbg_ptr;
|
|
685
|
-
this.__wbg_ptr = 0;
|
|
686
|
-
DecodedClaimsFinalization.unregister(this);
|
|
687
|
-
return ptr;
|
|
688
|
-
}
|
|
689
|
-
free() {
|
|
690
|
-
const ptr = this.__destroy_into_raw();
|
|
691
|
-
wasm.__wbg_nvidia__decodedclaims_free(ptr, 0);
|
|
692
|
-
}
|
|
693
|
-
}
|
|
694
|
-
if (Symbol.dispose) DecodedClaims.prototype[Symbol.dispose] = DecodedClaims.prototype.free;
|
|
695
|
-
|
|
696
|
-
class EATToken {
|
|
697
|
-
static __wrap(ptr) {
|
|
698
|
-
ptr = ptr >>> 0;
|
|
699
|
-
const obj = Object.create(EATToken.prototype);
|
|
700
|
-
obj.__wbg_ptr = ptr;
|
|
701
|
-
EATTokenFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
702
|
-
return obj;
|
|
703
|
-
}
|
|
704
|
-
__destroy_into_raw() {
|
|
705
|
-
const ptr = this.__wbg_ptr;
|
|
706
|
-
this.__wbg_ptr = 0;
|
|
707
|
-
EATTokenFinalization.unregister(this);
|
|
708
|
-
return ptr;
|
|
709
|
-
}
|
|
710
|
-
free() {
|
|
711
|
-
const ptr = this.__destroy_into_raw();
|
|
712
|
-
wasm.__wbg_nvidia__eattoken_free(ptr, 0);
|
|
738
|
+
cpu_fam_id() {
|
|
739
|
+
const ret = wasm.parsedattestation_cpu_fam_id(this.__wbg_ptr);
|
|
740
|
+
return ret;
|
|
713
741
|
}
|
|
714
742
|
/**
|
|
715
|
-
* @
|
|
716
|
-
* @returns {EATToken}
|
|
743
|
+
* @returns {number}
|
|
717
744
|
*/
|
|
718
|
-
|
|
719
|
-
const
|
|
720
|
-
|
|
721
|
-
const ret = wasm.eattoken_parse(ptr0, len0);
|
|
722
|
-
if (ret[2]) {
|
|
723
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
724
|
-
}
|
|
725
|
-
return EATToken.__wrap(ret[0]);
|
|
745
|
+
cpu_mod_id() {
|
|
746
|
+
const ret = wasm.parsedattestation_cpu_mod_id(this.__wbg_ptr);
|
|
747
|
+
return ret;
|
|
726
748
|
}
|
|
727
749
|
/**
|
|
728
|
-
*
|
|
729
|
-
* @param {
|
|
730
|
-
* @returns {
|
|
750
|
+
* Parses and constructs a new attestation report from a stream of binary data
|
|
751
|
+
* @param {Uint8Array} bytes
|
|
752
|
+
* @returns {ParsedAttestation}
|
|
731
753
|
*/
|
|
732
|
-
|
|
733
|
-
const
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
const ret = wasm.eattoken_verify(ptr, keys.__wbg_ptr, nonce.__wbg_ptr);
|
|
754
|
+
static new(bytes) {
|
|
755
|
+
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);
|
|
756
|
+
const len0 = WASM_VECTOR_LEN;
|
|
757
|
+
const ret = wasm.parsedattestation_new(ptr0, len0);
|
|
737
758
|
if (ret[2]) {
|
|
738
759
|
throw takeFromExternrefTable0(ret[1]);
|
|
739
760
|
}
|
|
740
|
-
return
|
|
741
|
-
}
|
|
742
|
-
}
|
|
743
|
-
if (Symbol.dispose) EATToken.prototype[Symbol.dispose] = EATToken.prototype.free;
|
|
744
|
-
|
|
745
|
-
class KeyChain {
|
|
746
|
-
static __wrap(ptr) {
|
|
747
|
-
ptr = ptr >>> 0;
|
|
748
|
-
const obj = Object.create(KeyChain.prototype);
|
|
749
|
-
obj.__wbg_ptr = ptr;
|
|
750
|
-
KeyChainFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
751
|
-
return obj;
|
|
752
|
-
}
|
|
753
|
-
__destroy_into_raw() {
|
|
754
|
-
const ptr = this.__wbg_ptr;
|
|
755
|
-
this.__wbg_ptr = 0;
|
|
756
|
-
KeyChainFinalization.unregister(this);
|
|
757
|
-
return ptr;
|
|
758
|
-
}
|
|
759
|
-
free() {
|
|
760
|
-
const ptr = this.__destroy_into_raw();
|
|
761
|
-
wasm.__wbg_nvidia__keychain_free(ptr, 0);
|
|
762
|
-
}
|
|
763
|
-
}
|
|
764
|
-
if (Symbol.dispose) KeyChain.prototype[Symbol.dispose] = KeyChain.prototype.free;
|
|
765
|
-
|
|
766
|
-
class NvidiaNonce {
|
|
767
|
-
static __wrap(ptr) {
|
|
768
|
-
ptr = ptr >>> 0;
|
|
769
|
-
const obj = Object.create(NvidiaNonce.prototype);
|
|
770
|
-
obj.__wbg_ptr = ptr;
|
|
771
|
-
NvidiaNonceFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
772
|
-
return obj;
|
|
773
|
-
}
|
|
774
|
-
__destroy_into_raw() {
|
|
775
|
-
const ptr = this.__wbg_ptr;
|
|
776
|
-
this.__wbg_ptr = 0;
|
|
777
|
-
NvidiaNonceFinalization.unregister(this);
|
|
778
|
-
return ptr;
|
|
779
|
-
}
|
|
780
|
-
free() {
|
|
781
|
-
const ptr = this.__destroy_into_raw();
|
|
782
|
-
wasm.__wbg_nvidia__nvidianonce_free(ptr, 0);
|
|
783
|
-
}
|
|
784
|
-
/**
|
|
785
|
-
* @returns {NvidiaNonce}
|
|
786
|
-
*/
|
|
787
|
-
static generate() {
|
|
788
|
-
const ret = wasm.nvidianonce_generate();
|
|
789
|
-
return NvidiaNonce.__wrap(ret);
|
|
761
|
+
return ParsedAttestation.__wrap(ret[0]);
|
|
790
762
|
}
|
|
791
763
|
/**
|
|
792
|
-
*
|
|
764
|
+
* Verifies the attestation report against a certificate chain
|
|
765
|
+
* @param {VerifiedChain} chain
|
|
766
|
+
* @param {SevNonce} nonce
|
|
793
767
|
*/
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
deferred1_1 = ret[1];
|
|
801
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
802
|
-
} finally {
|
|
803
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
768
|
+
verify(chain, nonce) {
|
|
769
|
+
_assertClass(chain, VerifiedChain);
|
|
770
|
+
_assertClass(nonce, SevNonce);
|
|
771
|
+
const ret = wasm.parsedattestation_verify(this.__wbg_ptr, chain.__wbg_ptr, nonce.__wbg_ptr);
|
|
772
|
+
if (ret[1]) {
|
|
773
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
804
774
|
}
|
|
805
775
|
}
|
|
806
776
|
}
|
|
807
|
-
if (Symbol.dispose)
|
|
808
|
-
|
|
809
|
-
/**
|
|
810
|
-
* Same as [`KeyChain:fetch_keychain`], put in for better wasm compatibility
|
|
811
|
-
* @returns {Promise<KeyChain>}
|
|
812
|
-
*/
|
|
813
|
-
function fetch_keychain() {
|
|
814
|
-
const ret = wasm.nvidia__fetch_keychain();
|
|
815
|
-
return ret;
|
|
816
|
-
}
|
|
817
|
-
|
|
818
|
-
export const nvidia = {};
|
|
819
|
-
nvidia.DecodedClaims = DecodedClaims;
|
|
820
|
-
nvidia.EATToken = EATToken;
|
|
821
|
-
nvidia.KeyChain = KeyChain;
|
|
822
|
-
nvidia.NvidiaNonce = NvidiaNonce;
|
|
823
|
-
nvidia.fetch_keychain = fetch_keychain;
|
|
777
|
+
if (Symbol.dispose) ParsedAttestation.prototype[Symbol.dispose] = ParsedAttestation.prototype.free;
|
|
824
778
|
|
|
825
|
-
|
|
826
|
-
* A parsed certificate revocation list
|
|
827
|
-
*/
|
|
828
|
-
class CRL {
|
|
829
|
-
static __wrap(ptr) {
|
|
830
|
-
ptr = ptr >>> 0;
|
|
831
|
-
const obj = Object.create(CRL.prototype);
|
|
832
|
-
obj.__wbg_ptr = ptr;
|
|
833
|
-
CRLFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
834
|
-
return obj;
|
|
835
|
-
}
|
|
779
|
+
export class Pcs {
|
|
836
780
|
__destroy_into_raw() {
|
|
837
781
|
const ptr = this.__wbg_ptr;
|
|
838
782
|
this.__wbg_ptr = 0;
|
|
839
|
-
|
|
783
|
+
PcsFinalization.unregister(this);
|
|
840
784
|
return ptr;
|
|
841
785
|
}
|
|
842
786
|
free() {
|
|
843
787
|
const ptr = this.__destroy_into_raw();
|
|
844
|
-
wasm.
|
|
788
|
+
wasm.__wbg_pcs_free(ptr, 0);
|
|
845
789
|
}
|
|
846
790
|
/**
|
|
847
|
-
*
|
|
848
|
-
*
|
|
849
|
-
* @param {VerifiedChain} chain
|
|
791
|
+
* @param {TdxQuote} quote
|
|
792
|
+
* @returns {Promise<Collateral>}
|
|
850
793
|
*/
|
|
851
|
-
|
|
852
|
-
_assertClass(
|
|
853
|
-
const ret = wasm.
|
|
854
|
-
|
|
855
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
856
|
-
}
|
|
794
|
+
fetch_collateral(quote) {
|
|
795
|
+
_assertClass(quote, TdxQuote);
|
|
796
|
+
const ret = wasm.pcs_fetch_collateral(this.__wbg_ptr, quote.__wbg_ptr);
|
|
797
|
+
return ret;
|
|
857
798
|
}
|
|
858
799
|
/**
|
|
859
|
-
*
|
|
860
|
-
* @param {Uint8Array} list
|
|
861
|
-
* @returns {CRL}
|
|
800
|
+
* @param {string} base_url
|
|
862
801
|
*/
|
|
863
|
-
|
|
864
|
-
const ptr0 =
|
|
802
|
+
constructor(base_url) {
|
|
803
|
+
const ptr0 = passStringToWasm0(base_url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
865
804
|
const len0 = WASM_VECTOR_LEN;
|
|
866
|
-
const ret = wasm.
|
|
805
|
+
const ret = wasm.pcs_new(ptr0, len0);
|
|
867
806
|
if (ret[2]) {
|
|
868
807
|
throw takeFromExternrefTable0(ret[1]);
|
|
869
808
|
}
|
|
870
|
-
|
|
809
|
+
this.__wbg_ptr = ret[0];
|
|
810
|
+
PcsFinalization.register(this, this.__wbg_ptr, this);
|
|
811
|
+
return this;
|
|
871
812
|
}
|
|
872
813
|
}
|
|
873
|
-
if (Symbol.dispose)
|
|
814
|
+
if (Symbol.dispose) Pcs.prototype[Symbol.dispose] = Pcs.prototype.free;
|
|
874
815
|
|
|
875
|
-
|
|
816
|
+
/**
|
|
817
|
+
* Generic per-request query parameters.
|
|
818
|
+
*
|
|
819
|
+
* The `nonce` key is reserved and will be rejected.
|
|
820
|
+
*/
|
|
821
|
+
export class QueryParams {
|
|
876
822
|
static __wrap(ptr) {
|
|
877
|
-
|
|
878
|
-
const obj = Object.create(ExportPem.prototype);
|
|
823
|
+
const obj = Object.create(QueryParams.prototype);
|
|
879
824
|
obj.__wbg_ptr = ptr;
|
|
880
|
-
|
|
825
|
+
QueryParamsFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
881
826
|
return obj;
|
|
882
827
|
}
|
|
883
828
|
__destroy_into_raw() {
|
|
884
829
|
const ptr = this.__wbg_ptr;
|
|
885
830
|
this.__wbg_ptr = 0;
|
|
886
|
-
|
|
831
|
+
QueryParamsFinalization.unregister(this);
|
|
887
832
|
return ptr;
|
|
888
833
|
}
|
|
889
834
|
free() {
|
|
890
835
|
const ptr = this.__destroy_into_raw();
|
|
891
|
-
wasm.
|
|
892
|
-
}
|
|
893
|
-
/**
|
|
894
|
-
* @returns {Uint8Array}
|
|
895
|
-
*/
|
|
896
|
-
get ark() {
|
|
897
|
-
const ret = wasm.__wbg_get_sev__exportpem_ark(this.__wbg_ptr);
|
|
898
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
899
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
900
|
-
return v1;
|
|
901
|
-
}
|
|
902
|
-
/**
|
|
903
|
-
* @returns {Uint8Array}
|
|
904
|
-
*/
|
|
905
|
-
get ask() {
|
|
906
|
-
const ret = wasm.__wbg_get_sev__exportpem_ask(this.__wbg_ptr);
|
|
907
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
908
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
909
|
-
return v1;
|
|
910
|
-
}
|
|
911
|
-
/**
|
|
912
|
-
* @returns {Uint8Array}
|
|
913
|
-
*/
|
|
914
|
-
get vek() {
|
|
915
|
-
const ret = wasm.__wbg_get_sev__exportpem_vek(this.__wbg_ptr);
|
|
916
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
917
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
918
|
-
return v1;
|
|
919
|
-
}
|
|
920
|
-
/**
|
|
921
|
-
* @param {Uint8Array} arg0
|
|
922
|
-
*/
|
|
923
|
-
set ark(arg0) {
|
|
924
|
-
const ptr0 = passArray8ToWasm0(arg0, wasm.__wbindgen_malloc);
|
|
925
|
-
const len0 = WASM_VECTOR_LEN;
|
|
926
|
-
wasm.__wbg_set_sev__exportpem_ark(this.__wbg_ptr, ptr0, len0);
|
|
836
|
+
wasm.__wbg_queryparams_free(ptr, 0);
|
|
927
837
|
}
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
const len0 = WASM_VECTOR_LEN;
|
|
934
|
-
wasm.__wbg_set_sev__exportpem_ask(this.__wbg_ptr, ptr0, len0);
|
|
838
|
+
constructor() {
|
|
839
|
+
const ret = wasm.queryparams_new();
|
|
840
|
+
this.__wbg_ptr = ret;
|
|
841
|
+
QueryParamsFinalization.register(this, this.__wbg_ptr, this);
|
|
842
|
+
return this;
|
|
935
843
|
}
|
|
936
844
|
/**
|
|
937
|
-
*
|
|
845
|
+
* Appends a query parameter.
|
|
846
|
+
*
|
|
847
|
+
* Reserved keywords for specific queries will get overwritten
|
|
848
|
+
* @param {string} key
|
|
849
|
+
* @param {string} value
|
|
850
|
+
* @returns {QueryParams}
|
|
938
851
|
*/
|
|
939
|
-
|
|
940
|
-
const
|
|
852
|
+
with(key, value) {
|
|
853
|
+
const ptr = this.__destroy_into_raw();
|
|
854
|
+
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
941
855
|
const len0 = WASM_VECTOR_LEN;
|
|
942
|
-
|
|
856
|
+
const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
857
|
+
const len1 = WASM_VECTOR_LEN;
|
|
858
|
+
const ret = wasm.queryparams_with(ptr, ptr0, len0, ptr1, len1);
|
|
859
|
+
return QueryParams.__wrap(ret);
|
|
943
860
|
}
|
|
944
861
|
}
|
|
945
|
-
if (Symbol.dispose)
|
|
862
|
+
if (Symbol.dispose) QueryParams.prototype[Symbol.dispose] = QueryParams.prototype.free;
|
|
946
863
|
|
|
947
|
-
class
|
|
864
|
+
export class QuoteVerifier {
|
|
948
865
|
__destroy_into_raw() {
|
|
949
866
|
const ptr = this.__wbg_ptr;
|
|
950
867
|
this.__wbg_ptr = 0;
|
|
951
|
-
|
|
868
|
+
QuoteVerifierFinalization.unregister(this);
|
|
952
869
|
return ptr;
|
|
953
870
|
}
|
|
954
871
|
free() {
|
|
955
872
|
const ptr = this.__destroy_into_raw();
|
|
956
|
-
wasm.
|
|
957
|
-
}
|
|
958
|
-
/**
|
|
959
|
-
* @param {ParsedAttestation} attestation
|
|
960
|
-
* @returns {Promise<VerifiedChain>}
|
|
961
|
-
*/
|
|
962
|
-
fetch_certificates(attestation) {
|
|
963
|
-
_assertClass(attestation, ParsedAttestation);
|
|
964
|
-
const ret = wasm.kds_fetch_certificates(this.__wbg_ptr, attestation.__wbg_ptr);
|
|
965
|
-
return ret;
|
|
873
|
+
wasm.__wbg_quoteverifier_free(ptr, 0);
|
|
966
874
|
}
|
|
967
875
|
/**
|
|
968
|
-
*
|
|
969
|
-
* @param {
|
|
970
|
-
* @returns {Promise<CRL>}
|
|
876
|
+
* @param {Collateral} collateral
|
|
877
|
+
* @param {TdxQuote} quote
|
|
971
878
|
*/
|
|
972
|
-
|
|
973
|
-
_assertClass(
|
|
974
|
-
|
|
975
|
-
|
|
879
|
+
constructor(collateral, quote) {
|
|
880
|
+
_assertClass(collateral, Collateral);
|
|
881
|
+
var ptr0 = collateral.__destroy_into_raw();
|
|
882
|
+
_assertClass(quote, TdxQuote);
|
|
883
|
+
var ptr1 = quote.__destroy_into_raw();
|
|
884
|
+
const ret = wasm.quoteverifier_new(ptr0, ptr1);
|
|
885
|
+
this.__wbg_ptr = ret;
|
|
886
|
+
QuoteVerifierFinalization.register(this, this.__wbg_ptr, this);
|
|
887
|
+
return this;
|
|
976
888
|
}
|
|
977
889
|
/**
|
|
978
|
-
* @param {
|
|
890
|
+
* @param {TdxNonce} nonce
|
|
979
891
|
*/
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
const
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
892
|
+
verify(nonce) {
|
|
893
|
+
_assertClass(nonce, TdxNonce);
|
|
894
|
+
const ret = wasm.quoteverifier_verify(this.__wbg_ptr, nonce.__wbg_ptr);
|
|
895
|
+
if (ret[1]) {
|
|
896
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
986
897
|
}
|
|
987
|
-
this.__wbg_ptr = ret[0] >>> 0;
|
|
988
|
-
KdsFinalization.register(this, this.__wbg_ptr, this);
|
|
989
|
-
return this;
|
|
990
898
|
}
|
|
991
899
|
}
|
|
992
|
-
if (Symbol.dispose)
|
|
900
|
+
if (Symbol.dispose) QuoteVerifier.prototype[Symbol.dispose] = QuoteVerifier.prototype.free;
|
|
993
901
|
|
|
994
|
-
|
|
995
|
-
* Represents a parsed attestation report with some already
|
|
996
|
-
* parsed commonly accessed fields
|
|
997
|
-
*/
|
|
998
|
-
class ParsedAttestation {
|
|
902
|
+
export class ResponseHeaders {
|
|
999
903
|
static __wrap(ptr) {
|
|
1000
|
-
|
|
1001
|
-
const obj = Object.create(ParsedAttestation.prototype);
|
|
904
|
+
const obj = Object.create(ResponseHeaders.prototype);
|
|
1002
905
|
obj.__wbg_ptr = ptr;
|
|
1003
|
-
|
|
906
|
+
ResponseHeadersFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1004
907
|
return obj;
|
|
1005
908
|
}
|
|
1006
909
|
__destroy_into_raw() {
|
|
1007
910
|
const ptr = this.__wbg_ptr;
|
|
1008
911
|
this.__wbg_ptr = 0;
|
|
1009
|
-
|
|
912
|
+
ResponseHeadersFinalization.unregister(this);
|
|
1010
913
|
return ptr;
|
|
1011
914
|
}
|
|
1012
915
|
free() {
|
|
1013
916
|
const ptr = this.__destroy_into_raw();
|
|
1014
|
-
wasm.
|
|
1015
|
-
}
|
|
1016
|
-
/**
|
|
1017
|
-
* @returns {number}
|
|
1018
|
-
*/
|
|
1019
|
-
cpu_fam_id() {
|
|
1020
|
-
const ret = wasm.parsedattestation_cpu_fam_id(this.__wbg_ptr);
|
|
1021
|
-
return ret;
|
|
1022
|
-
}
|
|
1023
|
-
/**
|
|
1024
|
-
* @returns {number}
|
|
1025
|
-
*/
|
|
1026
|
-
cpu_mod_id() {
|
|
1027
|
-
const ret = wasm.parsedattestation_cpu_mod_id(this.__wbg_ptr);
|
|
1028
|
-
return ret;
|
|
917
|
+
wasm.__wbg_responseheaders_free(ptr, 0);
|
|
1029
918
|
}
|
|
1030
919
|
/**
|
|
1031
|
-
*
|
|
1032
|
-
* @
|
|
1033
|
-
* @returns {ParsedAttestation}
|
|
920
|
+
* @param {string} name
|
|
921
|
+
* @returns {string | undefined}
|
|
1034
922
|
*/
|
|
1035
|
-
|
|
1036
|
-
const ptr0 =
|
|
923
|
+
get(name) {
|
|
924
|
+
const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1037
925
|
const len0 = WASM_VECTOR_LEN;
|
|
1038
|
-
const ret = wasm.
|
|
1039
|
-
|
|
1040
|
-
|
|
926
|
+
const ret = wasm.responseheaders_get(this.__wbg_ptr, ptr0, len0);
|
|
927
|
+
let v2;
|
|
928
|
+
if (ret[0] !== 0) {
|
|
929
|
+
v2 = getStringFromWasm0(ret[0], ret[1]).slice();
|
|
930
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
1041
931
|
}
|
|
1042
|
-
return
|
|
932
|
+
return v2;
|
|
1043
933
|
}
|
|
1044
934
|
/**
|
|
1045
|
-
*
|
|
1046
|
-
* @param {VerifiedChain} chain
|
|
1047
|
-
* @param {SevNonce} nonce
|
|
935
|
+
* @returns {string[]}
|
|
1048
936
|
*/
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
1055
|
-
}
|
|
937
|
+
keys() {
|
|
938
|
+
const ret = wasm.responseheaders_keys(this.__wbg_ptr);
|
|
939
|
+
var v1 = getArrayJsValueFromWasm0(ret[0], ret[1]).slice();
|
|
940
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 4, 4);
|
|
941
|
+
return v1;
|
|
1056
942
|
}
|
|
1057
943
|
}
|
|
1058
|
-
if (Symbol.dispose)
|
|
944
|
+
if (Symbol.dispose) ResponseHeaders.prototype[Symbol.dispose] = ResponseHeaders.prototype.free;
|
|
1059
945
|
|
|
1060
|
-
class SevNonce {
|
|
946
|
+
export class SevNonce {
|
|
1061
947
|
static __wrap(ptr) {
|
|
1062
|
-
ptr = ptr >>> 0;
|
|
1063
948
|
const obj = Object.create(SevNonce.prototype);
|
|
1064
949
|
obj.__wbg_ptr = ptr;
|
|
1065
950
|
SevNonceFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -1073,7 +958,7 @@ class SevNonce {
|
|
|
1073
958
|
}
|
|
1074
959
|
free() {
|
|
1075
960
|
const ptr = this.__destroy_into_raw();
|
|
1076
|
-
wasm.
|
|
961
|
+
wasm.__wbg_sevnonce_free(ptr, 0);
|
|
1077
962
|
}
|
|
1078
963
|
/**
|
|
1079
964
|
* @returns {SevNonce}
|
|
@@ -1100,12 +985,94 @@ class SevNonce {
|
|
|
1100
985
|
}
|
|
1101
986
|
if (Symbol.dispose) SevNonce.prototype[Symbol.dispose] = SevNonce.prototype.free;
|
|
1102
987
|
|
|
988
|
+
export class TcbLevels {
|
|
989
|
+
__destroy_into_raw() {
|
|
990
|
+
const ptr = this.__wbg_ptr;
|
|
991
|
+
this.__wbg_ptr = 0;
|
|
992
|
+
TcbLevelsFinalization.unregister(this);
|
|
993
|
+
return ptr;
|
|
994
|
+
}
|
|
995
|
+
free() {
|
|
996
|
+
const ptr = this.__destroy_into_raw();
|
|
997
|
+
wasm.__wbg_tcblevels_free(ptr, 0);
|
|
998
|
+
}
|
|
999
|
+
}
|
|
1000
|
+
if (Symbol.dispose) TcbLevels.prototype[Symbol.dispose] = TcbLevels.prototype.free;
|
|
1001
|
+
|
|
1002
|
+
export class TdxNonce {
|
|
1003
|
+
__destroy_into_raw() {
|
|
1004
|
+
const ptr = this.__wbg_ptr;
|
|
1005
|
+
this.__wbg_ptr = 0;
|
|
1006
|
+
TdxNonceFinalization.unregister(this);
|
|
1007
|
+
return ptr;
|
|
1008
|
+
}
|
|
1009
|
+
free() {
|
|
1010
|
+
const ptr = this.__destroy_into_raw();
|
|
1011
|
+
wasm.__wbg_tdxnonce_free(ptr, 0);
|
|
1012
|
+
}
|
|
1013
|
+
constructor() {
|
|
1014
|
+
const ret = wasm.tdxnonce_generate();
|
|
1015
|
+
this.__wbg_ptr = ret;
|
|
1016
|
+
TdxNonceFinalization.register(this, this.__wbg_ptr, this);
|
|
1017
|
+
return this;
|
|
1018
|
+
}
|
|
1019
|
+
/**
|
|
1020
|
+
* @returns {string}
|
|
1021
|
+
*/
|
|
1022
|
+
to_hex() {
|
|
1023
|
+
let deferred1_0;
|
|
1024
|
+
let deferred1_1;
|
|
1025
|
+
try {
|
|
1026
|
+
const ret = wasm.tdxnonce_to_hex(this.__wbg_ptr);
|
|
1027
|
+
deferred1_0 = ret[0];
|
|
1028
|
+
deferred1_1 = ret[1];
|
|
1029
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
1030
|
+
} finally {
|
|
1031
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
1032
|
+
}
|
|
1033
|
+
}
|
|
1034
|
+
}
|
|
1035
|
+
if (Symbol.dispose) TdxNonce.prototype[Symbol.dispose] = TdxNonce.prototype.free;
|
|
1036
|
+
|
|
1037
|
+
export class TdxQuote {
|
|
1038
|
+
static __wrap(ptr) {
|
|
1039
|
+
const obj = Object.create(TdxQuote.prototype);
|
|
1040
|
+
obj.__wbg_ptr = ptr;
|
|
1041
|
+
TdxQuoteFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
1042
|
+
return obj;
|
|
1043
|
+
}
|
|
1044
|
+
__destroy_into_raw() {
|
|
1045
|
+
const ptr = this.__wbg_ptr;
|
|
1046
|
+
this.__wbg_ptr = 0;
|
|
1047
|
+
TdxQuoteFinalization.unregister(this);
|
|
1048
|
+
return ptr;
|
|
1049
|
+
}
|
|
1050
|
+
free() {
|
|
1051
|
+
const ptr = this.__destroy_into_raw();
|
|
1052
|
+
wasm.__wbg_tdxquote_free(ptr, 0);
|
|
1053
|
+
}
|
|
1054
|
+
/**
|
|
1055
|
+
* Attempts to parse a quote from DCAP bytes.
|
|
1056
|
+
* @param {Uint8Array} quote
|
|
1057
|
+
* @returns {TdxQuote}
|
|
1058
|
+
*/
|
|
1059
|
+
static from_bytes(quote) {
|
|
1060
|
+
const ptr0 = passArray8ToWasm0(quote, wasm.__wbindgen_malloc);
|
|
1061
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1062
|
+
const ret = wasm.tdxquote_from_bytes(ptr0, len0);
|
|
1063
|
+
if (ret[2]) {
|
|
1064
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
1065
|
+
}
|
|
1066
|
+
return TdxQuote.__wrap(ret[0]);
|
|
1067
|
+
}
|
|
1068
|
+
}
|
|
1069
|
+
if (Symbol.dispose) TdxQuote.prototype[Symbol.dispose] = TdxQuote.prototype.free;
|
|
1070
|
+
|
|
1103
1071
|
/**
|
|
1104
1072
|
* A chain which has been cryptographically verified
|
|
1105
1073
|
*/
|
|
1106
|
-
class VerifiedChain {
|
|
1074
|
+
export class VerifiedChain {
|
|
1107
1075
|
static __wrap(ptr) {
|
|
1108
|
-
ptr = ptr >>> 0;
|
|
1109
1076
|
const obj = Object.create(VerifiedChain.prototype);
|
|
1110
1077
|
obj.__wbg_ptr = ptr;
|
|
1111
1078
|
VerifiedChainFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
@@ -1119,7 +1086,7 @@ class VerifiedChain {
|
|
|
1119
1086
|
}
|
|
1120
1087
|
free() {
|
|
1121
1088
|
const ptr = this.__destroy_into_raw();
|
|
1122
|
-
wasm.
|
|
1089
|
+
wasm.__wbg_verifiedchain_free(ptr, 0);
|
|
1123
1090
|
}
|
|
1124
1091
|
/**
|
|
1125
1092
|
* parses a triad of ark, ask and vek certificates in the PEM format,
|
|
@@ -1155,38 +1122,50 @@ class VerifiedChain {
|
|
|
1155
1122
|
}
|
|
1156
1123
|
if (Symbol.dispose) VerifiedChain.prototype[Symbol.dispose] = VerifiedChain.prototype.free;
|
|
1157
1124
|
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1125
|
+
/**
|
|
1126
|
+
* @param {any} input
|
|
1127
|
+
* @param {any | null} [init]
|
|
1128
|
+
* @returns {Promise<any>}
|
|
1129
|
+
*/
|
|
1130
|
+
function fetch2(input, init) {
|
|
1131
|
+
const ret = wasm.fetch(input, isLikeNone(init) ? 0 : addToExternrefTable0(init));
|
|
1132
|
+
return ret;
|
|
1133
|
+
}
|
|
1134
|
+
export { fetch2 as fetch }
|
|
1135
|
+
|
|
1136
|
+
/**
|
|
1137
|
+
* Same as [`KeyChain:fetch_keychain`], put in for better wasm compatibility
|
|
1138
|
+
* @returns {Promise<KeyChain>}
|
|
1139
|
+
*/
|
|
1140
|
+
export function fetch_keychain() {
|
|
1141
|
+
const ret = wasm.fetch_keychain();
|
|
1142
|
+
return ret;
|
|
1143
|
+
}
|
|
1144
|
+
export function __wbg___wbindgen_debug_string_edece8177ad01481(arg0, arg1) {
|
|
1166
1145
|
const ret = debugString(arg1);
|
|
1167
1146
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1168
1147
|
const len1 = WASM_VECTOR_LEN;
|
|
1169
1148
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1170
1149
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1171
1150
|
}
|
|
1172
|
-
export function
|
|
1151
|
+
export function __wbg___wbindgen_is_function_5cd60d5cf78b4eef(arg0) {
|
|
1173
1152
|
const ret = typeof(arg0) === 'function';
|
|
1174
1153
|
return ret;
|
|
1175
1154
|
}
|
|
1176
|
-
export function
|
|
1155
|
+
export function __wbg___wbindgen_is_object_b4593df85baada48(arg0) {
|
|
1177
1156
|
const val = arg0;
|
|
1178
1157
|
const ret = typeof(val) === 'object' && val !== null;
|
|
1179
1158
|
return ret;
|
|
1180
1159
|
}
|
|
1181
|
-
export function
|
|
1160
|
+
export function __wbg___wbindgen_is_string_dde0fd9020db4434(arg0) {
|
|
1182
1161
|
const ret = typeof(arg0) === 'string';
|
|
1183
1162
|
return ret;
|
|
1184
1163
|
}
|
|
1185
|
-
export function
|
|
1164
|
+
export function __wbg___wbindgen_is_undefined_35bb9f4c7fd651d5(arg0) {
|
|
1186
1165
|
const ret = arg0 === undefined;
|
|
1187
1166
|
return ret;
|
|
1188
1167
|
}
|
|
1189
|
-
export function
|
|
1168
|
+
export function __wbg___wbindgen_string_get_d109740c0d18f4d7(arg0, arg1) {
|
|
1190
1169
|
const obj = arg1;
|
|
1191
1170
|
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
1192
1171
|
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -1194,22 +1173,22 @@ export function __wbg___wbindgen_string_get_914df97fcfa788f2(arg0, arg1) {
|
|
|
1194
1173
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1195
1174
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1196
1175
|
}
|
|
1197
|
-
export function
|
|
1176
|
+
export function __wbg___wbindgen_throw_9c31b086c2b26051(arg0, arg1) {
|
|
1198
1177
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
1199
1178
|
}
|
|
1200
|
-
export function
|
|
1179
|
+
export function __wbg__wbg_cb_unref_3fa391f3fcdb55f8(arg0) {
|
|
1201
1180
|
arg0._wbg_cb_unref();
|
|
1202
1181
|
}
|
|
1203
|
-
export function
|
|
1204
|
-
arg0.abort();
|
|
1205
|
-
}
|
|
1206
|
-
export function __wbg_abort_7a67cb8f9383baa1(arg0, arg1) {
|
|
1182
|
+
export function __wbg_abort_89f7368e16055f5f(arg0, arg1) {
|
|
1207
1183
|
arg0.abort(arg1);
|
|
1208
1184
|
}
|
|
1209
|
-
export function
|
|
1185
|
+
export function __wbg_abort_b363e6285472a358(arg0) {
|
|
1186
|
+
arg0.abort();
|
|
1187
|
+
}
|
|
1188
|
+
export function __wbg_append_263958599fd198c1() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
1210
1189
|
arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
1211
1190
|
}, arguments); }
|
|
1212
|
-
export function
|
|
1191
|
+
export function __wbg_arrayBuffer_cb5d4748b5f3cad5() { return handleError(function (arg0) {
|
|
1213
1192
|
const ret = arg0.arrayBuffer();
|
|
1214
1193
|
return ret;
|
|
1215
1194
|
}, arguments); }
|
|
@@ -1217,11 +1196,11 @@ export function __wbg_attestresult_new(arg0) {
|
|
|
1217
1196
|
const ret = AttestResult.__wrap(arg0);
|
|
1218
1197
|
return ret;
|
|
1219
1198
|
}
|
|
1220
|
-
export function
|
|
1199
|
+
export function __wbg_call_13665d9f14390edc() { return handleError(function (arg0, arg1) {
|
|
1221
1200
|
const ret = arg0.call(arg1);
|
|
1222
1201
|
return ret;
|
|
1223
1202
|
}, arguments); }
|
|
1224
|
-
export function
|
|
1203
|
+
export function __wbg_call_dfde26266607c996() { return handleError(function (arg0, arg1, arg2) {
|
|
1225
1204
|
const ret = arg0.call(arg1, arg2);
|
|
1226
1205
|
return ret;
|
|
1227
1206
|
}, arguments); }
|
|
@@ -1241,19 +1220,23 @@ export function __wbg_collateral_new(arg0) {
|
|
|
1241
1220
|
const ret = Collateral.__wrap(arg0);
|
|
1242
1221
|
return ret;
|
|
1243
1222
|
}
|
|
1223
|
+
export function __wbg_crl_new(arg0) {
|
|
1224
|
+
const ret = CRL.__wrap(arg0);
|
|
1225
|
+
return ret;
|
|
1226
|
+
}
|
|
1244
1227
|
export function __wbg_crypto_48300657fced39f9(arg0) {
|
|
1245
1228
|
const ret = arg0.crypto;
|
|
1246
1229
|
return ret;
|
|
1247
1230
|
}
|
|
1248
|
-
export function
|
|
1231
|
+
export function __wbg_done_54b8da57023b7ed2(arg0) {
|
|
1249
1232
|
const ret = arg0.done;
|
|
1250
1233
|
return ret;
|
|
1251
1234
|
}
|
|
1252
|
-
export function
|
|
1235
|
+
export function __wbg_entries_8c373da97ea5ada5(arg0) {
|
|
1253
1236
|
const ret = arg0.entries();
|
|
1254
1237
|
return ret;
|
|
1255
1238
|
}
|
|
1256
|
-
export function
|
|
1239
|
+
export function __wbg_fetch_2998af8c54e0997c(arg0, arg1) {
|
|
1257
1240
|
const ret = arg0.fetch(arg1);
|
|
1258
1241
|
return ret;
|
|
1259
1242
|
}
|
|
@@ -1275,27 +1258,37 @@ export function __wbg_getRandomValues_263d0aa5464054ee() { return handleError(fu
|
|
|
1275
1258
|
export function __wbg_getRandomValues_76dfc69825c9c552() { return handleError(function (arg0, arg1) {
|
|
1276
1259
|
globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
|
|
1277
1260
|
}, arguments); }
|
|
1278
|
-
export function
|
|
1261
|
+
export function __wbg_getTime_09f1dd40a44edb30(arg0) {
|
|
1279
1262
|
const ret = arg0.getTime();
|
|
1280
1263
|
return ret;
|
|
1281
1264
|
}
|
|
1282
|
-
export function
|
|
1283
|
-
const ret = arg0[arg1 >>> 0];
|
|
1284
|
-
return ret;
|
|
1285
|
-
}
|
|
1286
|
-
export function __wbg_get_ed0642c4b9d31ddf() { return handleError(function (arg0, arg1) {
|
|
1265
|
+
export function __wbg_get_3e9a707ab7d352eb() { return handleError(function (arg0, arg1) {
|
|
1287
1266
|
const ret = Reflect.get(arg0, arg1);
|
|
1288
1267
|
return ret;
|
|
1289
1268
|
}, arguments); }
|
|
1290
|
-
export function
|
|
1269
|
+
export function __wbg_get_98fdf51d029a75eb(arg0, arg1) {
|
|
1270
|
+
const ret = arg0[arg1 >>> 0];
|
|
1271
|
+
return ret;
|
|
1272
|
+
}
|
|
1273
|
+
export function __wbg_has_ef192b1f278770eb() { return handleError(function (arg0, arg1) {
|
|
1291
1274
|
const ret = Reflect.has(arg0, arg1);
|
|
1292
1275
|
return ret;
|
|
1293
1276
|
}, arguments); }
|
|
1294
|
-
export function
|
|
1277
|
+
export function __wbg_headers_18f39f24d3837dc1(arg0) {
|
|
1295
1278
|
const ret = arg0.headers;
|
|
1296
1279
|
return ret;
|
|
1297
1280
|
}
|
|
1298
|
-
export function
|
|
1281
|
+
export function __wbg_instanceof_Request_0b988f27c60a71ed(arg0) {
|
|
1282
|
+
let result;
|
|
1283
|
+
try {
|
|
1284
|
+
result = arg0 instanceof Request;
|
|
1285
|
+
} catch (_) {
|
|
1286
|
+
result = false;
|
|
1287
|
+
}
|
|
1288
|
+
const ret = result;
|
|
1289
|
+
return ret;
|
|
1290
|
+
}
|
|
1291
|
+
export function __wbg_instanceof_Response_ecfc823e8fb354e2(arg0) {
|
|
1299
1292
|
let result;
|
|
1300
1293
|
try {
|
|
1301
1294
|
result = arg0 instanceof Response;
|
|
@@ -1305,15 +1298,19 @@ export function __wbg_instanceof_Response_06795eab66cc4036(arg0) {
|
|
|
1305
1298
|
const ret = result;
|
|
1306
1299
|
return ret;
|
|
1307
1300
|
}
|
|
1308
|
-
export function
|
|
1301
|
+
export function __wbg_isArray_94898ed3aad6947b(arg0) {
|
|
1309
1302
|
const ret = Array.isArray(arg0);
|
|
1310
1303
|
return ret;
|
|
1311
1304
|
}
|
|
1312
|
-
export function
|
|
1305
|
+
export function __wbg_iterator_1441b47f341dc34f() {
|
|
1313
1306
|
const ret = Symbol.iterator;
|
|
1314
1307
|
return ret;
|
|
1315
1308
|
}
|
|
1316
|
-
export function
|
|
1309
|
+
export function __wbg_keychain_new(arg0) {
|
|
1310
|
+
const ret = KeyChain.__wrap(arg0);
|
|
1311
|
+
return ret;
|
|
1312
|
+
}
|
|
1313
|
+
export function __wbg_length_56fcd3e2b7e0299d(arg0) {
|
|
1317
1314
|
const ret = arg0.length;
|
|
1318
1315
|
return ret;
|
|
1319
1316
|
}
|
|
@@ -1325,42 +1322,42 @@ export function __wbg_msCrypto_8c6d45a75ef1d3da(arg0) {
|
|
|
1325
1322
|
const ret = arg0.msCrypto;
|
|
1326
1323
|
return ret;
|
|
1327
1324
|
}
|
|
1328
|
-
export function
|
|
1325
|
+
export function __wbg_new_02d162bc6cf02f60() {
|
|
1326
|
+
const ret = new Object();
|
|
1327
|
+
return ret;
|
|
1328
|
+
}
|
|
1329
|
+
export function __wbg_new_0_2722fcdb71a888a6() {
|
|
1329
1330
|
const ret = new Date();
|
|
1330
1331
|
return ret;
|
|
1331
1332
|
}
|
|
1332
|
-
export function
|
|
1333
|
-
const ret = new
|
|
1333
|
+
export function __wbg_new_1f236d63ba0c4784(arg0, arg1) {
|
|
1334
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
1334
1335
|
return ret;
|
|
1335
|
-
}
|
|
1336
|
-
export function
|
|
1337
|
-
const ret = new
|
|
1336
|
+
}
|
|
1337
|
+
export function __wbg_new_7ddec6de44ff8f5d(arg0) {
|
|
1338
|
+
const ret = new Uint8Array(arg0);
|
|
1338
1339
|
return ret;
|
|
1339
1340
|
}
|
|
1340
|
-
export function
|
|
1341
|
+
export function __wbg_new_af86d8f14640f1f3() { return handleError(function () {
|
|
1341
1342
|
const ret = new AbortController();
|
|
1342
1343
|
return ret;
|
|
1343
1344
|
}, arguments); }
|
|
1344
|
-
export function
|
|
1345
|
-
const ret = new
|
|
1346
|
-
return ret;
|
|
1347
|
-
}
|
|
1348
|
-
export function __wbg_new_e3b04b4d53d1b593(arg0, arg1) {
|
|
1349
|
-
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
1345
|
+
export function __wbg_new_ee0be486d8f01282() { return handleError(function () {
|
|
1346
|
+
const ret = new Headers();
|
|
1350
1347
|
return ret;
|
|
1351
|
-
}
|
|
1352
|
-
export function
|
|
1348
|
+
}, arguments); }
|
|
1349
|
+
export function __wbg_new_from_slice_269e35316ed2d061(arg0, arg1) {
|
|
1353
1350
|
const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
|
|
1354
1351
|
return ret;
|
|
1355
1352
|
}
|
|
1356
|
-
export function
|
|
1353
|
+
export function __wbg_new_typed_c072c4ce9a2a0cdf(arg0, arg1) {
|
|
1357
1354
|
try {
|
|
1358
1355
|
var state0 = {a: arg0, b: arg1};
|
|
1359
1356
|
var cb0 = (arg0, arg1) => {
|
|
1360
1357
|
const a = state0.a;
|
|
1361
1358
|
state0.a = 0;
|
|
1362
1359
|
try {
|
|
1363
|
-
return
|
|
1360
|
+
return wasm_bindgen__convert__closures_____invoke__h61e8cb59c1b109c6(a, state0.b, arg0, arg1);
|
|
1364
1361
|
} finally {
|
|
1365
1362
|
state0.a = a;
|
|
1366
1363
|
}
|
|
@@ -1371,19 +1368,19 @@ export function __wbg_new_typed_14d7cc391ce53d2c(arg0, arg1) {
|
|
|
1371
1368
|
state0.a = 0;
|
|
1372
1369
|
}
|
|
1373
1370
|
}
|
|
1374
|
-
export function
|
|
1371
|
+
export function __wbg_new_with_length_99887c91eae4abab(arg0) {
|
|
1375
1372
|
const ret = new Uint8Array(arg0 >>> 0);
|
|
1376
1373
|
return ret;
|
|
1377
1374
|
}
|
|
1378
|
-
export function
|
|
1375
|
+
export function __wbg_new_with_str_and_init_ffe9977c986ea039() { return handleError(function (arg0, arg1, arg2) {
|
|
1379
1376
|
const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
|
|
1380
1377
|
return ret;
|
|
1381
1378
|
}, arguments); }
|
|
1382
|
-
export function
|
|
1379
|
+
export function __wbg_next_2a4e19f4f5083b0f(arg0) {
|
|
1383
1380
|
const ret = arg0.next;
|
|
1384
1381
|
return ret;
|
|
1385
1382
|
}
|
|
1386
|
-
export function
|
|
1383
|
+
export function __wbg_next_6429a146bf756f93() { return handleError(function (arg0) {
|
|
1387
1384
|
const ret = arg0.next();
|
|
1388
1385
|
return ret;
|
|
1389
1386
|
}, arguments); }
|
|
@@ -1391,36 +1388,40 @@ export function __wbg_node_95beb7570492fd97(arg0) {
|
|
|
1391
1388
|
const ret = arg0.node;
|
|
1392
1389
|
return ret;
|
|
1393
1390
|
}
|
|
1394
|
-
export function __wbg_nvidia__keychain_new(arg0) {
|
|
1395
|
-
const ret = KeyChain.__wrap(arg0);
|
|
1396
|
-
return ret;
|
|
1397
|
-
}
|
|
1398
1391
|
export function __wbg_nvidiaattestresult_new(arg0) {
|
|
1399
1392
|
const ret = NvidiaAttestResult.__wrap(arg0);
|
|
1400
1393
|
return ret;
|
|
1401
1394
|
}
|
|
1395
|
+
export function __wbg_parsedattestation_new(arg0) {
|
|
1396
|
+
const ret = ParsedAttestation.__wrap(arg0);
|
|
1397
|
+
return ret;
|
|
1398
|
+
}
|
|
1402
1399
|
export function __wbg_process_b2fea42461d03994(arg0) {
|
|
1403
1400
|
const ret = arg0.process;
|
|
1404
1401
|
return ret;
|
|
1405
1402
|
}
|
|
1406
|
-
export function
|
|
1403
|
+
export function __wbg_prototypesetcall_5f9bdc8d75e07276(arg0, arg1, arg2) {
|
|
1407
1404
|
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
|
|
1408
1405
|
}
|
|
1409
|
-
export function
|
|
1406
|
+
export function __wbg_queueMicrotask_78d584b53af520f5(arg0) {
|
|
1410
1407
|
const ret = arg0.queueMicrotask;
|
|
1411
1408
|
return ret;
|
|
1412
1409
|
}
|
|
1413
|
-
export function
|
|
1410
|
+
export function __wbg_queueMicrotask_b39ea83c7f01971a(arg0) {
|
|
1414
1411
|
queueMicrotask(arg0);
|
|
1415
1412
|
}
|
|
1416
1413
|
export function __wbg_randomFillSync_ca9f178fb14c88cb() { return handleError(function (arg0, arg1) {
|
|
1417
1414
|
arg0.randomFillSync(arg1);
|
|
1418
1415
|
}, arguments); }
|
|
1416
|
+
export function __wbg_realFetch_65865cb56349aabc() { return handleError(function (arg0, arg1) {
|
|
1417
|
+
const ret = realFetch(arg0, arg1);
|
|
1418
|
+
return ret;
|
|
1419
|
+
}, arguments); }
|
|
1419
1420
|
export function __wbg_require_7a9419e39d796c95() { return handleError(function () {
|
|
1420
1421
|
const ret = module.require;
|
|
1421
1422
|
return ret;
|
|
1422
1423
|
}, arguments); }
|
|
1423
|
-
export function
|
|
1424
|
+
export function __wbg_resolve_d17db9352f5a220e(arg0) {
|
|
1424
1425
|
const ret = Promise.resolve(arg0);
|
|
1425
1426
|
return ret;
|
|
1426
1427
|
}
|
|
@@ -1436,78 +1437,66 @@ export function __wbg_setTimeout_f757f00851f76c42(arg0, arg1) {
|
|
|
1436
1437
|
const ret = setTimeout(arg0, arg1);
|
|
1437
1438
|
return ret;
|
|
1438
1439
|
}
|
|
1439
|
-
export function
|
|
1440
|
+
export function __wbg_set_a0e911be3da02782() { return handleError(function (arg0, arg1, arg2) {
|
|
1440
1441
|
const ret = Reflect.set(arg0, arg1, arg2);
|
|
1441
1442
|
return ret;
|
|
1442
1443
|
}, arguments); }
|
|
1443
|
-
export function
|
|
1444
|
+
export function __wbg_set_body_7f56457720e81672(arg0, arg1) {
|
|
1444
1445
|
arg0.body = arg1;
|
|
1445
1446
|
}
|
|
1446
|
-
export function
|
|
1447
|
+
export function __wbg_set_cache_9ed01a3813d96de2(arg0, arg1) {
|
|
1447
1448
|
arg0.cache = __wbindgen_enum_RequestCache[arg1];
|
|
1448
1449
|
}
|
|
1449
|
-
export function
|
|
1450
|
+
export function __wbg_set_cause_02f710d8cce70c01(arg0, arg1) {
|
|
1450
1451
|
arg0.cause = arg1;
|
|
1451
1452
|
}
|
|
1452
|
-
export function
|
|
1453
|
+
export function __wbg_set_credentials_55b92faec8dcc6a4(arg0, arg1) {
|
|
1453
1454
|
arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
|
|
1454
1455
|
}
|
|
1455
|
-
export function
|
|
1456
|
+
export function __wbg_set_headers_97ed66619adb1e3e(arg0, arg1) {
|
|
1456
1457
|
arg0.headers = arg1;
|
|
1457
1458
|
}
|
|
1458
|
-
export function
|
|
1459
|
+
export function __wbg_set_method_4d69a1a7e34c0aca(arg0, arg1, arg2) {
|
|
1459
1460
|
arg0.method = getStringFromWasm0(arg1, arg2);
|
|
1460
1461
|
}
|
|
1461
|
-
export function
|
|
1462
|
+
export function __wbg_set_mode_dfc59bbbe25b1d14(arg0, arg1) {
|
|
1462
1463
|
arg0.mode = __wbindgen_enum_RequestMode[arg1];
|
|
1463
1464
|
}
|
|
1464
|
-
export function
|
|
1465
|
+
export function __wbg_set_name_e500733c75ec36b0(arg0, arg1, arg2) {
|
|
1465
1466
|
arg0.name = getStringFromWasm0(arg1, arg2);
|
|
1466
1467
|
}
|
|
1467
|
-
export function
|
|
1468
|
+
export function __wbg_set_signal_2a5bd3615938edbc(arg0, arg1) {
|
|
1468
1469
|
arg0.signal = arg1;
|
|
1469
1470
|
}
|
|
1470
|
-
export function
|
|
1471
|
-
const ret = CRL.__wrap(arg0);
|
|
1472
|
-
return ret;
|
|
1473
|
-
}
|
|
1474
|
-
export function __wbg_sev__parsedattestation_new(arg0) {
|
|
1475
|
-
const ret = ParsedAttestation.__wrap(arg0);
|
|
1476
|
-
return ret;
|
|
1477
|
-
}
|
|
1478
|
-
export function __wbg_sev__verifiedchain_new(arg0) {
|
|
1479
|
-
const ret = VerifiedChain.__wrap(arg0);
|
|
1480
|
-
return ret;
|
|
1481
|
-
}
|
|
1482
|
-
export function __wbg_signal_9172c3282bfba2f5(arg0) {
|
|
1471
|
+
export function __wbg_signal_304beac95c8c5ea0(arg0) {
|
|
1483
1472
|
const ret = arg0.signal;
|
|
1484
1473
|
return ret;
|
|
1485
1474
|
}
|
|
1486
|
-
export function
|
|
1475
|
+
export function __wbg_static_accessor_GLOBAL_THIS_02344c9b09eb08a9() {
|
|
1487
1476
|
const ret = typeof globalThis === 'undefined' ? null : globalThis;
|
|
1488
1477
|
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1489
1478
|
}
|
|
1490
|
-
export function
|
|
1479
|
+
export function __wbg_static_accessor_GLOBAL_ac6d4ac874d5cd54() {
|
|
1491
1480
|
const ret = typeof global === 'undefined' ? null : global;
|
|
1492
1481
|
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1493
1482
|
}
|
|
1494
|
-
export function
|
|
1483
|
+
export function __wbg_static_accessor_SELF_9b2406c23aeb2023() {
|
|
1495
1484
|
const ret = typeof self === 'undefined' ? null : self;
|
|
1496
1485
|
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1497
1486
|
}
|
|
1498
|
-
export function
|
|
1487
|
+
export function __wbg_static_accessor_WINDOW_b34d2126934e16ba() {
|
|
1499
1488
|
const ret = typeof window === 'undefined' ? null : window;
|
|
1500
1489
|
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1501
1490
|
}
|
|
1502
|
-
export function
|
|
1491
|
+
export function __wbg_status_0853c9f5752c7ee2(arg0) {
|
|
1503
1492
|
const ret = arg0.status;
|
|
1504
1493
|
return ret;
|
|
1505
1494
|
}
|
|
1506
|
-
export function
|
|
1495
|
+
export function __wbg_stringify_ef0c105b1ccc3849() { return handleError(function (arg0) {
|
|
1507
1496
|
const ret = JSON.stringify(arg0);
|
|
1508
1497
|
return ret;
|
|
1509
1498
|
}, arguments); }
|
|
1510
|
-
export function
|
|
1499
|
+
export function __wbg_subarray_7c6a0da8f3b4a1ba(arg0, arg1, arg2) {
|
|
1511
1500
|
const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
|
|
1512
1501
|
return ret;
|
|
1513
1502
|
}
|
|
@@ -1515,46 +1504,57 @@ export function __wbg_tdxquote_new(arg0) {
|
|
|
1515
1504
|
const ret = TdxQuote.__wrap(arg0);
|
|
1516
1505
|
return ret;
|
|
1517
1506
|
}
|
|
1518
|
-
export function
|
|
1507
|
+
export function __wbg_text_99930d92d5f1b540() { return handleError(function (arg0) {
|
|
1519
1508
|
const ret = arg0.text();
|
|
1520
1509
|
return ret;
|
|
1521
1510
|
}, arguments); }
|
|
1522
|
-
export function
|
|
1523
|
-
const ret = arg0.then(arg1
|
|
1511
|
+
export function __wbg_then_837494e384b37459(arg0, arg1) {
|
|
1512
|
+
const ret = arg0.then(arg1);
|
|
1524
1513
|
return ret;
|
|
1525
1514
|
}
|
|
1526
|
-
export function
|
|
1527
|
-
const ret = arg0.then(arg1);
|
|
1515
|
+
export function __wbg_then_bd927500e8905df2(arg0, arg1, arg2) {
|
|
1516
|
+
const ret = arg0.then(arg1, arg2);
|
|
1528
1517
|
return ret;
|
|
1529
1518
|
}
|
|
1530
|
-
export function
|
|
1519
|
+
export function __wbg_url_1a5ea6a8a7f22ff8(arg0, arg1) {
|
|
1520
|
+
const ret = arg1.url;
|
|
1521
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1522
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1523
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1524
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1525
|
+
}
|
|
1526
|
+
export function __wbg_url_f1cddff1f5b9519a(arg0, arg1) {
|
|
1531
1527
|
const ret = arg1.url;
|
|
1532
1528
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1533
1529
|
const len1 = WASM_VECTOR_LEN;
|
|
1534
1530
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1535
1531
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1536
1532
|
}
|
|
1537
|
-
export function
|
|
1533
|
+
export function __wbg_value_9cc0518af87a489c(arg0) {
|
|
1538
1534
|
const ret = arg0.value;
|
|
1539
1535
|
return ret;
|
|
1540
1536
|
}
|
|
1537
|
+
export function __wbg_verifiedchain_new(arg0) {
|
|
1538
|
+
const ret = VerifiedChain.__wrap(arg0);
|
|
1539
|
+
return ret;
|
|
1540
|
+
}
|
|
1541
1541
|
export function __wbg_versions_215a3ab1c9d5745a(arg0) {
|
|
1542
1542
|
const ret = arg0.versions;
|
|
1543
1543
|
return ret;
|
|
1544
1544
|
}
|
|
1545
1545
|
export function __wbindgen_cast_0000000000000001(arg0, arg1) {
|
|
1546
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
1547
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1546
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 1962, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
1547
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hae26513a56be1c77);
|
|
1548
1548
|
return ret;
|
|
1549
1549
|
}
|
|
1550
1550
|
export function __wbindgen_cast_0000000000000002(arg0, arg1) {
|
|
1551
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
1552
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1551
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 1787, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1552
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hba3e03ec0686df06);
|
|
1553
1553
|
return ret;
|
|
1554
1554
|
}
|
|
1555
1555
|
export function __wbindgen_cast_0000000000000003(arg0, arg1) {
|
|
1556
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
1557
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1556
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 900, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1557
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hb48ee18b811a2652);
|
|
1558
1558
|
return ret;
|
|
1559
1559
|
}
|
|
1560
1560
|
export function __wbindgen_cast_0000000000000004(arg0, arg1) {
|
|
@@ -1583,23 +1583,23 @@ export function __wbindgen_init_externref_table() {
|
|
|
1583
1583
|
table.set(offset + 2, true);
|
|
1584
1584
|
table.set(offset + 3, false);
|
|
1585
1585
|
}
|
|
1586
|
-
function
|
|
1587
|
-
wasm.
|
|
1586
|
+
function wasm_bindgen__convert__closures_____invoke__hba3e03ec0686df06(arg0, arg1) {
|
|
1587
|
+
wasm.wasm_bindgen__convert__closures_____invoke__hba3e03ec0686df06(arg0, arg1);
|
|
1588
1588
|
}
|
|
1589
1589
|
|
|
1590
|
-
function
|
|
1591
|
-
wasm.
|
|
1590
|
+
function wasm_bindgen__convert__closures_____invoke__hb48ee18b811a2652(arg0, arg1) {
|
|
1591
|
+
wasm.wasm_bindgen__convert__closures_____invoke__hb48ee18b811a2652(arg0, arg1);
|
|
1592
1592
|
}
|
|
1593
1593
|
|
|
1594
|
-
function
|
|
1595
|
-
const ret = wasm.
|
|
1594
|
+
function wasm_bindgen__convert__closures_____invoke__hae26513a56be1c77(arg0, arg1, arg2) {
|
|
1595
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__hae26513a56be1c77(arg0, arg1, arg2);
|
|
1596
1596
|
if (ret[1]) {
|
|
1597
1597
|
throw takeFromExternrefTable0(ret[0]);
|
|
1598
1598
|
}
|
|
1599
1599
|
}
|
|
1600
1600
|
|
|
1601
|
-
function
|
|
1602
|
-
wasm.
|
|
1601
|
+
function wasm_bindgen__convert__closures_____invoke__h61e8cb59c1b109c6(arg0, arg1, arg2, arg3) {
|
|
1602
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h61e8cb59c1b109c6(arg0, arg1, arg2, arg3);
|
|
1603
1603
|
}
|
|
1604
1604
|
|
|
1605
1605
|
|
|
@@ -1612,79 +1612,79 @@ const __wbindgen_enum_RequestCredentials = ["omit", "same-origin", "include"];
|
|
|
1612
1612
|
const __wbindgen_enum_RequestMode = ["same-origin", "no-cors", "cors", "navigate"];
|
|
1613
1613
|
const AttestHeadersFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1614
1614
|
? { register: () => {}, unregister: () => {} }
|
|
1615
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_attestheaders_free(ptr
|
|
1615
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_attestheaders_free(ptr, 1));
|
|
1616
1616
|
const AttestResultFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1617
1617
|
? { register: () => {}, unregister: () => {} }
|
|
1618
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_attestresult_free(ptr
|
|
1618
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_attestresult_free(ptr, 1));
|
|
1619
1619
|
const CRLFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1620
1620
|
? { register: () => {}, unregister: () => {} }
|
|
1621
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1621
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_crl_free(ptr, 1));
|
|
1622
1622
|
const ClientFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1623
1623
|
? { register: () => {}, unregister: () => {} }
|
|
1624
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_client_free(ptr
|
|
1624
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_client_free(ptr, 1));
|
|
1625
1625
|
const ClientBuilderFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1626
1626
|
? { register: () => {}, unregister: () => {} }
|
|
1627
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_clientbuilder_free(ptr
|
|
1627
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_clientbuilder_free(ptr, 1));
|
|
1628
1628
|
const CollateralFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1629
1629
|
? { register: () => {}, unregister: () => {} }
|
|
1630
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_collateral_free(ptr
|
|
1630
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_collateral_free(ptr, 1));
|
|
1631
1631
|
const DecodedClaimsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1632
1632
|
? { register: () => {}, unregister: () => {} }
|
|
1633
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1633
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_decodedclaims_free(ptr, 1));
|
|
1634
1634
|
const EATTokenFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1635
1635
|
? { register: () => {}, unregister: () => {} }
|
|
1636
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1636
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_eattoken_free(ptr, 1));
|
|
1637
1637
|
const ExportPemFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1638
1638
|
? { register: () => {}, unregister: () => {} }
|
|
1639
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1639
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_exportpem_free(ptr, 1));
|
|
1640
1640
|
const GatewayErrorFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1641
1641
|
? { register: () => {}, unregister: () => {} }
|
|
1642
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_gatewayerror_free(ptr
|
|
1642
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_gatewayerror_free(ptr, 1));
|
|
1643
1643
|
const KdsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1644
1644
|
? { register: () => {}, unregister: () => {} }
|
|
1645
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1645
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_kds_free(ptr, 1));
|
|
1646
1646
|
const KeyChainFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1647
1647
|
? { register: () => {}, unregister: () => {} }
|
|
1648
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1648
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_keychain_free(ptr, 1));
|
|
1649
1649
|
const ModulesFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1650
1650
|
? { register: () => {}, unregister: () => {} }
|
|
1651
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_modules_free(ptr
|
|
1651
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_modules_free(ptr, 1));
|
|
1652
1652
|
const NvidiaAttestResultFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1653
1653
|
? { register: () => {}, unregister: () => {} }
|
|
1654
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_nvidiaattestresult_free(ptr
|
|
1654
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_nvidiaattestresult_free(ptr, 1));
|
|
1655
1655
|
const NvidiaNonceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1656
1656
|
? { register: () => {}, unregister: () => {} }
|
|
1657
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1657
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_nvidianonce_free(ptr, 1));
|
|
1658
1658
|
const ParsedAttestationFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1659
1659
|
? { register: () => {}, unregister: () => {} }
|
|
1660
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1660
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_parsedattestation_free(ptr, 1));
|
|
1661
1661
|
const PcsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1662
1662
|
? { register: () => {}, unregister: () => {} }
|
|
1663
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_pcs_free(ptr
|
|
1663
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_pcs_free(ptr, 1));
|
|
1664
1664
|
const QueryParamsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1665
1665
|
? { register: () => {}, unregister: () => {} }
|
|
1666
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_queryparams_free(ptr
|
|
1666
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_queryparams_free(ptr, 1));
|
|
1667
1667
|
const QuoteVerifierFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1668
1668
|
? { register: () => {}, unregister: () => {} }
|
|
1669
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_quoteverifier_free(ptr
|
|
1669
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_quoteverifier_free(ptr, 1));
|
|
1670
1670
|
const ResponseHeadersFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1671
1671
|
? { register: () => {}, unregister: () => {} }
|
|
1672
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_responseheaders_free(ptr
|
|
1672
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_responseheaders_free(ptr, 1));
|
|
1673
1673
|
const SevNonceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1674
1674
|
? { register: () => {}, unregister: () => {} }
|
|
1675
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1675
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_sevnonce_free(ptr, 1));
|
|
1676
1676
|
const TcbLevelsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1677
1677
|
? { register: () => {}, unregister: () => {} }
|
|
1678
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_tcblevels_free(ptr
|
|
1678
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_tcblevels_free(ptr, 1));
|
|
1679
1679
|
const TdxNonceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1680
1680
|
? { register: () => {}, unregister: () => {} }
|
|
1681
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_tdxnonce_free(ptr
|
|
1681
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_tdxnonce_free(ptr, 1));
|
|
1682
1682
|
const TdxQuoteFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1683
1683
|
? { register: () => {}, unregister: () => {} }
|
|
1684
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_tdxquote_free(ptr
|
|
1684
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_tdxquote_free(ptr, 1));
|
|
1685
1685
|
const VerifiedChainFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1686
1686
|
? { register: () => {}, unregister: () => {} }
|
|
1687
|
-
: new FinalizationRegistry(ptr => wasm.
|
|
1687
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_verifiedchain_free(ptr, 1));
|
|
1688
1688
|
|
|
1689
1689
|
function addToExternrefTable0(obj) {
|
|
1690
1690
|
const idx = wasm.__externref_table_alloc();
|
|
@@ -1792,8 +1792,7 @@ function getDataViewMemory0() {
|
|
|
1792
1792
|
}
|
|
1793
1793
|
|
|
1794
1794
|
function getStringFromWasm0(ptr, len) {
|
|
1795
|
-
|
|
1796
|
-
return decodeText(ptr, len);
|
|
1795
|
+
return decodeText(ptr >>> 0, len);
|
|
1797
1796
|
}
|
|
1798
1797
|
|
|
1799
1798
|
let cachedUint8ArrayMemory0 = null;
|