@bitwarden/commercial-sdk-internal 0.2.0-main.360 → 0.2.0-main.361
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 +3 -9
- package/bitwarden_wasm_internal_bg.js +26 -23
- package/bitwarden_wasm_internal_bg.wasm +0 -0
- package/bitwarden_wasm_internal_bg.wasm.d.ts +1 -0
- package/bitwarden_wasm_internal_bg.wasm.js +1 -1
- package/node/bitwarden_wasm_internal.d.ts +3 -9
- package/node/bitwarden_wasm_internal.js +26 -23
- package/node/bitwarden_wasm_internal_bg.wasm +0 -0
- package/node/bitwarden_wasm_internal_bg.wasm.d.ts +1 -0
- package/package.json +1 -1
|
@@ -631,11 +631,6 @@ export type UserId = Tagged<Uuid, "UserId">;
|
|
|
631
631
|
*/
|
|
632
632
|
export type OrganizationId = Tagged<Uuid, "OrganizationId">;
|
|
633
633
|
|
|
634
|
-
/**
|
|
635
|
-
* A non-generic wrapper around `bitwarden-crypto`\'s `PasswordProtectedKeyEnvelope`.
|
|
636
|
-
*/
|
|
637
|
-
export type PasswordProtectedKeyEnvelope = Tagged<string, "PasswordProtectedKeyEnvelope">;
|
|
638
|
-
|
|
639
634
|
export interface MasterPasswordError extends Error {
|
|
640
635
|
name: "MasterPasswordError";
|
|
641
636
|
variant:
|
|
@@ -766,6 +761,8 @@ export type EncString = Tagged<string, "EncString">;
|
|
|
766
761
|
|
|
767
762
|
export type SignedPublicKey = Tagged<string, "SignedPublicKey">;
|
|
768
763
|
|
|
764
|
+
export type PasswordProtectedKeyEnvelope = Tagged<string, "PasswordProtectedKeyEnvelope">;
|
|
765
|
+
|
|
769
766
|
/**
|
|
770
767
|
* The type of key / signature scheme used for signing and verifying.
|
|
771
768
|
*/
|
|
@@ -1917,10 +1914,7 @@ export class CryptoClient {
|
|
|
1917
1914
|
* Decrypts a `PasswordProtectedKeyEnvelope`, returning the user key, if successful.
|
|
1918
1915
|
* This is a stop-gap solution, until initialization of the SDK is used.
|
|
1919
1916
|
*/
|
|
1920
|
-
unseal_password_protected_key_envelope(
|
|
1921
|
-
pin: string,
|
|
1922
|
-
envelope: PasswordProtectedKeyEnvelope,
|
|
1923
|
-
): Uint8Array;
|
|
1917
|
+
unseal_password_protected_key_envelope(pin: string, envelope: string): Uint8Array;
|
|
1924
1918
|
}
|
|
1925
1919
|
export class ExporterClient {
|
|
1926
1920
|
private constructor();
|
|
@@ -2092,7 +2092,7 @@ class CryptoClient {
|
|
|
2092
2092
|
* Decrypts a `PasswordProtectedKeyEnvelope`, returning the user key, if successful.
|
|
2093
2093
|
* This is a stop-gap solution, until initialization of the SDK is used.
|
|
2094
2094
|
* @param {string} pin
|
|
2095
|
-
* @param {
|
|
2095
|
+
* @param {string} envelope
|
|
2096
2096
|
* @returns {Uint8Array}
|
|
2097
2097
|
*/
|
|
2098
2098
|
unseal_password_protected_key_envelope(pin, envelope) {
|
|
@@ -2100,12 +2100,15 @@ class CryptoClient {
|
|
|
2100
2100
|
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
2101
2101
|
const ptr0 = passStringToWasm0(pin, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2102
2102
|
const len0 = WASM_VECTOR_LEN;
|
|
2103
|
+
const ptr1 = passStringToWasm0(envelope, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2104
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2103
2105
|
wasm.cryptoclient_unseal_password_protected_key_envelope(
|
|
2104
2106
|
retptr,
|
|
2105
2107
|
this.__wbg_ptr,
|
|
2106
2108
|
ptr0,
|
|
2107
2109
|
len0,
|
|
2108
|
-
|
|
2110
|
+
ptr1,
|
|
2111
|
+
len1,
|
|
2109
2112
|
);
|
|
2110
2113
|
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
2111
2114
|
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
@@ -2114,9 +2117,9 @@ class CryptoClient {
|
|
|
2114
2117
|
if (r3) {
|
|
2115
2118
|
throw takeObject(r2);
|
|
2116
2119
|
}
|
|
2117
|
-
var
|
|
2120
|
+
var v3 = getArrayU8FromWasm0(r0, r1).slice();
|
|
2118
2121
|
wasm.__wbindgen_free(r0, r1 * 1, 1);
|
|
2119
|
-
return
|
|
2122
|
+
return v3;
|
|
2120
2123
|
} finally {
|
|
2121
2124
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
2122
2125
|
}
|
|
@@ -4194,7 +4197,7 @@ module.exports.__wbg_call_7cccdd69e0791ae2 = function () {
|
|
|
4194
4197
|
}, arguments);
|
|
4195
4198
|
};
|
|
4196
4199
|
|
|
4197
|
-
module.exports.
|
|
4200
|
+
module.exports.__wbg_cipher_8d57d546ebd28feb = function (arg0) {
|
|
4198
4201
|
const ret = getObject(arg0).cipher;
|
|
4199
4202
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4200
4203
|
};
|
|
@@ -4274,7 +4277,7 @@ module.exports.__wbg_fetch_509096533071c657 = function (arg0, arg1) {
|
|
|
4274
4277
|
return addHeapObject(ret);
|
|
4275
4278
|
};
|
|
4276
4279
|
|
|
4277
|
-
module.exports.
|
|
4280
|
+
module.exports.__wbg_folder_e7b703a9574b8633 = function (arg0) {
|
|
4278
4281
|
const ret = getObject(arg0).folder;
|
|
4279
4282
|
return isLikeNone(ret) ? 0 : addHeapObject(ret);
|
|
4280
4283
|
};
|
|
@@ -4296,7 +4299,7 @@ module.exports.__wbg_getTime_46267b1c24877e30 = function (arg0) {
|
|
|
4296
4299
|
return ret;
|
|
4297
4300
|
};
|
|
4298
4301
|
|
|
4299
|
-
module.exports.
|
|
4302
|
+
module.exports.__wbg_get_0fe8cec0c515874b = function () {
|
|
4300
4303
|
return handleError(function (arg0, arg1, arg2) {
|
|
4301
4304
|
let deferred0_0;
|
|
4302
4305
|
let deferred0_1;
|
|
@@ -4318,12 +4321,7 @@ module.exports.__wbg_get_67b2ba62fc30de12 = function () {
|
|
|
4318
4321
|
}, arguments);
|
|
4319
4322
|
};
|
|
4320
4323
|
|
|
4321
|
-
module.exports.
|
|
4322
|
-
const ret = getObject(arg0)[arg1 >>> 0];
|
|
4323
|
-
return addHeapObject(ret);
|
|
4324
|
-
};
|
|
4325
|
-
|
|
4326
|
-
module.exports.__wbg_get_f25f7cf564b18916 = function () {
|
|
4324
|
+
module.exports.__wbg_get_68689cff5a27a4e3 = function () {
|
|
4327
4325
|
return handleError(function (arg0, arg1, arg2) {
|
|
4328
4326
|
let deferred0_0;
|
|
4329
4327
|
let deferred0_1;
|
|
@@ -4338,7 +4336,12 @@ module.exports.__wbg_get_f25f7cf564b18916 = function () {
|
|
|
4338
4336
|
}, arguments);
|
|
4339
4337
|
};
|
|
4340
4338
|
|
|
4341
|
-
module.exports.
|
|
4339
|
+
module.exports.__wbg_get_b9b93047fe3cf45b = function (arg0, arg1) {
|
|
4340
|
+
const ret = getObject(arg0)[arg1 >>> 0];
|
|
4341
|
+
return addHeapObject(ret);
|
|
4342
|
+
};
|
|
4343
|
+
|
|
4344
|
+
module.exports.__wbg_getaccesstoken_e19adb10f028d797 = function (arg0) {
|
|
4342
4345
|
const ret = getObject(arg0).get_access_token();
|
|
4343
4346
|
return addHeapObject(ret);
|
|
4344
4347
|
};
|
|
@@ -4523,14 +4526,14 @@ module.exports.__wbg_length_e2d2a49132c1b256 = function (arg0) {
|
|
|
4523
4526
|
return ret;
|
|
4524
4527
|
};
|
|
4525
4528
|
|
|
4526
|
-
module.exports.
|
|
4529
|
+
module.exports.__wbg_list_4d7ad3b099048858 = function () {
|
|
4527
4530
|
return handleError(function (arg0) {
|
|
4528
4531
|
const ret = getObject(arg0).list();
|
|
4529
4532
|
return addHeapObject(ret);
|
|
4530
4533
|
}, arguments);
|
|
4531
4534
|
};
|
|
4532
4535
|
|
|
4533
|
-
module.exports.
|
|
4536
|
+
module.exports.__wbg_list_58b48f9ba5ad52dc = function () {
|
|
4534
4537
|
return handleError(function (arg0) {
|
|
4535
4538
|
const ret = getObject(arg0).list();
|
|
4536
4539
|
return addHeapObject(ret);
|
|
@@ -4731,7 +4734,7 @@ module.exports.__wbg_randomFillSync_ac0988aba3254290 = function () {
|
|
|
4731
4734
|
}, arguments);
|
|
4732
4735
|
};
|
|
4733
4736
|
|
|
4734
|
-
module.exports.
|
|
4737
|
+
module.exports.__wbg_remove_3537743f8f56af1c = function () {
|
|
4735
4738
|
return handleError(function (arg0, arg1, arg2) {
|
|
4736
4739
|
let deferred0_0;
|
|
4737
4740
|
let deferred0_1;
|
|
@@ -4746,7 +4749,7 @@ module.exports.__wbg_remove_128adba3facf371f = function () {
|
|
|
4746
4749
|
}, arguments);
|
|
4747
4750
|
};
|
|
4748
4751
|
|
|
4749
|
-
module.exports.
|
|
4752
|
+
module.exports.__wbg_remove_588e522225864fee = function () {
|
|
4750
4753
|
return handleError(function (arg0, arg1, arg2) {
|
|
4751
4754
|
let deferred0_0;
|
|
4752
4755
|
let deferred0_1;
|
|
@@ -4800,7 +4803,7 @@ module.exports.__wbg_set_3f1d0b984ed272ed = function (arg0, arg1, arg2) {
|
|
|
4800
4803
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
4801
4804
|
};
|
|
4802
4805
|
|
|
4803
|
-
module.exports.
|
|
4806
|
+
module.exports.__wbg_set_5d5d2f6723f9ec70 = function () {
|
|
4804
4807
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
4805
4808
|
let deferred0_0;
|
|
4806
4809
|
let deferred0_1;
|
|
@@ -4824,7 +4827,7 @@ module.exports.__wbg_set_8fc6bf8a5b1071d1 = function (arg0, arg1, arg2) {
|
|
|
4824
4827
|
return addHeapObject(ret);
|
|
4825
4828
|
};
|
|
4826
4829
|
|
|
4827
|
-
module.exports.
|
|
4830
|
+
module.exports.__wbg_set_d3e2a357bd7efe01 = function () {
|
|
4828
4831
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
4829
4832
|
let deferred0_0;
|
|
4830
4833
|
let deferred0_1;
|
|
@@ -5059,17 +5062,17 @@ module.exports.__wbindgen_closure_wrapper195 = function (arg0, arg1, arg2) {
|
|
|
5059
5062
|
return addHeapObject(ret);
|
|
5060
5063
|
};
|
|
5061
5064
|
|
|
5062
|
-
module.exports.
|
|
5065
|
+
module.exports.__wbindgen_closure_wrapper3927 = function (arg0, arg1, arg2) {
|
|
5063
5066
|
const ret = makeMutClosure(arg0, arg1, 299, __wbg_adapter_60);
|
|
5064
5067
|
return addHeapObject(ret);
|
|
5065
5068
|
};
|
|
5066
5069
|
|
|
5067
|
-
module.exports.
|
|
5070
|
+
module.exports.__wbindgen_closure_wrapper6411 = function (arg0, arg1, arg2) {
|
|
5068
5071
|
const ret = makeMutClosure(arg0, arg1, 325, __wbg_adapter_60);
|
|
5069
5072
|
return addHeapObject(ret);
|
|
5070
5073
|
};
|
|
5071
5074
|
|
|
5072
|
-
module.exports.
|
|
5075
|
+
module.exports.__wbindgen_closure_wrapper6791 = function (arg0, arg1, arg2) {
|
|
5073
5076
|
const ret = makeMutClosure(arg0, arg1, 348, __wbg_adapter_57);
|
|
5074
5077
|
return addHeapObject(ret);
|
|
5075
5078
|
};
|
|
Binary file
|
|
@@ -213,6 +213,7 @@ export const cryptoclient_unseal_password_protected_key_envelope: (
|
|
|
213
213
|
c: number,
|
|
214
214
|
d: number,
|
|
215
215
|
e: number,
|
|
216
|
+
f: number,
|
|
216
217
|
) => void;
|
|
217
218
|
export const isMasterPasswordError: (a: number) => number;
|
|
218
219
|
export const isDeriveKeyConnectorError: (a: number) => number;
|