@bitwarden/commercial-sdk-internal 0.2.0-main.374 → 0.2.0-main.376
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/bitwarden_wasm_internal.d.ts +20 -1
- package/bitwarden_wasm_internal_bg.js +61 -37
- package/bitwarden_wasm_internal_bg.wasm +0 -0
- package/bitwarden_wasm_internal_bg.wasm.d.ts +9 -8
- package/bitwarden_wasm_internal_bg.wasm.js +1 -1
- package/node/bitwarden_wasm_internal.d.ts +20 -1
- package/node/bitwarden_wasm_internal.js +61 -37
- package/node/bitwarden_wasm_internal_bg.wasm +0 -0
- package/node/bitwarden_wasm_internal_bg.wasm.d.ts +6 -5
- package/package.json +1 -1
|
@@ -974,6 +974,12 @@ export interface IpcCommunicationBackendSender {
|
|
|
974
974
|
send(message: OutgoingMessage): Promise<void>;
|
|
975
975
|
}
|
|
976
976
|
|
|
977
|
+
export interface IpcSessionRepository {
|
|
978
|
+
get(endpoint: Endpoint): Promise<any | undefined>;
|
|
979
|
+
save(endpoint: Endpoint, session: any): Promise<void>;
|
|
980
|
+
remove(endpoint: Endpoint): Promise<void>;
|
|
981
|
+
}
|
|
982
|
+
|
|
977
983
|
export interface ChannelError extends Error {
|
|
978
984
|
name: "ChannelError";
|
|
979
985
|
}
|
|
@@ -2243,9 +2249,22 @@ export class IncomingMessage {
|
|
|
2243
2249
|
* [IpcClient] documentation.
|
|
2244
2250
|
*/
|
|
2245
2251
|
export class IpcClient {
|
|
2252
|
+
private constructor();
|
|
2246
2253
|
free(): void;
|
|
2247
2254
|
[Symbol.dispose](): void;
|
|
2248
|
-
|
|
2255
|
+
/**
|
|
2256
|
+
* Create a new `IpcClient` instance with an in-memory session repository for saving
|
|
2257
|
+
* sessions within the SDK.
|
|
2258
|
+
*/
|
|
2259
|
+
static newWithSdkInMemorySessions(communication_provider: IpcCommunicationBackend): IpcClient;
|
|
2260
|
+
/**
|
|
2261
|
+
* Create a new `IpcClient` instance with a client-managed session repository for saving
|
|
2262
|
+
* sessions using State Provider.
|
|
2263
|
+
*/
|
|
2264
|
+
static newWithClientManagedSessions(
|
|
2265
|
+
communication_provider: IpcCommunicationBackend,
|
|
2266
|
+
session_repository: IpcSessionRepository,
|
|
2267
|
+
): IpcClient;
|
|
2249
2268
|
start(): Promise<void>;
|
|
2250
2269
|
isRunning(): Promise<boolean>;
|
|
2251
2270
|
send(message: OutgoingMessage): Promise<void>;
|
|
@@ -875,18 +875,6 @@ export function isEncryptFileError(error) {
|
|
|
875
875
|
}
|
|
876
876
|
}
|
|
877
877
|
|
|
878
|
-
function wasm_bindgen__convert__closures_____invoke__h76c71c1158b6af01(arg0, arg1) {
|
|
879
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h76c71c1158b6af01(arg0, arg1);
|
|
880
|
-
}
|
|
881
|
-
|
|
882
|
-
function wasm_bindgen__convert__closures_____invoke__h4f8d9ba9b5b9a009(arg0, arg1, arg2) {
|
|
883
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h4f8d9ba9b5b9a009(
|
|
884
|
-
arg0,
|
|
885
|
-
arg1,
|
|
886
|
-
addHeapObject(arg2),
|
|
887
|
-
);
|
|
888
|
-
}
|
|
889
|
-
|
|
890
878
|
function wasm_bindgen__convert__closures_____invoke__hf869d8564f5adb52(arg0, arg1, arg2) {
|
|
891
879
|
try {
|
|
892
880
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
@@ -906,6 +894,18 @@ function wasm_bindgen__convert__closures_____invoke__hf869d8564f5adb52(arg0, arg
|
|
|
906
894
|
}
|
|
907
895
|
}
|
|
908
896
|
|
|
897
|
+
function wasm_bindgen__convert__closures_____invoke__h76c71c1158b6af01(arg0, arg1) {
|
|
898
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h76c71c1158b6af01(arg0, arg1);
|
|
899
|
+
}
|
|
900
|
+
|
|
901
|
+
function wasm_bindgen__convert__closures_____invoke__h4f8d9ba9b5b9a009(arg0, arg1, arg2) {
|
|
902
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h4f8d9ba9b5b9a009(
|
|
903
|
+
arg0,
|
|
904
|
+
arg1,
|
|
905
|
+
addHeapObject(arg2),
|
|
906
|
+
);
|
|
907
|
+
}
|
|
908
|
+
|
|
909
909
|
function wasm_bindgen__convert__closures_____invoke__h4096c3b930b983e7(arg0, arg1, arg2, arg3) {
|
|
910
910
|
wasm.wasm_bindgen__convert__closures_____invoke__h4096c3b930b983e7(
|
|
911
911
|
arg0,
|
|
@@ -2914,6 +2914,14 @@ const IpcClientFinalization =
|
|
|
2914
2914
|
* [IpcClient] documentation.
|
|
2915
2915
|
*/
|
|
2916
2916
|
export class IpcClient {
|
|
2917
|
+
static __wrap(ptr) {
|
|
2918
|
+
ptr = ptr >>> 0;
|
|
2919
|
+
const obj = Object.create(IpcClient.prototype);
|
|
2920
|
+
obj.__wbg_ptr = ptr;
|
|
2921
|
+
IpcClientFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
2922
|
+
return obj;
|
|
2923
|
+
}
|
|
2924
|
+
|
|
2917
2925
|
__destroy_into_raw() {
|
|
2918
2926
|
const ptr = this.__wbg_ptr;
|
|
2919
2927
|
this.__wbg_ptr = 0;
|
|
@@ -2926,14 +2934,30 @@ export class IpcClient {
|
|
|
2926
2934
|
wasm.__wbg_ipcclient_free(ptr, 0);
|
|
2927
2935
|
}
|
|
2928
2936
|
/**
|
|
2937
|
+
* Create a new `IpcClient` instance with an in-memory session repository for saving
|
|
2938
|
+
* sessions within the SDK.
|
|
2929
2939
|
* @param {IpcCommunicationBackend} communication_provider
|
|
2940
|
+
* @returns {IpcClient}
|
|
2930
2941
|
*/
|
|
2931
|
-
|
|
2942
|
+
static newWithSdkInMemorySessions(communication_provider) {
|
|
2932
2943
|
_assertClass(communication_provider, IpcCommunicationBackend);
|
|
2933
|
-
const ret = wasm.
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2944
|
+
const ret = wasm.ipcclient_newWithSdkInMemorySessions(communication_provider.__wbg_ptr);
|
|
2945
|
+
return IpcClient.__wrap(ret);
|
|
2946
|
+
}
|
|
2947
|
+
/**
|
|
2948
|
+
* Create a new `IpcClient` instance with a client-managed session repository for saving
|
|
2949
|
+
* sessions using State Provider.
|
|
2950
|
+
* @param {IpcCommunicationBackend} communication_provider
|
|
2951
|
+
* @param {IpcSessionRepository} session_repository
|
|
2952
|
+
* @returns {IpcClient}
|
|
2953
|
+
*/
|
|
2954
|
+
static newWithClientManagedSessions(communication_provider, session_repository) {
|
|
2955
|
+
_assertClass(communication_provider, IpcCommunicationBackend);
|
|
2956
|
+
const ret = wasm.ipcclient_newWithClientManagedSessions(
|
|
2957
|
+
communication_provider.__wbg_ptr,
|
|
2958
|
+
addHeapObject(session_repository),
|
|
2959
|
+
);
|
|
2960
|
+
return IpcClient.__wrap(ret);
|
|
2937
2961
|
}
|
|
2938
2962
|
/**
|
|
2939
2963
|
* @returns {Promise<void>}
|
|
@@ -4489,7 +4513,7 @@ export function __wbg_call_e762c39fa8ea36bf() {
|
|
|
4489
4513
|
}, arguments);
|
|
4490
4514
|
}
|
|
4491
4515
|
|
|
4492
|
-
export function
|
|
4516
|
+
export function __wbg_cipher_9701deafaff968bd(arg0) {
|
|
4493
4517
|
const ret = getObject(arg0).cipher;
|
|
4494
4518
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4495
4519
|
}
|
|
@@ -4569,7 +4593,7 @@ export function __wbg_fetch_f8ba0e29a9d6de0d(arg0, arg1) {
|
|
|
4569
4593
|
return addHeapObject(ret);
|
|
4570
4594
|
}
|
|
4571
4595
|
|
|
4572
|
-
export function
|
|
4596
|
+
export function __wbg_folder_0ac974e0faeac5a3(arg0) {
|
|
4573
4597
|
const ret = getObject(arg0).folder;
|
|
4574
4598
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4575
4599
|
}
|
|
@@ -4596,12 +4620,7 @@ export function __wbg_getTime_14776bfb48a1bff9(arg0) {
|
|
|
4596
4620
|
return ret;
|
|
4597
4621
|
}
|
|
4598
4622
|
|
|
4599
|
-
export function
|
|
4600
|
-
const ret = getObject(arg0)[arg1 >>> 0];
|
|
4601
|
-
return addHeapObject(ret);
|
|
4602
|
-
}
|
|
4603
|
-
|
|
4604
|
-
export function __wbg_get_905bbb36d78e816c() {
|
|
4623
|
+
export function __wbg_get_18698e0d6fcbb417() {
|
|
4605
4624
|
return handleError(function (arg0, arg1, arg2) {
|
|
4606
4625
|
let deferred0_0;
|
|
4607
4626
|
let deferred0_1;
|
|
@@ -4616,12 +4635,7 @@ export function __wbg_get_905bbb36d78e816c() {
|
|
|
4616
4635
|
}, arguments);
|
|
4617
4636
|
}
|
|
4618
4637
|
|
|
4619
|
-
export function
|
|
4620
|
-
const ret = getObject(arg0).get_access_token();
|
|
4621
|
-
return addHeapObject(ret);
|
|
4622
|
-
}
|
|
4623
|
-
|
|
4624
|
-
export function __wbg_get_eb8ca7ea2e1397a3() {
|
|
4638
|
+
export function __wbg_get_30883f9918eff6a9() {
|
|
4625
4639
|
return handleError(function (arg0, arg1, arg2) {
|
|
4626
4640
|
let deferred0_0;
|
|
4627
4641
|
let deferred0_1;
|
|
@@ -4636,6 +4650,16 @@ export function __wbg_get_eb8ca7ea2e1397a3() {
|
|
|
4636
4650
|
}, arguments);
|
|
4637
4651
|
}
|
|
4638
4652
|
|
|
4653
|
+
export function __wbg_get_7bed016f185add81(arg0, arg1) {
|
|
4654
|
+
const ret = getObject(arg0)[arg1 >>> 0];
|
|
4655
|
+
return addHeapObject(ret);
|
|
4656
|
+
}
|
|
4657
|
+
|
|
4658
|
+
export function __wbg_get_access_token_22d89957129b443b(arg0) {
|
|
4659
|
+
const ret = getObject(arg0).get_access_token();
|
|
4660
|
+
return addHeapObject(ret);
|
|
4661
|
+
}
|
|
4662
|
+
|
|
4639
4663
|
export function __wbg_get_efcb449f58ec27c2() {
|
|
4640
4664
|
return handleError(function (arg0, arg1) {
|
|
4641
4665
|
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
@@ -4823,14 +4847,14 @@ export function __wbg_length_cdd215e10d9dd507(arg0) {
|
|
|
4823
4847
|
return ret;
|
|
4824
4848
|
}
|
|
4825
4849
|
|
|
4826
|
-
export function
|
|
4850
|
+
export function __wbg_list_0eee12d125e84f59() {
|
|
4827
4851
|
return handleError(function (arg0) {
|
|
4828
4852
|
const ret = getObject(arg0).list();
|
|
4829
4853
|
return addHeapObject(ret);
|
|
4830
4854
|
}, arguments);
|
|
4831
4855
|
}
|
|
4832
4856
|
|
|
4833
|
-
export function
|
|
4857
|
+
export function __wbg_list_7695393584d6a69b() {
|
|
4834
4858
|
return handleError(function (arg0) {
|
|
4835
4859
|
const ret = getObject(arg0).list();
|
|
4836
4860
|
return addHeapObject(ret);
|
|
@@ -5045,7 +5069,7 @@ export function __wbg_randomFillSync_ac0988aba3254290() {
|
|
|
5045
5069
|
}, arguments);
|
|
5046
5070
|
}
|
|
5047
5071
|
|
|
5048
|
-
export function
|
|
5072
|
+
export function __wbg_remove_8b189a6fd3dcbfd4() {
|
|
5049
5073
|
return handleError(function (arg0, arg1, arg2) {
|
|
5050
5074
|
let deferred0_0;
|
|
5051
5075
|
let deferred0_1;
|
|
@@ -5060,7 +5084,7 @@ export function __wbg_remove_33695adbdbc52a3e() {
|
|
|
5060
5084
|
}, arguments);
|
|
5061
5085
|
}
|
|
5062
5086
|
|
|
5063
|
-
export function
|
|
5087
|
+
export function __wbg_remove_b53fd6b594257783() {
|
|
5064
5088
|
return handleError(function (arg0, arg1, arg2) {
|
|
5065
5089
|
let deferred0_0;
|
|
5066
5090
|
let deferred0_1;
|
|
@@ -5106,7 +5130,7 @@ export function __wbg_setTimeout_ca12ead8b48245e2(arg0, arg1) {
|
|
|
5106
5130
|
return addHeapObject(ret);
|
|
5107
5131
|
}
|
|
5108
5132
|
|
|
5109
|
-
export function
|
|
5133
|
+
export function __wbg_set_2b24ea7b5665d88e() {
|
|
5110
5134
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
5111
5135
|
let deferred0_0;
|
|
5112
5136
|
let deferred0_1;
|
|
@@ -5125,7 +5149,7 @@ export function __wbg_set_3f1d0b984ed272ed(arg0, arg1, arg2) {
|
|
|
5125
5149
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
5126
5150
|
}
|
|
5127
5151
|
|
|
5128
|
-
export function
|
|
5152
|
+
export function __wbg_set_685d7b8ddf2c6d23() {
|
|
5129
5153
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
5130
5154
|
let deferred0_0;
|
|
5131
5155
|
let deferred0_1;
|
|
Binary file
|
|
@@ -278,7 +278,8 @@ export const ipcRequestDiscover: (a: number, b: number, c: number) => number;
|
|
|
278
278
|
export const __wbg_ipcclient_free: (a: number, b: number) => void;
|
|
279
279
|
export const __wbg_ipcclientsubscription_free: (a: number, b: number) => void;
|
|
280
280
|
export const ipcclientsubscription_receive: (a: number, b: number) => number;
|
|
281
|
-
export const
|
|
281
|
+
export const ipcclient_newWithSdkInMemorySessions: (a: number) => number;
|
|
282
|
+
export const ipcclient_newWithClientManagedSessions: (a: number, b: number) => number;
|
|
282
283
|
export const ipcclient_start: (a: number) => number;
|
|
283
284
|
export const ipcclient_isRunning: (a: number) => number;
|
|
284
285
|
export const ipcclient_send: (a: number, b: number) => number;
|
|
@@ -435,22 +436,22 @@ export const __wbg_totpclient_free: (a: number, b: number) => void;
|
|
|
435
436
|
export const __wbg_get_outgoingmessage_destination: (a: number) => number;
|
|
436
437
|
export const __wbg_set_outgoingmessage_destination: (a: number, b: number) => void;
|
|
437
438
|
export const __wbg_cryptoclient_free: (a: number, b: number) => void;
|
|
438
|
-
export const
|
|
439
|
+
export const wasm_bindgen__convert__closures_____invoke__hf869d8564f5adb52: (
|
|
439
440
|
a: number,
|
|
440
441
|
b: number,
|
|
442
|
+
c: number,
|
|
443
|
+
d: number,
|
|
441
444
|
) => void;
|
|
442
|
-
export const
|
|
443
|
-
export const
|
|
445
|
+
export const wasm_bindgen__closure__destroy__h7b7f88151484c167: (a: number, b: number) => void;
|
|
446
|
+
export const wasm_bindgen__convert__closures_____invoke__h76c71c1158b6af01: (
|
|
444
447
|
a: number,
|
|
445
448
|
b: number,
|
|
446
|
-
c: number,
|
|
447
449
|
) => void;
|
|
448
|
-
export const
|
|
449
|
-
export const
|
|
450
|
+
export const wasm_bindgen__closure__destroy__h1cce7ce4a094839d: (a: number, b: number) => void;
|
|
451
|
+
export const wasm_bindgen__convert__closures_____invoke__h4f8d9ba9b5b9a009: (
|
|
450
452
|
a: number,
|
|
451
453
|
b: number,
|
|
452
454
|
c: number,
|
|
453
|
-
d: number,
|
|
454
455
|
) => void;
|
|
455
456
|
export const wasm_bindgen__closure__destroy__h04ff7fddf688fec6: (a: number, b: number) => void;
|
|
456
457
|
export const wasm_bindgen__convert__closures_____invoke__h4096c3b930b983e7: (
|