@janssenproject/cedarling_wasm 0.0.338-nodejs → 0.0.339-nodejs
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/README.md +4 -25
- package/cedarling_wasm.d.ts +35 -21
- package/cedarling_wasm.js +275 -66
- package/cedarling_wasm_bg.wasm +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -46,14 +46,14 @@ After building WASM bindings in folder `pkg` you can find where you can find `ce
|
|
|
46
46
|
In `index.html` described simple usage of `cedarling wasm` API:
|
|
47
47
|
|
|
48
48
|
```js
|
|
49
|
-
import { BOOTSTRAP_CONFIG,
|
|
49
|
+
import { BOOTSTRAP_CONFIG, REQUEST_UNSIGNED } from "/example_data.js"; // Import js objects: bootstrap config and request
|
|
50
50
|
import initWasm, { init } from "/pkg/cedarling_wasm.js";
|
|
51
51
|
|
|
52
52
|
async function main() {
|
|
53
53
|
await initWasm(); // Initialize the WebAssembly module
|
|
54
54
|
|
|
55
55
|
let instance = await init(BOOTSTRAP_CONFIG);
|
|
56
|
-
let result = await instance.
|
|
56
|
+
let result = await instance.authorize_unsigned(REQUEST_UNSIGNED);
|
|
57
57
|
console.log("result:", result);
|
|
58
58
|
}
|
|
59
59
|
main().catch(console.error);
|
|
@@ -103,11 +103,6 @@ export class Cedarling {
|
|
|
103
103
|
* Assume that config is `Map`
|
|
104
104
|
*/
|
|
105
105
|
static new_from_map(config: Map<any, any>): Promise<Cedarling>;
|
|
106
|
-
/**
|
|
107
|
-
* Authorize request
|
|
108
|
-
* makes authorization decision based on the [`Request`]
|
|
109
|
-
*/
|
|
110
|
-
authorize(request: any): Promise<AuthorizeResult>;
|
|
111
106
|
/**
|
|
112
107
|
* Authorize request for unsigned principals.
|
|
113
108
|
* makes authorization decision based on the [`RequestUnsigned`]
|
|
@@ -257,13 +252,9 @@ export class AuthorizeResult {
|
|
|
257
252
|
*/
|
|
258
253
|
json_string(): string;
|
|
259
254
|
/**
|
|
260
|
-
*
|
|
261
|
-
*/
|
|
262
|
-
workload?: AuthorizeResultResponse;
|
|
263
|
-
/**
|
|
264
|
-
* Result of authorization where principal is `Jans::User`
|
|
255
|
+
* Get authorization responses for all principals
|
|
265
256
|
*/
|
|
266
|
-
|
|
257
|
+
principals: Record<string, AuthorizeResultResponse>;
|
|
267
258
|
/**
|
|
268
259
|
* Get result for a specific principal
|
|
269
260
|
*/
|
|
@@ -453,17 +444,6 @@ cd policy-store && zip -r ../policy-store.cjar .
|
|
|
453
444
|
|
|
454
445
|
See [Policy Store Formats](../../../docs/cedarling/reference/cedarling-policy-store.md#policy-store-formats) for details on the directory structure and metadata.json format.
|
|
455
446
|
|
|
456
|
-
### ID Token Trust Mode
|
|
457
|
-
|
|
458
|
-
The `CEDARLING_ID_TOKEN_TRUST_MODE` property controls how ID tokens are validated:
|
|
459
|
-
|
|
460
|
-
- **`strict`** (default): Enforces strict validation rules
|
|
461
|
-
- ID token `aud` must match access token `client_id`
|
|
462
|
-
- If userinfo token is present, its `sub` must match the ID token `sub`
|
|
463
|
-
- **`never`**: Disables ID token validation (useful for testing)
|
|
464
|
-
- **`always`**: Always validates ID tokens when present
|
|
465
|
-
- **`ifpresent`**: Validates ID tokens only if they are provided
|
|
466
|
-
|
|
467
447
|
### Testing Configuration
|
|
468
448
|
|
|
469
449
|
For testing scenarios, you may want to disable JWT validation. You can configure this in your bootstrap configuration:
|
|
@@ -472,7 +452,6 @@ For testing scenarios, you may want to disable JWT validation. You can configure
|
|
|
472
452
|
const BOOTSTRAP_CONFIG = {
|
|
473
453
|
CEDARLING_JWT_SIG_VALIDATION: "disabled",
|
|
474
454
|
CEDARLING_JWT_STATUS_VALIDATION: "disabled",
|
|
475
|
-
CEDARLING_ID_TOKEN_TRUST_MODE: "never",
|
|
476
455
|
};
|
|
477
456
|
```
|
|
478
457
|
|
package/cedarling_wasm.d.ts
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* The `ReadableStreamType` enum.
|
|
5
|
+
*
|
|
6
|
+
* *This API requires the following crate features to be activated: `ReadableStreamType`*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
type ReadableStreamType = "bytes";
|
|
3
10
|
|
|
4
11
|
/**
|
|
5
12
|
* A WASM wrapper for the Rust `cedarling::AuthorizeResult` struct.
|
|
@@ -22,26 +29,10 @@ export class AuthorizeResult {
|
|
|
22
29
|
* this field is [`bool`] type to be compatible with [authzen Access Evaluation Decision](https://openid.github.io/authzen/#section-6.2.1).
|
|
23
30
|
*/
|
|
24
31
|
decision: boolean;
|
|
25
|
-
/**
|
|
26
|
-
* Result of authorization where principal is `Jans::User`
|
|
27
|
-
*/
|
|
28
|
-
get person(): AuthorizeResultResponse | undefined;
|
|
29
|
-
/**
|
|
30
|
-
* Result of authorization where principal is `Jans::User`
|
|
31
|
-
*/
|
|
32
|
-
set person(value: AuthorizeResultResponse | null | undefined);
|
|
33
32
|
/**
|
|
34
33
|
* Request ID of the authorization request
|
|
35
34
|
*/
|
|
36
35
|
request_id: string;
|
|
37
|
-
/**
|
|
38
|
-
* Result of authorization where principal is `Jans::Workload`
|
|
39
|
-
*/
|
|
40
|
-
get workload(): AuthorizeResultResponse | undefined;
|
|
41
|
-
/**
|
|
42
|
-
* Result of authorization where principal is `Jans::Workload`
|
|
43
|
-
*/
|
|
44
|
-
set workload(value: AuthorizeResultResponse | null | undefined);
|
|
45
36
|
}
|
|
46
37
|
|
|
47
38
|
/**
|
|
@@ -69,11 +60,6 @@ export class Cedarling {
|
|
|
69
60
|
private constructor();
|
|
70
61
|
free(): void;
|
|
71
62
|
[Symbol.dispose](): void;
|
|
72
|
-
/**
|
|
73
|
-
* Authorize request
|
|
74
|
-
* makes authorization decision based on the [`Request`]
|
|
75
|
-
*/
|
|
76
|
-
authorize(request: any): Promise<AuthorizeResult>;
|
|
77
63
|
/**
|
|
78
64
|
* Authorize multi-issuer request.
|
|
79
65
|
* Makes authorization decision based on multiple JWT tokens from different issuers
|
|
@@ -362,6 +348,34 @@ export class Diagnostics {
|
|
|
362
348
|
readonly reason: string[];
|
|
363
349
|
}
|
|
364
350
|
|
|
351
|
+
export class IntoUnderlyingByteSource {
|
|
352
|
+
private constructor();
|
|
353
|
+
free(): void;
|
|
354
|
+
[Symbol.dispose](): void;
|
|
355
|
+
cancel(): void;
|
|
356
|
+
pull(controller: ReadableByteStreamController): Promise<any>;
|
|
357
|
+
start(controller: ReadableByteStreamController): void;
|
|
358
|
+
readonly autoAllocateChunkSize: number;
|
|
359
|
+
readonly type: ReadableStreamType;
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
export class IntoUnderlyingSink {
|
|
363
|
+
private constructor();
|
|
364
|
+
free(): void;
|
|
365
|
+
[Symbol.dispose](): void;
|
|
366
|
+
abort(reason: any): Promise<any>;
|
|
367
|
+
close(): Promise<any>;
|
|
368
|
+
write(chunk: any): Promise<any>;
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
export class IntoUnderlyingSource {
|
|
372
|
+
private constructor();
|
|
373
|
+
free(): void;
|
|
374
|
+
[Symbol.dispose](): void;
|
|
375
|
+
cancel(): void;
|
|
376
|
+
pull(controller: ReadableStreamDefaultController): Promise<any>;
|
|
377
|
+
}
|
|
378
|
+
|
|
365
379
|
/**
|
|
366
380
|
* A WASM wrapper for the Rust `cedarling::MultiIssuerAuthorizeResult` struct.
|
|
367
381
|
* Represents the result of a multi-issuer authorization request.
|
package/cedarling_wasm.js
CHANGED
|
@@ -60,14 +60,6 @@ class AuthorizeResult {
|
|
|
60
60
|
const ret = wasm.__wbg_get_authorizeresult_decision(this.__wbg_ptr);
|
|
61
61
|
return ret !== 0;
|
|
62
62
|
}
|
|
63
|
-
/**
|
|
64
|
-
* Result of authorization where principal is `Jans::User`
|
|
65
|
-
* @returns {AuthorizeResultResponse | undefined}
|
|
66
|
-
*/
|
|
67
|
-
get person() {
|
|
68
|
-
const ret = wasm.__wbg_get_authorizeresult_person(this.__wbg_ptr);
|
|
69
|
-
return ret === 0 ? undefined : AuthorizeResultResponse.__wrap(ret);
|
|
70
|
-
}
|
|
71
63
|
/**
|
|
72
64
|
* Request ID of the authorization request
|
|
73
65
|
* @returns {string}
|
|
@@ -84,14 +76,6 @@ class AuthorizeResult {
|
|
|
84
76
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
85
77
|
}
|
|
86
78
|
}
|
|
87
|
-
/**
|
|
88
|
-
* Result of authorization where principal is `Jans::Workload`
|
|
89
|
-
* @returns {AuthorizeResultResponse | undefined}
|
|
90
|
-
*/
|
|
91
|
-
get workload() {
|
|
92
|
-
const ret = wasm.__wbg_get_authorizeresult_workload(this.__wbg_ptr);
|
|
93
|
-
return ret === 0 ? undefined : AuthorizeResultResponse.__wrap(ret);
|
|
94
|
-
}
|
|
95
79
|
/**
|
|
96
80
|
* Result of authorization
|
|
97
81
|
* true means `ALLOW`
|
|
@@ -103,18 +87,6 @@ class AuthorizeResult {
|
|
|
103
87
|
set decision(arg0) {
|
|
104
88
|
wasm.__wbg_set_authorizeresult_decision(this.__wbg_ptr, arg0);
|
|
105
89
|
}
|
|
106
|
-
/**
|
|
107
|
-
* Result of authorization where principal is `Jans::User`
|
|
108
|
-
* @param {AuthorizeResultResponse | null} [arg0]
|
|
109
|
-
*/
|
|
110
|
-
set person(arg0) {
|
|
111
|
-
let ptr0 = 0;
|
|
112
|
-
if (!isLikeNone(arg0)) {
|
|
113
|
-
_assertClass(arg0, AuthorizeResultResponse);
|
|
114
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
115
|
-
}
|
|
116
|
-
wasm.__wbg_set_authorizeresult_person(this.__wbg_ptr, ptr0);
|
|
117
|
-
}
|
|
118
90
|
/**
|
|
119
91
|
* Request ID of the authorization request
|
|
120
92
|
* @param {string} arg0
|
|
@@ -124,18 +96,6 @@ class AuthorizeResult {
|
|
|
124
96
|
const len0 = WASM_VECTOR_LEN;
|
|
125
97
|
wasm.__wbg_set_authorizeresult_request_id(this.__wbg_ptr, ptr0, len0);
|
|
126
98
|
}
|
|
127
|
-
/**
|
|
128
|
-
* Result of authorization where principal is `Jans::Workload`
|
|
129
|
-
* @param {AuthorizeResultResponse | null} [arg0]
|
|
130
|
-
*/
|
|
131
|
-
set workload(arg0) {
|
|
132
|
-
let ptr0 = 0;
|
|
133
|
-
if (!isLikeNone(arg0)) {
|
|
134
|
-
_assertClass(arg0, AuthorizeResultResponse);
|
|
135
|
-
ptr0 = arg0.__destroy_into_raw();
|
|
136
|
-
}
|
|
137
|
-
wasm.__wbg_set_authorizeresult_workload(this.__wbg_ptr, ptr0);
|
|
138
|
-
}
|
|
139
99
|
}
|
|
140
100
|
if (Symbol.dispose) AuthorizeResult.prototype[Symbol.dispose] = AuthorizeResult.prototype.free;
|
|
141
101
|
exports.AuthorizeResult = AuthorizeResult;
|
|
@@ -203,16 +163,6 @@ class Cedarling {
|
|
|
203
163
|
const ptr = this.__destroy_into_raw();
|
|
204
164
|
wasm.__wbg_cedarling_free(ptr, 0);
|
|
205
165
|
}
|
|
206
|
-
/**
|
|
207
|
-
* Authorize request
|
|
208
|
-
* makes authorization decision based on the [`Request`]
|
|
209
|
-
* @param {any} request
|
|
210
|
-
* @returns {Promise<AuthorizeResult>}
|
|
211
|
-
*/
|
|
212
|
-
authorize(request) {
|
|
213
|
-
const ret = wasm.cedarling_authorize(this.__wbg_ptr, request);
|
|
214
|
-
return ret;
|
|
215
|
-
}
|
|
216
166
|
/**
|
|
217
167
|
* Authorize multi-issuer request.
|
|
218
168
|
* Makes authorization decision based on multiple JWT tokens from different issuers
|
|
@@ -924,6 +874,120 @@ class Diagnostics {
|
|
|
924
874
|
if (Symbol.dispose) Diagnostics.prototype[Symbol.dispose] = Diagnostics.prototype.free;
|
|
925
875
|
exports.Diagnostics = Diagnostics;
|
|
926
876
|
|
|
877
|
+
class IntoUnderlyingByteSource {
|
|
878
|
+
__destroy_into_raw() {
|
|
879
|
+
const ptr = this.__wbg_ptr;
|
|
880
|
+
this.__wbg_ptr = 0;
|
|
881
|
+
IntoUnderlyingByteSourceFinalization.unregister(this);
|
|
882
|
+
return ptr;
|
|
883
|
+
}
|
|
884
|
+
free() {
|
|
885
|
+
const ptr = this.__destroy_into_raw();
|
|
886
|
+
wasm.__wbg_intounderlyingbytesource_free(ptr, 0);
|
|
887
|
+
}
|
|
888
|
+
/**
|
|
889
|
+
* @returns {number}
|
|
890
|
+
*/
|
|
891
|
+
get autoAllocateChunkSize() {
|
|
892
|
+
const ret = wasm.intounderlyingbytesource_autoAllocateChunkSize(this.__wbg_ptr);
|
|
893
|
+
return ret >>> 0;
|
|
894
|
+
}
|
|
895
|
+
cancel() {
|
|
896
|
+
const ptr = this.__destroy_into_raw();
|
|
897
|
+
wasm.intounderlyingbytesource_cancel(ptr);
|
|
898
|
+
}
|
|
899
|
+
/**
|
|
900
|
+
* @param {ReadableByteStreamController} controller
|
|
901
|
+
* @returns {Promise<any>}
|
|
902
|
+
*/
|
|
903
|
+
pull(controller) {
|
|
904
|
+
const ret = wasm.intounderlyingbytesource_pull(this.__wbg_ptr, controller);
|
|
905
|
+
return ret;
|
|
906
|
+
}
|
|
907
|
+
/**
|
|
908
|
+
* @param {ReadableByteStreamController} controller
|
|
909
|
+
*/
|
|
910
|
+
start(controller) {
|
|
911
|
+
wasm.intounderlyingbytesource_start(this.__wbg_ptr, controller);
|
|
912
|
+
}
|
|
913
|
+
/**
|
|
914
|
+
* @returns {ReadableStreamType}
|
|
915
|
+
*/
|
|
916
|
+
get type() {
|
|
917
|
+
const ret = wasm.intounderlyingbytesource_type(this.__wbg_ptr);
|
|
918
|
+
return __wbindgen_enum_ReadableStreamType[ret];
|
|
919
|
+
}
|
|
920
|
+
}
|
|
921
|
+
if (Symbol.dispose) IntoUnderlyingByteSource.prototype[Symbol.dispose] = IntoUnderlyingByteSource.prototype.free;
|
|
922
|
+
exports.IntoUnderlyingByteSource = IntoUnderlyingByteSource;
|
|
923
|
+
|
|
924
|
+
class IntoUnderlyingSink {
|
|
925
|
+
__destroy_into_raw() {
|
|
926
|
+
const ptr = this.__wbg_ptr;
|
|
927
|
+
this.__wbg_ptr = 0;
|
|
928
|
+
IntoUnderlyingSinkFinalization.unregister(this);
|
|
929
|
+
return ptr;
|
|
930
|
+
}
|
|
931
|
+
free() {
|
|
932
|
+
const ptr = this.__destroy_into_raw();
|
|
933
|
+
wasm.__wbg_intounderlyingsink_free(ptr, 0);
|
|
934
|
+
}
|
|
935
|
+
/**
|
|
936
|
+
* @param {any} reason
|
|
937
|
+
* @returns {Promise<any>}
|
|
938
|
+
*/
|
|
939
|
+
abort(reason) {
|
|
940
|
+
const ptr = this.__destroy_into_raw();
|
|
941
|
+
const ret = wasm.intounderlyingsink_abort(ptr, reason);
|
|
942
|
+
return ret;
|
|
943
|
+
}
|
|
944
|
+
/**
|
|
945
|
+
* @returns {Promise<any>}
|
|
946
|
+
*/
|
|
947
|
+
close() {
|
|
948
|
+
const ptr = this.__destroy_into_raw();
|
|
949
|
+
const ret = wasm.intounderlyingsink_close(ptr);
|
|
950
|
+
return ret;
|
|
951
|
+
}
|
|
952
|
+
/**
|
|
953
|
+
* @param {any} chunk
|
|
954
|
+
* @returns {Promise<any>}
|
|
955
|
+
*/
|
|
956
|
+
write(chunk) {
|
|
957
|
+
const ret = wasm.intounderlyingsink_write(this.__wbg_ptr, chunk);
|
|
958
|
+
return ret;
|
|
959
|
+
}
|
|
960
|
+
}
|
|
961
|
+
if (Symbol.dispose) IntoUnderlyingSink.prototype[Symbol.dispose] = IntoUnderlyingSink.prototype.free;
|
|
962
|
+
exports.IntoUnderlyingSink = IntoUnderlyingSink;
|
|
963
|
+
|
|
964
|
+
class IntoUnderlyingSource {
|
|
965
|
+
__destroy_into_raw() {
|
|
966
|
+
const ptr = this.__wbg_ptr;
|
|
967
|
+
this.__wbg_ptr = 0;
|
|
968
|
+
IntoUnderlyingSourceFinalization.unregister(this);
|
|
969
|
+
return ptr;
|
|
970
|
+
}
|
|
971
|
+
free() {
|
|
972
|
+
const ptr = this.__destroy_into_raw();
|
|
973
|
+
wasm.__wbg_intounderlyingsource_free(ptr, 0);
|
|
974
|
+
}
|
|
975
|
+
cancel() {
|
|
976
|
+
const ptr = this.__destroy_into_raw();
|
|
977
|
+
wasm.intounderlyingsource_cancel(ptr);
|
|
978
|
+
}
|
|
979
|
+
/**
|
|
980
|
+
* @param {ReadableStreamDefaultController} controller
|
|
981
|
+
* @returns {Promise<any>}
|
|
982
|
+
*/
|
|
983
|
+
pull(controller) {
|
|
984
|
+
const ret = wasm.intounderlyingsource_pull(this.__wbg_ptr, controller);
|
|
985
|
+
return ret;
|
|
986
|
+
}
|
|
987
|
+
}
|
|
988
|
+
if (Symbol.dispose) IntoUnderlyingSource.prototype[Symbol.dispose] = IntoUnderlyingSource.prototype.free;
|
|
989
|
+
exports.IntoUnderlyingSource = IntoUnderlyingSource;
|
|
990
|
+
|
|
927
991
|
/**
|
|
928
992
|
* A WASM wrapper for the Rust `cedarling::MultiIssuerAuthorizeResult` struct.
|
|
929
993
|
* Represents the result of a multi-issuer authorization request.
|
|
@@ -1224,6 +1288,26 @@ function __wbg_get_imports() {
|
|
|
1224
1288
|
const ret = AuthorizeResult.__wrap(arg0);
|
|
1225
1289
|
return ret;
|
|
1226
1290
|
},
|
|
1291
|
+
__wbg_body_ac1dad652946e6da: function(arg0) {
|
|
1292
|
+
const ret = arg0.body;
|
|
1293
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1294
|
+
},
|
|
1295
|
+
__wbg_buffer_60b8043cd926067d: function(arg0) {
|
|
1296
|
+
const ret = arg0.buffer;
|
|
1297
|
+
return ret;
|
|
1298
|
+
},
|
|
1299
|
+
__wbg_byobRequest_6342e5f2b232c0f9: function(arg0) {
|
|
1300
|
+
const ret = arg0.byobRequest;
|
|
1301
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1302
|
+
},
|
|
1303
|
+
__wbg_byteLength_607b856aa6c5a508: function(arg0) {
|
|
1304
|
+
const ret = arg0.byteLength;
|
|
1305
|
+
return ret;
|
|
1306
|
+
},
|
|
1307
|
+
__wbg_byteOffset_b26b63681c83856c: function(arg0) {
|
|
1308
|
+
const ret = arg0.byteOffset;
|
|
1309
|
+
return ret;
|
|
1310
|
+
},
|
|
1227
1311
|
__wbg_call_2d781c1f4d5c0ef8: function() { return handleError(function (arg0, arg1, arg2) {
|
|
1228
1312
|
const ret = arg0.call(arg1, arg2);
|
|
1229
1313
|
return ret;
|
|
@@ -1232,14 +1316,32 @@ function __wbg_get_imports() {
|
|
|
1232
1316
|
const ret = arg0.call(arg1);
|
|
1233
1317
|
return ret;
|
|
1234
1318
|
}, arguments); },
|
|
1319
|
+
__wbg_cancel_79b3bea07a1028e7: function(arg0) {
|
|
1320
|
+
const ret = arg0.cancel();
|
|
1321
|
+
return ret;
|
|
1322
|
+
},
|
|
1323
|
+
__wbg_catch_d7ed0375ab6532a5: function(arg0, arg1) {
|
|
1324
|
+
const ret = arg0.catch(arg1);
|
|
1325
|
+
return ret;
|
|
1326
|
+
},
|
|
1235
1327
|
__wbg_cedarling_new: function(arg0) {
|
|
1236
1328
|
const ret = Cedarling.__wrap(arg0);
|
|
1237
1329
|
return ret;
|
|
1238
1330
|
},
|
|
1331
|
+
__wbg_clearTimeout_1d1b13f4034f30ca: function(arg0) {
|
|
1332
|
+
const ret = clearTimeout(arg0);
|
|
1333
|
+
return ret;
|
|
1334
|
+
},
|
|
1239
1335
|
__wbg_clearTimeout_2256f1e7b94ef517: function(arg0) {
|
|
1240
1336
|
const ret = clearTimeout(arg0);
|
|
1241
1337
|
return ret;
|
|
1242
1338
|
},
|
|
1339
|
+
__wbg_close_690d36108c557337: function() { return handleError(function (arg0) {
|
|
1340
|
+
arg0.close();
|
|
1341
|
+
}, arguments); },
|
|
1342
|
+
__wbg_close_737b4b1fbc658540: function() { return handleError(function (arg0) {
|
|
1343
|
+
arg0.close();
|
|
1344
|
+
}, arguments); },
|
|
1243
1345
|
__wbg_crypto_38df2bab126b63dc: function(arg0) {
|
|
1244
1346
|
const ret = arg0.crypto;
|
|
1245
1347
|
return ret;
|
|
@@ -1255,6 +1357,9 @@ function __wbg_get_imports() {
|
|
|
1255
1357
|
const ret = arg0.done;
|
|
1256
1358
|
return ret;
|
|
1257
1359
|
},
|
|
1360
|
+
__wbg_enqueue_ec3552838b4b7fbf: function() { return handleError(function (arg0, arg1) {
|
|
1361
|
+
arg0.enqueue(arg1);
|
|
1362
|
+
}, arguments); },
|
|
1258
1363
|
__wbg_entries_5b8fe91cea59610e: function(arg0) {
|
|
1259
1364
|
const ret = arg0.entries();
|
|
1260
1365
|
return ret;
|
|
@@ -1270,6 +1375,10 @@ function __wbg_get_imports() {
|
|
|
1270
1375
|
__wbg_error_b282edc683808929: function(arg0) {
|
|
1271
1376
|
console.error(...arg0);
|
|
1272
1377
|
},
|
|
1378
|
+
__wbg_fetch_010aa16f24b763bc: function(arg0, arg1) {
|
|
1379
|
+
const ret = fetch(arg0, arg1);
|
|
1380
|
+
return ret;
|
|
1381
|
+
},
|
|
1273
1382
|
__wbg_fetch_43b2f110608a59ff: function(arg0) {
|
|
1274
1383
|
const ret = fetch(arg0);
|
|
1275
1384
|
return ret;
|
|
@@ -1278,6 +1387,10 @@ function __wbg_get_imports() {
|
|
|
1278
1387
|
const ret = arg0.fetch(arg1);
|
|
1279
1388
|
return ret;
|
|
1280
1389
|
},
|
|
1390
|
+
__wbg_fetch_d77cded604d729e9: function(arg0, arg1, arg2) {
|
|
1391
|
+
const ret = arg0.fetch(arg1, arg2);
|
|
1392
|
+
return ret;
|
|
1393
|
+
},
|
|
1281
1394
|
__wbg_fromEntries_8f078e02a548e8eb: function() { return handleError(function (arg0) {
|
|
1282
1395
|
const ret = Object.fromEntries(arg0);
|
|
1283
1396
|
return ret;
|
|
@@ -1288,6 +1401,10 @@ function __wbg_get_imports() {
|
|
|
1288
1401
|
__wbg_getRandomValues_c44a50d8cfdaebeb: function() { return handleError(function (arg0, arg1) {
|
|
1289
1402
|
arg0.getRandomValues(arg1);
|
|
1290
1403
|
}, arguments); },
|
|
1404
|
+
__wbg_getReader_9facd4f899beac89: function() { return handleError(function (arg0) {
|
|
1405
|
+
const ret = arg0.getReader();
|
|
1406
|
+
return ret;
|
|
1407
|
+
}, arguments); },
|
|
1291
1408
|
__wbg_getTime_1dad7b5386ddd2d9: function(arg0) {
|
|
1292
1409
|
const ret = arg0.getTime();
|
|
1293
1410
|
return ret;
|
|
@@ -1308,10 +1425,18 @@ function __wbg_get_imports() {
|
|
|
1308
1425
|
const ret = arg0[arg1 >>> 0];
|
|
1309
1426
|
return ret;
|
|
1310
1427
|
},
|
|
1428
|
+
__wbg_get_done_d0ab690f8df5501f: function(arg0) {
|
|
1429
|
+
const ret = arg0.done;
|
|
1430
|
+
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
1431
|
+
},
|
|
1311
1432
|
__wbg_get_unchecked_329cfe50afab7352: function(arg0, arg1) {
|
|
1312
1433
|
const ret = arg0[arg1 >>> 0];
|
|
1313
1434
|
return ret;
|
|
1314
1435
|
},
|
|
1436
|
+
__wbg_get_value_548ae6adf5a174e4: function(arg0) {
|
|
1437
|
+
const ret = arg0.value;
|
|
1438
|
+
return ret;
|
|
1439
|
+
},
|
|
1315
1440
|
__wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
|
|
1316
1441
|
const ret = arg0[arg1];
|
|
1317
1442
|
return ret;
|
|
@@ -1440,6 +1565,10 @@ function __wbg_get_imports() {
|
|
|
1440
1565
|
const ret = new AbortController();
|
|
1441
1566
|
return ret;
|
|
1442
1567
|
}, arguments); },
|
|
1568
|
+
__wbg_new_d15cb560a6a0e5f0: function(arg0, arg1) {
|
|
1569
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
1570
|
+
return ret;
|
|
1571
|
+
},
|
|
1443
1572
|
__wbg_new_fd94ca5c9639abd2: function(arg0) {
|
|
1444
1573
|
const ret = new Date(arg0);
|
|
1445
1574
|
return ret;
|
|
@@ -1455,7 +1584,7 @@ function __wbg_get_imports() {
|
|
|
1455
1584
|
const a = state0.a;
|
|
1456
1585
|
state0.a = 0;
|
|
1457
1586
|
try {
|
|
1458
|
-
return
|
|
1587
|
+
return wasm_bindgen__convert__closures_____invoke__h17a92308e79e69c0(a, state0.b, arg0, arg1);
|
|
1459
1588
|
} finally {
|
|
1460
1589
|
state0.a = a;
|
|
1461
1590
|
}
|
|
@@ -1466,6 +1595,10 @@ function __wbg_get_imports() {
|
|
|
1466
1595
|
state0.a = state0.b = 0;
|
|
1467
1596
|
}
|
|
1468
1597
|
},
|
|
1598
|
+
__wbg_new_with_byte_offset_and_length_b2ec5bf7b2f35743: function(arg0, arg1, arg2) {
|
|
1599
|
+
const ret = new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
1600
|
+
return ret;
|
|
1601
|
+
},
|
|
1469
1602
|
__wbg_new_with_length_825018a1616e9e55: function(arg0) {
|
|
1470
1603
|
const ret = new Uint8Array(arg0 >>> 0);
|
|
1471
1604
|
return ret;
|
|
@@ -1511,6 +1644,13 @@ function __wbg_get_imports() {
|
|
|
1511
1644
|
__wbg_randomFillSync_6c25eac9869eb53c: function() { return handleError(function (arg0, arg1) {
|
|
1512
1645
|
arg0.randomFillSync(arg1);
|
|
1513
1646
|
}, arguments); },
|
|
1647
|
+
__wbg_read_7f593a961a7f80ed: function(arg0) {
|
|
1648
|
+
const ret = arg0.read();
|
|
1649
|
+
return ret;
|
|
1650
|
+
},
|
|
1651
|
+
__wbg_releaseLock_ef7766a5da654ff8: function(arg0) {
|
|
1652
|
+
arg0.releaseLock();
|
|
1653
|
+
},
|
|
1514
1654
|
__wbg_require_b4edbdcf3e2a1ef0: function() { return handleError(function () {
|
|
1515
1655
|
const ret = module.require;
|
|
1516
1656
|
return ret;
|
|
@@ -1519,6 +1659,13 @@ function __wbg_get_imports() {
|
|
|
1519
1659
|
const ret = Promise.resolve(arg0);
|
|
1520
1660
|
return ret;
|
|
1521
1661
|
},
|
|
1662
|
+
__wbg_respond_e286ee502e7cf7e4: function() { return handleError(function (arg0, arg1) {
|
|
1663
|
+
arg0.respond(arg1 >>> 0);
|
|
1664
|
+
}, arguments); },
|
|
1665
|
+
__wbg_setTimeout_a3127d9f29a851c3: function(arg0, arg1) {
|
|
1666
|
+
const ret = setTimeout(arg0, arg1);
|
|
1667
|
+
return ret;
|
|
1668
|
+
},
|
|
1522
1669
|
__wbg_setTimeout_b188b3bcc8977c7d: function(arg0, arg1) {
|
|
1523
1670
|
const ret = setTimeout(arg0, arg1);
|
|
1524
1671
|
return ret;
|
|
@@ -1533,6 +1680,9 @@ function __wbg_get_imports() {
|
|
|
1533
1680
|
const ret = Reflect.set(arg0, arg1, arg2);
|
|
1534
1681
|
return ret;
|
|
1535
1682
|
}, arguments); },
|
|
1683
|
+
__wbg_set_8c0b3ffcf05d61c2: function(arg0, arg1, arg2) {
|
|
1684
|
+
arg0.set(getArrayU8FromWasm0(arg1, arg2));
|
|
1685
|
+
},
|
|
1536
1686
|
__wbg_set_bf7251625df30a02: function(arg0, arg1, arg2) {
|
|
1537
1687
|
const ret = arg0.set(arg1, arg2);
|
|
1538
1688
|
return ret;
|
|
@@ -1546,15 +1696,30 @@ function __wbg_get_imports() {
|
|
|
1546
1696
|
__wbg_set_credentials_ed63183445882c65: function(arg0, arg1) {
|
|
1547
1697
|
arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
|
|
1548
1698
|
},
|
|
1699
|
+
__wbg_set_e09648bea3f1af1e: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
1700
|
+
arg0.set(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
1701
|
+
}, arguments); },
|
|
1549
1702
|
__wbg_set_headers_3c8fecc693b75327: function(arg0, arg1) {
|
|
1550
1703
|
arg0.headers = arg1;
|
|
1551
1704
|
},
|
|
1705
|
+
__wbg_set_integrity_6e605069e31cef0a: function(arg0, arg1, arg2) {
|
|
1706
|
+
arg0.integrity = getStringFromWasm0(arg1, arg2);
|
|
1707
|
+
},
|
|
1552
1708
|
__wbg_set_method_8c015e8bcafd7be1: function(arg0, arg1, arg2) {
|
|
1553
1709
|
arg0.method = getStringFromWasm0(arg1, arg2);
|
|
1554
1710
|
},
|
|
1555
1711
|
__wbg_set_mode_5a87f2c809cf37c2: function(arg0, arg1) {
|
|
1556
1712
|
arg0.mode = __wbindgen_enum_RequestMode[arg1];
|
|
1557
1713
|
},
|
|
1714
|
+
__wbg_set_redirect_c7b340412376b11a: function(arg0, arg1) {
|
|
1715
|
+
arg0.redirect = __wbindgen_enum_RequestRedirect[arg1];
|
|
1716
|
+
},
|
|
1717
|
+
__wbg_set_referrer_4f2f273104bee6d0: function(arg0, arg1, arg2) {
|
|
1718
|
+
arg0.referrer = getStringFromWasm0(arg1, arg2);
|
|
1719
|
+
},
|
|
1720
|
+
__wbg_set_referrer_policy_3cea8b6e31a9e636: function(arg0, arg1) {
|
|
1721
|
+
arg0.referrerPolicy = __wbindgen_enum_ReferrerPolicy[arg1];
|
|
1722
|
+
},
|
|
1558
1723
|
__wbg_set_signal_0cebecb698f25d21: function(arg0, arg1) {
|
|
1559
1724
|
arg0.signal = arg1;
|
|
1560
1725
|
},
|
|
@@ -1598,6 +1763,10 @@ function __wbg_get_imports() {
|
|
|
1598
1763
|
const ret = arg0.then(arg1, arg2);
|
|
1599
1764
|
return ret;
|
|
1600
1765
|
},
|
|
1766
|
+
__wbg_toString_3272fa0dfd05dd87: function(arg0) {
|
|
1767
|
+
const ret = arg0.toString();
|
|
1768
|
+
return ret;
|
|
1769
|
+
},
|
|
1601
1770
|
__wbg_trace_e81c2d096c740f11: function(arg0) {
|
|
1602
1771
|
console.trace(...arg0);
|
|
1603
1772
|
},
|
|
@@ -1616,40 +1785,54 @@ function __wbg_get_imports() {
|
|
|
1616
1785
|
const ret = arg0.versions;
|
|
1617
1786
|
return ret;
|
|
1618
1787
|
},
|
|
1788
|
+
__wbg_view_f68a712e7315f8b2: function(arg0) {
|
|
1789
|
+
const ret = arg0.view;
|
|
1790
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1791
|
+
},
|
|
1619
1792
|
__wbg_warn_ff4a30433095bbe4: function(arg0) {
|
|
1620
1793
|
console.warn(...arg0);
|
|
1621
1794
|
},
|
|
1622
1795
|
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
1623
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx:
|
|
1624
|
-
const ret = makeMutClosure(arg0, arg1, wasm.
|
|
1796
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 595, function: Function { arguments: [], shim_idx: 596, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1797
|
+
const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__hcbf2ec2b115651da, wasm_bindgen__convert__closures_____invoke__h09da5be58b802521);
|
|
1625
1798
|
return ret;
|
|
1626
1799
|
},
|
|
1627
1800
|
__wbindgen_cast_0000000000000002: function(arg0, arg1) {
|
|
1628
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx:
|
|
1629
|
-
const ret = makeMutClosure(arg0, arg1, wasm.
|
|
1801
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 640, function: Function { arguments: [Externref], shim_idx: 641, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1802
|
+
const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__hb94dbe4a47b9147c, wasm_bindgen__convert__closures_____invoke__hdb4e3955a815023f);
|
|
1803
|
+
return ret;
|
|
1804
|
+
},
|
|
1805
|
+
__wbindgen_cast_0000000000000003: function(arg0, arg1) {
|
|
1806
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 752, function: Function { arguments: [], shim_idx: 753, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1807
|
+
const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__hd11c5dfc6ff843b5, wasm_bindgen__convert__closures_____invoke__h5ac545e984d2dde4);
|
|
1630
1808
|
return ret;
|
|
1631
1809
|
},
|
|
1632
|
-
|
|
1810
|
+
__wbindgen_cast_0000000000000004: function(arg0, arg1) {
|
|
1811
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 794, function: Function { arguments: [Externref], shim_idx: 2224, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
1812
|
+
const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__h14227e6b7ccdc7d9, wasm_bindgen__convert__closures_____invoke__hce0de7781e15b6ff);
|
|
1813
|
+
return ret;
|
|
1814
|
+
},
|
|
1815
|
+
__wbindgen_cast_0000000000000005: function(arg0) {
|
|
1633
1816
|
// Cast intrinsic for `F64 -> Externref`.
|
|
1634
1817
|
const ret = arg0;
|
|
1635
1818
|
return ret;
|
|
1636
1819
|
},
|
|
1637
|
-
|
|
1820
|
+
__wbindgen_cast_0000000000000006: function(arg0) {
|
|
1638
1821
|
// Cast intrinsic for `I64 -> Externref`.
|
|
1639
1822
|
const ret = arg0;
|
|
1640
1823
|
return ret;
|
|
1641
1824
|
},
|
|
1642
|
-
|
|
1825
|
+
__wbindgen_cast_0000000000000007: function(arg0, arg1) {
|
|
1643
1826
|
// Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
|
|
1644
1827
|
const ret = getArrayU8FromWasm0(arg0, arg1);
|
|
1645
1828
|
return ret;
|
|
1646
1829
|
},
|
|
1647
|
-
|
|
1830
|
+
__wbindgen_cast_0000000000000008: function(arg0, arg1) {
|
|
1648
1831
|
// Cast intrinsic for `Ref(String) -> Externref`.
|
|
1649
1832
|
const ret = getStringFromWasm0(arg0, arg1);
|
|
1650
1833
|
return ret;
|
|
1651
1834
|
},
|
|
1652
|
-
|
|
1835
|
+
__wbindgen_cast_0000000000000009: function(arg0) {
|
|
1653
1836
|
// Cast intrinsic for `U64 -> Externref`.
|
|
1654
1837
|
const ret = BigInt.asUintN(64, arg0);
|
|
1655
1838
|
return ret;
|
|
@@ -1670,22 +1853,36 @@ function __wbg_get_imports() {
|
|
|
1670
1853
|
};
|
|
1671
1854
|
}
|
|
1672
1855
|
|
|
1673
|
-
function
|
|
1674
|
-
wasm.
|
|
1856
|
+
function wasm_bindgen__convert__closures_____invoke__h09da5be58b802521(arg0, arg1) {
|
|
1857
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h09da5be58b802521(arg0, arg1);
|
|
1858
|
+
}
|
|
1859
|
+
|
|
1860
|
+
function wasm_bindgen__convert__closures_____invoke__h5ac545e984d2dde4(arg0, arg1) {
|
|
1861
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h5ac545e984d2dde4(arg0, arg1);
|
|
1862
|
+
}
|
|
1863
|
+
|
|
1864
|
+
function wasm_bindgen__convert__closures_____invoke__hdb4e3955a815023f(arg0, arg1, arg2) {
|
|
1865
|
+
wasm.wasm_bindgen__convert__closures_____invoke__hdb4e3955a815023f(arg0, arg1, arg2);
|
|
1675
1866
|
}
|
|
1676
1867
|
|
|
1677
|
-
function
|
|
1678
|
-
const ret = wasm.
|
|
1868
|
+
function wasm_bindgen__convert__closures_____invoke__hce0de7781e15b6ff(arg0, arg1, arg2) {
|
|
1869
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__hce0de7781e15b6ff(arg0, arg1, arg2);
|
|
1679
1870
|
if (ret[1]) {
|
|
1680
1871
|
throw takeFromExternrefTable0(ret[0]);
|
|
1681
1872
|
}
|
|
1682
1873
|
}
|
|
1683
1874
|
|
|
1684
|
-
function
|
|
1685
|
-
wasm.
|
|
1875
|
+
function wasm_bindgen__convert__closures_____invoke__h17a92308e79e69c0(arg0, arg1, arg2, arg3) {
|
|
1876
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h17a92308e79e69c0(arg0, arg1, arg2, arg3);
|
|
1686
1877
|
}
|
|
1687
1878
|
|
|
1688
1879
|
|
|
1880
|
+
const __wbindgen_enum_ReadableStreamType = ["bytes"];
|
|
1881
|
+
|
|
1882
|
+
|
|
1883
|
+
const __wbindgen_enum_ReferrerPolicy = ["", "no-referrer", "no-referrer-when-downgrade", "origin", "origin-when-cross-origin", "unsafe-url", "same-origin", "strict-origin", "strict-origin-when-cross-origin"];
|
|
1884
|
+
|
|
1885
|
+
|
|
1689
1886
|
const __wbindgen_enum_RequestCache = ["default", "no-store", "reload", "no-cache", "force-cache", "only-if-cached"];
|
|
1690
1887
|
|
|
1691
1888
|
|
|
@@ -1693,6 +1890,9 @@ const __wbindgen_enum_RequestCredentials = ["omit", "same-origin", "include"];
|
|
|
1693
1890
|
|
|
1694
1891
|
|
|
1695
1892
|
const __wbindgen_enum_RequestMode = ["same-origin", "no-cors", "cors", "navigate"];
|
|
1893
|
+
|
|
1894
|
+
|
|
1895
|
+
const __wbindgen_enum_RequestRedirect = ["follow", "error", "manual"];
|
|
1696
1896
|
const AuthorizeResultFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1697
1897
|
? { register: () => {}, unregister: () => {} }
|
|
1698
1898
|
: new FinalizationRegistry(ptr => wasm.__wbg_authorizeresult_free(ptr >>> 0, 1));
|
|
@@ -1711,6 +1911,15 @@ const DataStoreStatsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
|
1711
1911
|
const DiagnosticsFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1712
1912
|
? { register: () => {}, unregister: () => {} }
|
|
1713
1913
|
: new FinalizationRegistry(ptr => wasm.__wbg_diagnostics_free(ptr >>> 0, 1));
|
|
1914
|
+
const IntoUnderlyingByteSourceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1915
|
+
? { register: () => {}, unregister: () => {} }
|
|
1916
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingbytesource_free(ptr >>> 0, 1));
|
|
1917
|
+
const IntoUnderlyingSinkFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1918
|
+
? { register: () => {}, unregister: () => {} }
|
|
1919
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingsink_free(ptr >>> 0, 1));
|
|
1920
|
+
const IntoUnderlyingSourceFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1921
|
+
? { register: () => {}, unregister: () => {} }
|
|
1922
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingsource_free(ptr >>> 0, 1));
|
|
1714
1923
|
const MultiIssuerAuthorizeResultFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
1715
1924
|
? { register: () => {}, unregister: () => {} }
|
|
1716
1925
|
: new FinalizationRegistry(ptr => wasm.__wbg_multiissuerauthorizeresult_free(ptr >>> 0, 1));
|
package/cedarling_wasm_bg.wasm
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@janssenproject/cedarling_wasm",
|
|
3
3
|
"description": "The Cedarling is a performant local authorization service that runs the Rust Cedar Engine",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.339-nodejs",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|