@bitwarden/sdk-internal 0.2.0-main.222 → 0.2.0-main.224
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 +17 -0
- package/bitwarden_wasm_internal_bg.js +46 -17
- package/bitwarden_wasm_internal_bg.wasm +0 -0
- package/bitwarden_wasm_internal_bg.wasm.d.ts +8 -0
- package/bitwarden_wasm_internal_bg.wasm.js +1 -1
- package/node/bitwarden_wasm_internal.d.ts +17 -0
- package/node/bitwarden_wasm_internal.js +46 -17
- package/node/bitwarden_wasm_internal_bg.wasm +0 -0
- package/node/bitwarden_wasm_internal_bg.wasm.d.ts +8 -0
- package/package.json +1 -1
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
97040142da7794cf327ebb6f547ab65ca2f11881
|
|
@@ -1181,6 +1181,19 @@ export interface AttachmentView {
|
|
|
1181
1181
|
sizeName: string | undefined;
|
|
1182
1182
|
fileName: string | undefined;
|
|
1183
1183
|
key: EncString | undefined;
|
|
1184
|
+
/**
|
|
1185
|
+
* The decrypted attachmentkey in base64 format.
|
|
1186
|
+
*
|
|
1187
|
+
* **TEMPORARY FIELD**: This field is a temporary workaround to provide
|
|
1188
|
+
* decrypted attachment keys to the TypeScript client during the migration
|
|
1189
|
+
* process. It will be removed once the encryption/decryption logic is
|
|
1190
|
+
* fully migrated to the SDK.
|
|
1191
|
+
*
|
|
1192
|
+
* **Ticket**: <https://bitwarden.atlassian.net/browse/PM-23005>
|
|
1193
|
+
*
|
|
1194
|
+
* Do not rely on this field for long-term use.
|
|
1195
|
+
*/
|
|
1196
|
+
decryptedKey: string | undefined;
|
|
1184
1197
|
}
|
|
1185
1198
|
|
|
1186
1199
|
export interface Attachment {
|
|
@@ -1595,6 +1608,10 @@ export class PureCrypto {
|
|
|
1595
1608
|
signed_public_key: Uint8Array,
|
|
1596
1609
|
verifying_key: Uint8Array,
|
|
1597
1610
|
): Uint8Array;
|
|
1611
|
+
/**
|
|
1612
|
+
* Derive output of the KDF for a [bitwarden_crypto::Kdf] configuration.
|
|
1613
|
+
*/
|
|
1614
|
+
static derive_kdf_material(password: Uint8Array, salt: Uint8Array, kdf: Kdf): Uint8Array;
|
|
1598
1615
|
}
|
|
1599
1616
|
export class StateClient {
|
|
1600
1617
|
private constructor();
|
|
@@ -753,7 +753,7 @@ function __wbg_adapter_56(arg0, arg1, arg2) {
|
|
|
753
753
|
);
|
|
754
754
|
}
|
|
755
755
|
|
|
756
|
-
function
|
|
756
|
+
function __wbg_adapter_279(arg0, arg1, arg2, arg3) {
|
|
757
757
|
wasm.wasm_bindgen__convert__closures__invoke2_mut__h8776500d04a3e634(
|
|
758
758
|
arg0,
|
|
759
759
|
arg1,
|
|
@@ -3055,6 +3055,35 @@ export class PureCrypto {
|
|
|
3055
3055
|
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3056
3056
|
}
|
|
3057
3057
|
}
|
|
3058
|
+
/**
|
|
3059
|
+
* Derive output of the KDF for a [bitwarden_crypto::Kdf] configuration.
|
|
3060
|
+
* @param {Uint8Array} password
|
|
3061
|
+
* @param {Uint8Array} salt
|
|
3062
|
+
* @param {Kdf} kdf
|
|
3063
|
+
* @returns {Uint8Array}
|
|
3064
|
+
*/
|
|
3065
|
+
static derive_kdf_material(password, salt, kdf) {
|
|
3066
|
+
try {
|
|
3067
|
+
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
3068
|
+
const ptr0 = passArray8ToWasm0(password, wasm.__wbindgen_malloc);
|
|
3069
|
+
const len0 = WASM_VECTOR_LEN;
|
|
3070
|
+
const ptr1 = passArray8ToWasm0(salt, wasm.__wbindgen_malloc);
|
|
3071
|
+
const len1 = WASM_VECTOR_LEN;
|
|
3072
|
+
wasm.purecrypto_derive_kdf_material(retptr, ptr0, len0, ptr1, len1, addHeapObject(kdf));
|
|
3073
|
+
var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
|
|
3074
|
+
var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
|
|
3075
|
+
var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
|
|
3076
|
+
var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
|
|
3077
|
+
if (r3) {
|
|
3078
|
+
throw takeObject(r2);
|
|
3079
|
+
}
|
|
3080
|
+
var v3 = getArrayU8FromWasm0(r0, r1).slice();
|
|
3081
|
+
wasm.__wbindgen_free(r0, r1 * 1, 1);
|
|
3082
|
+
return v3;
|
|
3083
|
+
} finally {
|
|
3084
|
+
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
3085
|
+
}
|
|
3086
|
+
}
|
|
3058
3087
|
}
|
|
3059
3088
|
|
|
3060
3089
|
const StateClientFinalization =
|
|
@@ -3347,7 +3376,14 @@ export function __wbg_getTime_46267b1c24877e30(arg0) {
|
|
|
3347
3376
|
return ret;
|
|
3348
3377
|
}
|
|
3349
3378
|
|
|
3350
|
-
export function
|
|
3379
|
+
export function __wbg_get_67b2ba62fc30de12() {
|
|
3380
|
+
return handleError(function (arg0, arg1) {
|
|
3381
|
+
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
3382
|
+
return addHeapObject(ret);
|
|
3383
|
+
}, arguments);
|
|
3384
|
+
}
|
|
3385
|
+
|
|
3386
|
+
export function __wbg_get_890e4177717f9ef6() {
|
|
3351
3387
|
return handleError(function (arg0, arg1, arg2) {
|
|
3352
3388
|
let deferred0_0;
|
|
3353
3389
|
let deferred0_1;
|
|
@@ -3362,19 +3398,12 @@ export function __wbg_get_19ade86a11be7465() {
|
|
|
3362
3398
|
}, arguments);
|
|
3363
3399
|
}
|
|
3364
3400
|
|
|
3365
|
-
export function __wbg_get_67b2ba62fc30de12() {
|
|
3366
|
-
return handleError(function (arg0, arg1) {
|
|
3367
|
-
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
3368
|
-
return addHeapObject(ret);
|
|
3369
|
-
}, arguments);
|
|
3370
|
-
}
|
|
3371
|
-
|
|
3372
3401
|
export function __wbg_get_b9b93047fe3cf45b(arg0, arg1) {
|
|
3373
3402
|
const ret = getObject(arg0)[arg1 >>> 0];
|
|
3374
3403
|
return addHeapObject(ret);
|
|
3375
3404
|
}
|
|
3376
3405
|
|
|
3377
|
-
export function
|
|
3406
|
+
export function __wbg_getaccesstoken_0e9ad4049aeafc04(arg0) {
|
|
3378
3407
|
const ret = getObject(arg0).get_access_token();
|
|
3379
3408
|
return addHeapObject(ret);
|
|
3380
3409
|
}
|
|
@@ -3479,7 +3508,7 @@ export function __wbg_length_e2d2a49132c1b256(arg0) {
|
|
|
3479
3508
|
return ret;
|
|
3480
3509
|
}
|
|
3481
3510
|
|
|
3482
|
-
export function
|
|
3511
|
+
export function __wbg_list_34dd2c5c74fa88f6() {
|
|
3483
3512
|
return handleError(function (arg0) {
|
|
3484
3513
|
const ret = getObject(arg0).list();
|
|
3485
3514
|
return addHeapObject(ret);
|
|
@@ -3514,7 +3543,7 @@ export function __wbg_new_23a2665fac83c611(arg0, arg1) {
|
|
|
3514
3543
|
const a = state0.a;
|
|
3515
3544
|
state0.a = 0;
|
|
3516
3545
|
try {
|
|
3517
|
-
return
|
|
3546
|
+
return __wbg_adapter_279(a, state0.b, arg0, arg1);
|
|
3518
3547
|
} finally {
|
|
3519
3548
|
state0.a = a;
|
|
3520
3549
|
}
|
|
@@ -3656,7 +3685,7 @@ export function __wbg_randomFillSync_ac0988aba3254290() {
|
|
|
3656
3685
|
}, arguments);
|
|
3657
3686
|
}
|
|
3658
3687
|
|
|
3659
|
-
export function
|
|
3688
|
+
export function __wbg_remove_58c93427251a9a40() {
|
|
3660
3689
|
return handleError(function (arg0, arg1, arg2) {
|
|
3661
3690
|
let deferred0_0;
|
|
3662
3691
|
let deferred0_1;
|
|
@@ -3707,7 +3736,7 @@ export function __wbg_set_65595bdd868b3009(arg0, arg1, arg2) {
|
|
|
3707
3736
|
getObject(arg0).set(getObject(arg1), arg2 >>> 0);
|
|
3708
3737
|
}
|
|
3709
3738
|
|
|
3710
|
-
export function
|
|
3739
|
+
export function __wbg_set_f4ad258b3a9d2119() {
|
|
3711
3740
|
return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3712
3741
|
let deferred0_0;
|
|
3713
3742
|
let deferred0_1;
|
|
@@ -3901,17 +3930,17 @@ export function __wbindgen_cb_drop(arg0) {
|
|
|
3901
3930
|
return ret;
|
|
3902
3931
|
}
|
|
3903
3932
|
|
|
3904
|
-
export function
|
|
3933
|
+
export function __wbindgen_closure_wrapper2909(arg0, arg1, arg2) {
|
|
3905
3934
|
const ret = makeMutClosure(arg0, arg1, 919, __wbg_adapter_50);
|
|
3906
3935
|
return addHeapObject(ret);
|
|
3907
3936
|
}
|
|
3908
3937
|
|
|
3909
|
-
export function
|
|
3938
|
+
export function __wbindgen_closure_wrapper3749(arg0, arg1, arg2) {
|
|
3910
3939
|
const ret = makeMutClosure(arg0, arg1, 1003, __wbg_adapter_53);
|
|
3911
3940
|
return addHeapObject(ret);
|
|
3912
3941
|
}
|
|
3913
3942
|
|
|
3914
|
-
export function
|
|
3943
|
+
export function __wbindgen_closure_wrapper4167(arg0, arg1, arg2) {
|
|
3915
3944
|
const ret = makeMutClosure(arg0, arg1, 1126, __wbg_adapter_56);
|
|
3916
3945
|
return addHeapObject(ret);
|
|
3917
3946
|
}
|
|
Binary file
|
|
@@ -308,6 +308,14 @@ export const purecrypto_verify_and_unwrap_signed_public_key: (
|
|
|
308
308
|
d: number,
|
|
309
309
|
e: number,
|
|
310
310
|
) => void;
|
|
311
|
+
export const purecrypto_derive_kdf_material: (
|
|
312
|
+
a: number,
|
|
313
|
+
b: number,
|
|
314
|
+
c: number,
|
|
315
|
+
d: number,
|
|
316
|
+
e: number,
|
|
317
|
+
f: number,
|
|
318
|
+
) => void;
|
|
311
319
|
export const generate_ssh_key: (a: number, b: number) => void;
|
|
312
320
|
export const import_ssh_key: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
313
321
|
export const isTestError: (a: number) => number;
|