@wireapp/core-crypto 1.0.0-pre.8 → 1.0.0-rc.1
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
Binary file
|
@@ -810,7 +810,7 @@ export declare class CoreCrypto {
|
|
810
810
|
*
|
811
811
|
* @param conversationId - The ID of the conversation
|
812
812
|
*/
|
813
|
-
mergePendingGroupFromExternalCommit(conversationId: ConversationId): Promise<
|
813
|
+
mergePendingGroupFromExternalCommit(conversationId: ConversationId): Promise<DecryptedMessage[] | undefined>;
|
814
814
|
/**
|
815
815
|
* In case the external commit generated by {@link CoreCrypto.joinByExternalCommit} is rejected by the Delivery Service, and we
|
816
816
|
* want to abort this external commit once for all, we can wipe out the pending group from the keystore in order
|
@@ -234,12 +234,12 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
234
234
|
return real;
|
235
235
|
}
|
236
236
|
function __wbg_adapter_52(arg0, arg1, arg2) {
|
237
|
-
wasm$1.
|
237
|
+
wasm$1.wasm_bindgen__convert__closures__invoke1_mut__h8d579dd3e9d6cb9a(arg0, arg1, addHeapObject(arg2));
|
238
238
|
}
|
239
239
|
function __wbg_adapter_55(arg0, arg1, arg2) {
|
240
240
|
try {
|
241
241
|
const retptr = wasm$1.__wbindgen_add_to_stack_pointer(-16);
|
242
|
-
wasm$1.
|
242
|
+
wasm$1.wasm_bindgen__convert__closures__invoke1_mut__h746b8b0ddaf8393e(retptr, arg0, arg1, addHeapObject(arg2));
|
243
243
|
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
244
244
|
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
245
245
|
if (r1) {
|
@@ -314,7 +314,7 @@ function handleError(f, args) {
|
|
314
314
|
}
|
315
315
|
}
|
316
316
|
function __wbg_adapter_296(arg0, arg1, arg2, arg3) {
|
317
|
-
wasm$1.
|
317
|
+
wasm$1.wasm_bindgen__convert__closures__invoke2_mut__h80912c0a9461abcd(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
318
318
|
}
|
319
319
|
/**
|
320
320
|
* see [core_crypto::prelude::MlsWirePolicy]
|
@@ -343,7 +343,6 @@ const CredentialType$1 = Object.freeze({
|
|
343
343
|
X509: 2, "2": "X509",
|
344
344
|
});
|
345
345
|
/**
|
346
|
-
* see [core_crypto::prelude::CiphersuiteName]
|
347
346
|
*/
|
348
347
|
const Ciphersuite$1 = Object.freeze({
|
349
348
|
/**
|
@@ -867,7 +866,7 @@ let CoreCrypto$1 = class CoreCrypto {
|
|
867
866
|
* see [core_crypto::mls::MlsCentral::mls_init]
|
868
867
|
* @param {Uint8Array} client_id
|
869
868
|
* @param {Uint16Array} ciphersuites
|
870
|
-
* @returns {Promise<
|
869
|
+
* @returns {Promise<any>}
|
871
870
|
*/
|
872
871
|
mls_init(client_id, ciphersuites) {
|
873
872
|
const ptr0 = passArray8ToWasm0(client_id, wasm$1.__wbindgen_malloc);
|
@@ -1446,7 +1445,7 @@ let CoreCrypto$1 = class CoreCrypto {
|
|
1446
1445
|
* see [core_crypto::proteus::ProteusCentral::encrypt]
|
1447
1446
|
* @param {string} session_id
|
1448
1447
|
* @param {Uint8Array} plaintext
|
1449
|
-
* @returns {Promise<
|
1448
|
+
* @returns {Promise<any>}
|
1450
1449
|
*/
|
1451
1450
|
proteus_encrypt(session_id, plaintext) {
|
1452
1451
|
const ptr0 = passStringToWasm0(session_id, wasm$1.__wbindgen_malloc, wasm$1.__wbindgen_realloc);
|
@@ -1477,7 +1476,7 @@ let CoreCrypto$1 = class CoreCrypto {
|
|
1477
1476
|
*
|
1478
1477
|
* see [core_crypto::proteus::ProteusCentral::new_prekey]
|
1479
1478
|
* @param {number} prekey_id
|
1480
|
-
* @returns {Promise<
|
1479
|
+
* @returns {Promise<any>}
|
1481
1480
|
*/
|
1482
1481
|
proteus_new_prekey(prekey_id) {
|
1483
1482
|
const ret = wasm$1.corecrypto_proteus_new_prekey(this.__wbg_ptr, prekey_id);
|
@@ -1487,7 +1486,7 @@ let CoreCrypto$1 = class CoreCrypto {
|
|
1487
1486
|
* Returns: [`WasmCryptoResult<ProteusAutoPrekeyBundle>`]
|
1488
1487
|
*
|
1489
1488
|
* see [core_crypto::proteus::ProteusCentral::new_prekey]
|
1490
|
-
* @returns {Promise<
|
1489
|
+
* @returns {Promise<any>}
|
1491
1490
|
*/
|
1492
1491
|
proteus_new_prekey_auto() {
|
1493
1492
|
const ret = wasm$1.corecrypto_proteus_new_prekey_auto(this.__wbg_ptr);
|
@@ -2792,10 +2791,6 @@ function __wbg_get_imports() {
|
|
2792
2791
|
const ret = getObject(arg0).length;
|
2793
2792
|
return ret;
|
2794
2793
|
};
|
2795
|
-
imports.wbg.__wbg_new_b51585de1b234aff = function () {
|
2796
|
-
const ret = new Object();
|
2797
|
-
return addHeapObject(ret);
|
2798
|
-
};
|
2799
2794
|
imports.wbg.__wbg_call_01734de55d61e11d = function () {
|
2800
2795
|
return handleError(function (arg0, arg1, arg2) {
|
2801
2796
|
const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
|
@@ -2810,46 +2805,31 @@ function __wbg_get_imports() {
|
|
2810
2805
|
const ret = new Array();
|
2811
2806
|
return addHeapObject(ret);
|
2812
2807
|
};
|
2813
|
-
imports.wbg.
|
2814
|
-
|
2808
|
+
imports.wbg.__wbg_push_ca1c26067ef907ac = function (arg0, arg1) {
|
2809
|
+
const ret = getObject(arg0).push(getObject(arg1));
|
2810
|
+
return ret;
|
2815
2811
|
};
|
2816
|
-
imports.wbg.
|
2817
|
-
|
2812
|
+
imports.wbg.__wbg_ffiwiree2eidentity_new = function (arg0) {
|
2813
|
+
const ret = FfiWireE2EIdentity.__wrap(arg0);
|
2814
|
+
return addHeapObject(ret);
|
2818
2815
|
};
|
2819
|
-
imports.wbg.
|
2820
|
-
const ret = arg0;
|
2816
|
+
imports.wbg.__wbg_proteusautoprekeybundle_new = function (arg0) {
|
2817
|
+
const ret = ProteusAutoPrekeyBundle.__wrap(arg0);
|
2821
2818
|
return addHeapObject(ret);
|
2822
2819
|
};
|
2823
|
-
imports.wbg.
|
2824
|
-
|
2825
|
-
|
2826
|
-
var cb0 = (arg0, arg1) => {
|
2827
|
-
const a = state0.a;
|
2828
|
-
state0.a = 0;
|
2829
|
-
try {
|
2830
|
-
return __wbg_adapter_296(a, state0.b, arg0, arg1);
|
2831
|
-
}
|
2832
|
-
finally {
|
2833
|
-
state0.a = a;
|
2834
|
-
}
|
2835
|
-
};
|
2836
|
-
const ret = new Promise(cb0);
|
2837
|
-
return addHeapObject(ret);
|
2838
|
-
}
|
2839
|
-
finally {
|
2840
|
-
state0.a = state0.b = 0;
|
2841
|
-
}
|
2820
|
+
imports.wbg.__wbg_new_b51585de1b234aff = function () {
|
2821
|
+
const ret = new Object();
|
2822
|
+
return addHeapObject(ret);
|
2842
2823
|
};
|
2843
|
-
imports.wbg.
|
2844
|
-
|
2845
|
-
return ret;
|
2824
|
+
imports.wbg.__wbg_set_502d29070ea18557 = function (arg0, arg1, arg2) {
|
2825
|
+
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
2846
2826
|
};
|
2847
2827
|
imports.wbg.__wbindgen_bigint_from_u64 = function (arg0) {
|
2848
2828
|
const ret = BigInt.asUintN(64, arg0);
|
2849
2829
|
return addHeapObject(ret);
|
2850
2830
|
};
|
2851
|
-
imports.wbg.
|
2852
|
-
const ret =
|
2831
|
+
imports.wbg.__wbindgen_number_new = function (arg0) {
|
2832
|
+
const ret = arg0;
|
2853
2833
|
return addHeapObject(ret);
|
2854
2834
|
};
|
2855
2835
|
imports.wbg.__wbg_new_56693dbed0c32988 = function () {
|
@@ -2860,10 +2840,6 @@ function __wbg_get_imports() {
|
|
2860
2840
|
const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
|
2861
2841
|
return addHeapObject(ret);
|
2862
2842
|
};
|
2863
|
-
imports.wbg.__wbg_ffiwiree2eidentity_new = function (arg0) {
|
2864
|
-
const ret = FfiWireE2EIdentity.__wrap(arg0);
|
2865
|
-
return addHeapObject(ret);
|
2866
|
-
};
|
2867
2843
|
imports.wbg.__wbg_new_d258248ed531ff54 = function (arg0, arg1) {
|
2868
2844
|
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
2869
2845
|
return addHeapObject(ret);
|
@@ -2936,6 +2912,9 @@ function __wbg_get_imports() {
|
|
2936
2912
|
const ret = CoreCrypto$1.__wrap(arg0);
|
2937
2913
|
return addHeapObject(ret);
|
2938
2914
|
};
|
2915
|
+
imports.wbg.__wbg_set_841ac57cff3d672b = function (arg0, arg1, arg2) {
|
2916
|
+
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
2917
|
+
};
|
2939
2918
|
imports.wbg.__wbg_instanceof_Promise_0e98a5bf082e090f = function (arg0) {
|
2940
2919
|
let result;
|
2941
2920
|
try {
|
@@ -2980,6 +2959,26 @@ function __wbg_get_imports() {
|
|
2980
2959
|
const ret = performance.now();
|
2981
2960
|
return ret;
|
2982
2961
|
};
|
2962
|
+
imports.wbg.__wbg_new_43f1b47c28813cbd = function (arg0, arg1) {
|
2963
|
+
try {
|
2964
|
+
var state0 = { a: arg0, b: arg1 };
|
2965
|
+
var cb0 = (arg0, arg1) => {
|
2966
|
+
const a = state0.a;
|
2967
|
+
state0.a = 0;
|
2968
|
+
try {
|
2969
|
+
return __wbg_adapter_296(a, state0.b, arg0, arg1);
|
2970
|
+
}
|
2971
|
+
finally {
|
2972
|
+
state0.a = a;
|
2973
|
+
}
|
2974
|
+
};
|
2975
|
+
const ret = new Promise(cb0);
|
2976
|
+
return addHeapObject(ret);
|
2977
|
+
}
|
2978
|
+
finally {
|
2979
|
+
state0.a = state0.b = 0;
|
2980
|
+
}
|
2981
|
+
};
|
2983
2982
|
imports.wbg.__wbg_reject_7bd6ac9617013c02 = function (arg0) {
|
2984
2983
|
const ret = Promise.reject(getObject(arg0));
|
2985
2984
|
return addHeapObject(ret);
|
@@ -3416,12 +3415,12 @@ function __wbg_get_imports() {
|
|
3416
3415
|
return addHeapObject(ret);
|
3417
3416
|
}, arguments);
|
3418
3417
|
};
|
3419
|
-
imports.wbg.
|
3420
|
-
const ret = makeMutClosure(arg0, arg1,
|
3418
|
+
imports.wbg.__wbindgen_closure_wrapper1977 = function (arg0, arg1, arg2) {
|
3419
|
+
const ret = makeMutClosure(arg0, arg1, 166, __wbg_adapter_52);
|
3421
3420
|
return addHeapObject(ret);
|
3422
3421
|
};
|
3423
|
-
imports.wbg.
|
3424
|
-
const ret = makeMutClosure(arg0, arg1,
|
3422
|
+
imports.wbg.__wbindgen_closure_wrapper4646 = function (arg0, arg1, arg2) {
|
3423
|
+
const ret = makeMutClosure(arg0, arg1, 166, __wbg_adapter_55);
|
3425
3424
|
return addHeapObject(ret);
|
3426
3425
|
};
|
3427
3426
|
return imports;
|
@@ -3489,7 +3488,7 @@ var exports = /*#__PURE__*/Object.freeze({
|
|
3489
3488
|
var wasm = async (opt = {}) => {
|
3490
3489
|
let {importHook, serverPath} = opt;
|
3491
3490
|
|
3492
|
-
let path = "assets/core_crypto_ffi-
|
3491
|
+
let path = "assets/core_crypto_ffi-ca75d34d.wasm";
|
3493
3492
|
|
3494
3493
|
if (serverPath != null) {
|
3495
3494
|
path = serverPath + /[^\/\\]*$/.exec(path)[0];
|
Binary file
|