@bitwarden/sdk-internal 0.2.0-main.397 → 0.2.0-main.399
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/VERSION +1 -1
- package/bitwarden_wasm_internal.d.ts +8 -0
- package/bitwarden_wasm_internal_bg.js +63 -30
- package/bitwarden_wasm_internal_bg.wasm +0 -0
- package/bitwarden_wasm_internal_bg.wasm.d.ts +13 -6
- package/bitwarden_wasm_internal_bg.wasm.js +1 -1
- package/node/bitwarden_wasm_internal.d.ts +8 -0
- package/node/bitwarden_wasm_internal.js +63 -30
- package/node/bitwarden_wasm_internal_bg.wasm +0 -0
- package/node/bitwarden_wasm_internal_bg.wasm.d.ts +13 -6
- package/package.json +1 -1
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
4b0d12800ebd2fdbe0b55ad8541c7d89db704f14
|
|
@@ -2423,6 +2423,14 @@ export class PureCrypto {
|
|
|
2423
2423
|
encrypted_user_key: string,
|
|
2424
2424
|
master_key: Uint8Array,
|
|
2425
2425
|
): Uint8Array;
|
|
2426
|
+
/**
|
|
2427
|
+
* Given an encrypted private RSA key and the symmetric key it is wrapped with, this returns
|
|
2428
|
+
* the corresponding public RSA key in DER format.
|
|
2429
|
+
*/
|
|
2430
|
+
static rsa_extract_public_key(
|
|
2431
|
+
encrypted_private_key: string,
|
|
2432
|
+
wrapping_key: Uint8Array,
|
|
2433
|
+
): Uint8Array;
|
|
2426
2434
|
}
|
|
2427
2435
|
/**
|
|
2428
2436
|
* The `SendAccessClient` is used to interact with the Bitwarden API to get send access tokens.
|
|
@@ -876,6 +876,10 @@ function wasm_bindgen__convert__closures_____invoke__hdc41283f124c06e5(arg0, arg
|
|
|
876
876
|
);
|
|
877
877
|
}
|
|
878
878
|
|
|
879
|
+
function wasm_bindgen__convert__closures_____invoke__h092300064b8afb1e(arg0, arg1) {
|
|
880
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h092300064b8afb1e(arg0, arg1);
|
|
881
|
+
}
|
|
882
|
+
|
|
879
883
|
function wasm_bindgen__convert__closures_____invoke__h1a8786b7bd5c2cf5(arg0, arg1, arg2) {
|
|
880
884
|
try {
|
|
881
885
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
@@ -895,10 +899,6 @@ function wasm_bindgen__convert__closures_____invoke__h1a8786b7bd5c2cf5(arg0, arg
|
|
|
895
899
|
}
|
|
896
900
|
}
|
|
897
901
|
|
|
898
|
-
function wasm_bindgen__convert__closures_____invoke__h092300064b8afb1e(arg0, arg1) {
|
|
899
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h092300064b8afb1e(arg0, arg1);
|
|
900
|
-
}
|
|
901
|
-
|
|
902
902
|
function wasm_bindgen__convert__closures_____invoke__h43dfd80678632d6f(arg0, arg1, arg2, arg3) {
|
|
903
903
|
wasm.wasm_bindgen__convert__closures_____invoke__h43dfd80678632d6f(
|
|
904
904
|
arg0,
|
|
@@ -4011,6 +4011,39 @@ export class PureCrypto {
|
|
|
4011
4011
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
4012
4012
|
}
|
|
4013
4013
|
}
|
|
4014
|
+
/**
|
|
4015
|
+
* Given an encrypted private RSA key and the symmetric key it is wrapped with, this returns
|
|
4016
|
+
* the corresponding public RSA key in DER format.
|
|
4017
|
+
* @param {string} encrypted_private_key
|
|
4018
|
+
* @param {Uint8Array} wrapping_key
|
|
4019
|
+
* @returns {Uint8Array}
|
|
4020
|
+
*/
|
|
4021
|
+
static rsa_extract_public_key(encrypted_private_key, wrapping_key) {
|
|
4022
|
+
try {
|
|
4023
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
4024
|
+
const ptr0 = passStringToWasm0(
|
|
4025
|
+
encrypted_private_key,
|
|
4026
|
+
wasm.__wbindgen_malloc,
|
|
4027
|
+
wasm.__wbindgen_realloc,
|
|
4028
|
+
);
|
|
4029
|
+
const len0 = WASM_VECTOR_LEN;
|
|
4030
|
+
const ptr1 = passArray8ToWasm0(wrapping_key, wasm.__wbindgen_malloc);
|
|
4031
|
+
const len1 = WASM_VECTOR_LEN;
|
|
4032
|
+
wasm.purecrypto_rsa_extract_public_key(retptr, ptr0, len0, ptr1, len1);
|
|
4033
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
4034
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
4035
|
+
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
4036
|
+
var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
|
|
4037
|
+
if (r3) {
|
|
4038
|
+
throw takeObject(r2);
|
|
4039
|
+
}
|
|
4040
|
+
var v3 = getArrayU8FromWasm0(r0, r1).slice();
|
|
4041
|
+
wasm.__wbindgen_free(r0, r1 * 1, 1);
|
|
4042
|
+
return v3;
|
|
4043
|
+
} finally {
|
|
4044
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
4045
|
+
}
|
|
4046
|
+
}
|
|
4014
4047
|
}
|
|
4015
4048
|
if (Symbol.dispose) PureCrypto.prototype[Symbol.dispose] = PureCrypto.prototype.free;
|
|
4016
4049
|
|
|
@@ -4428,7 +4461,7 @@ export function __wbg_call_e762c39fa8ea36bf() {
|
|
|
4428
4461
|
}, arguments);
|
|
4429
4462
|
}
|
|
4430
4463
|
|
|
4431
|
-
export function
|
|
4464
|
+
export function __wbg_cipher_c5d7f3af290bbbf4(arg0) {
|
|
4432
4465
|
const ret = getObject(arg0).cipher;
|
|
4433
4466
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4434
4467
|
}
|
|
@@ -4521,7 +4554,7 @@ export function __wbg_fetch_f8ba0e29a9d6de0d(arg0, arg1) {
|
|
|
4521
4554
|
return addHeapObject(ret);
|
|
4522
4555
|
}
|
|
4523
4556
|
|
|
4524
|
-
export function
|
|
4557
|
+
export function __wbg_folder_149190ff7ec60f4c(arg0) {
|
|
4525
4558
|
const ret = getObject(arg0).folder;
|
|
4526
4559
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4527
4560
|
}
|
|
@@ -4548,7 +4581,7 @@ export function __wbg_getTime_14776bfb48a1bff9(arg0) {
|
|
|
4548
4581
|
return ret;
|
|
4549
4582
|
}
|
|
4550
4583
|
|
|
4551
|
-
export function
|
|
4584
|
+
export function __wbg_get_3763d86f09fb65c6() {
|
|
4552
4585
|
return handleError(function (arg0, arg1, arg2) {
|
|
4553
4586
|
let deferred0_0;
|
|
4554
4587
|
let deferred0_1;
|
|
@@ -4568,19 +4601,7 @@ export function __wbg_get_7bed016f185add81(arg0, arg1) {
|
|
|
4568
4601
|
return addHeapObject(ret);
|
|
4569
4602
|
}
|
|
4570
4603
|
|
|
4571
|
-
export function
|
|
4572
|
-
const ret = getObject(arg0).get_access_token();
|
|
4573
|
-
return addHeapObject(ret);
|
|
4574
|
-
}
|
|
4575
|
-
|
|
4576
|
-
export function __wbg_get_efcb449f58ec27c2() {
|
|
4577
|
-
return handleError(function (arg0, arg1) {
|
|
4578
|
-
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
4579
|
-
return addHeapObject(ret);
|
|
4580
|
-
}, arguments);
|
|
4581
|
-
}
|
|
4582
|
-
|
|
4583
|
-
export function __wbg_get_f836288e48750d27() {
|
|
4604
|
+
export function __wbg_get_97be5c58774542cd() {
|
|
4584
4605
|
return handleError(function (arg0, arg1, arg2) {
|
|
4585
4606
|
let deferred0_0;
|
|
4586
4607
|
let deferred0_1;
|
|
@@ -4595,6 +4616,18 @@ export function __wbg_get_f836288e48750d27() {
|
|
|
4595
4616
|
}, arguments);
|
|
4596
4617
|
}
|
|
4597
4618
|
|
|
4619
|
+
export function __wbg_get_access_token_afc3b106f073fd8e(arg0) {
|
|
4620
|
+
const ret = getObject(arg0).get_access_token();
|
|
4621
|
+
return addHeapObject(ret);
|
|
4622
|
+
}
|
|
4623
|
+
|
|
4624
|
+
export function __wbg_get_efcb449f58ec27c2() {
|
|
4625
|
+
return handleError(function (arg0, arg1) {
|
|
4626
|
+
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
4627
|
+
return addHeapObject(ret);
|
|
4628
|
+
}, arguments);
|
|
4629
|
+
}
|
|
4630
|
+
|
|
4598
4631
|
export function __wbg_get_with_ref_key_1dc361bd10053bfe(arg0, arg1) {
|
|
4599
4632
|
const ret = getObject(arg0)[getObject(arg1)];
|
|
4600
4633
|
return addHeapObject(ret);
|
|
@@ -4779,14 +4812,14 @@ export function __wbg_length_cdd215e10d9dd507(arg0) {
|
|
|
4779
4812
|
return ret;
|
|
4780
4813
|
}
|
|
4781
4814
|
|
|
4782
|
-
export function
|
|
4815
|
+
export function __wbg_list_53991bc038506fbc() {
|
|
4783
4816
|
return handleError(function (arg0) {
|
|
4784
4817
|
const ret = getObject(arg0).list();
|
|
4785
4818
|
return addHeapObject(ret);
|
|
4786
4819
|
}, arguments);
|
|
4787
4820
|
}
|
|
4788
4821
|
|
|
4789
|
-
export function
|
|
4822
|
+
export function __wbg_list_ff71f59ca6f21505() {
|
|
4790
4823
|
return handleError(function (arg0) {
|
|
4791
4824
|
const ret = getObject(arg0).list();
|
|
4792
4825
|
return addHeapObject(ret);
|
|
@@ -5030,7 +5063,7 @@ export function __wbg_randomFillSync_ac0988aba3254290() {
|
|
|
5030
5063
|
}, arguments);
|
|
5031
5064
|
}
|
|
5032
5065
|
|
|
5033
|
-
export function
|
|
5066
|
+
export function __wbg_remove_a5d30e4a14a4441b() {
|
|
5034
5067
|
return handleError(function (arg0, arg1, arg2) {
|
|
5035
5068
|
let deferred0_0;
|
|
5036
5069
|
let deferred0_1;
|
|
@@ -5045,7 +5078,7 @@ export function __wbg_remove_6e0b8907d2143b2a() {
|
|
|
5045
5078
|
}, arguments);
|
|
5046
5079
|
}
|
|
5047
5080
|
|
|
5048
|
-
export function
|
|
5081
|
+
export function __wbg_remove_e0d5d52e4d454588() {
|
|
5049
5082
|
return handleError(function (arg0, arg1, arg2) {
|
|
5050
5083
|
let deferred0_0;
|
|
5051
5084
|
let deferred0_1;
|
|
@@ -5091,11 +5124,7 @@ export function __wbg_setTimeout_ca12ead8b48245e2(arg0, arg1) {
|
|
|
5091
5124
|
return addHeapObject(ret);
|
|
5092
5125
|
}
|
|
5093
5126
|
|
|
5094
|
-
export function
|
|
5095
|
-
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
5096
|
-
}
|
|
5097
|
-
|
|
5098
|
-
export function __wbg_set_4f10240cec7c0329() {
|
|
5127
|
+
export function __wbg_set_2d0a9c1f306162b7() {
|
|
5099
5128
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
5100
5129
|
let deferred0_0;
|
|
5101
5130
|
let deferred0_1;
|
|
@@ -5110,7 +5139,7 @@ export function __wbg_set_4f10240cec7c0329() {
|
|
|
5110
5139
|
}, arguments);
|
|
5111
5140
|
}
|
|
5112
5141
|
|
|
5113
|
-
export function
|
|
5142
|
+
export function __wbg_set_32ec33366f931747() {
|
|
5114
5143
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
5115
5144
|
let deferred0_0;
|
|
5116
5145
|
let deferred0_1;
|
|
@@ -5125,6 +5154,10 @@ export function __wbg_set_8bf42eeed138232a() {
|
|
|
5125
5154
|
}, arguments);
|
|
5126
5155
|
}
|
|
5127
5156
|
|
|
5157
|
+
export function __wbg_set_3f1d0b984ed272ed(arg0, arg1, arg2) {
|
|
5158
|
+
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
5159
|
+
}
|
|
5160
|
+
|
|
5128
5161
|
export function __wbg_set_907fb406c34a251d(arg0, arg1, arg2) {
|
|
5129
5162
|
const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
|
|
5130
5163
|
return addHeapObject(ret);
|
|
Binary file
|
|
@@ -177,6 +177,13 @@ export const purecrypto_decrypt_user_key_with_master_key: (
|
|
|
177
177
|
d: number,
|
|
178
178
|
e: number,
|
|
179
179
|
) => void;
|
|
180
|
+
export const purecrypto_rsa_extract_public_key: (
|
|
181
|
+
a: number,
|
|
182
|
+
b: number,
|
|
183
|
+
c: number,
|
|
184
|
+
d: number,
|
|
185
|
+
e: number,
|
|
186
|
+
) => void;
|
|
180
187
|
export const generate_ssh_key: (a: number, b: number) => void;
|
|
181
188
|
export const import_ssh_key: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
182
189
|
export const isTestError: (a: number) => number;
|
|
@@ -436,19 +443,19 @@ export const wasm_bindgen__convert__closures_____invoke__hdc41283f124c06e5: (
|
|
|
436
443
|
b: number,
|
|
437
444
|
c: number,
|
|
438
445
|
) => void;
|
|
439
|
-
export const
|
|
440
|
-
export const
|
|
446
|
+
export const wasm_bindgen__closure__destroy__h5bf455f3385c4f71: (a: number, b: number) => void;
|
|
447
|
+
export const wasm_bindgen__convert__closures_____invoke__h092300064b8afb1e: (
|
|
441
448
|
a: number,
|
|
442
449
|
b: number,
|
|
443
|
-
c: number,
|
|
444
|
-
d: number,
|
|
445
450
|
) => void;
|
|
446
|
-
export const
|
|
451
|
+
export const wasm_bindgen__convert__closures_____invoke__h1a8786b7bd5c2cf5: (
|
|
447
452
|
a: number,
|
|
448
453
|
b: number,
|
|
454
|
+
c: number,
|
|
455
|
+
d: number,
|
|
449
456
|
) => void;
|
|
457
|
+
export const wasm_bindgen__closure__destroy__h1470697583ce3ba3: (a: number, b: number) => void;
|
|
450
458
|
export const wasm_bindgen__closure__destroy__hfcb631b72e5e985c: (a: number, b: number) => void;
|
|
451
|
-
export const wasm_bindgen__closure__destroy__h5bf455f3385c4f71: (a: number, b: number) => void;
|
|
452
459
|
export const wasm_bindgen__convert__closures_____invoke__h43dfd80678632d6f: (
|
|
453
460
|
a: number,
|
|
454
461
|
b: number,
|