@wireapp/core-crypto 1.0.0-rc.20 → 1.0.0-rc.21
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
Binary file
|
@@ -1,5 +1,3 @@
|
|
1
|
-
/* tslint:disable */
|
2
|
-
/* eslint-disable */
|
3
1
|
/**
|
4
2
|
* see [core_crypto::prelude::DeviceStatus]
|
5
3
|
*/
|
@@ -1204,7 +1202,7 @@ export declare class CoreCrypto {
|
|
1204
1202
|
* Creates an enrollment instance with private key material you can use in order to fetch
|
1205
1203
|
* a new x509 certificate from the acme server.
|
1206
1204
|
*
|
1207
|
-
* @param clientId - client identifier
|
1205
|
+
* @param clientId - client identifier e.g. `b7ac11a4-8f01-4527-af88-1c30885a7931:6add501bacd1d90e@example.com`
|
1208
1206
|
* @param displayName - human-readable name displayed in the application e.g. `Smith, Alice M (QA)`
|
1209
1207
|
* @param handle - user handle e.g. `alice.smith.qa@example.com`
|
1210
1208
|
* @param expiryDays - generated x509 certificate expiry
|
@@ -1217,7 +1215,7 @@ export declare class CoreCrypto {
|
|
1217
1215
|
* Generates an E2EI enrollment instance for a "regular" client (with a Basic credential) willing to migrate to E2EI.
|
1218
1216
|
* Once the enrollment is finished, use the instance in {@link CoreCrypto.e2eiRotateAll} to do the rotation.
|
1219
1217
|
*
|
1220
|
-
* @param clientId - client identifier
|
1218
|
+
* @param clientId - client identifier e.g. `b7ac11a4-8f01-4527-af88-1c30885a7931:6add501bacd1d90e@example.com`
|
1221
1219
|
* @param displayName - human-readable name displayed in the application e.g. `Smith, Alice M (QA)`
|
1222
1220
|
* @param handle - user handle e.g. `alice.smith.qa@example.com`
|
1223
1221
|
* @param expiryDays - generated x509 certificate expiry
|
@@ -1232,7 +1230,7 @@ export declare class CoreCrypto {
|
|
1232
1230
|
* has been revoked. It lets you change the DisplayName or the handle
|
1233
1231
|
* if you need to. Once the enrollment is finished, use the instance in {@link CoreCrypto.e2eiRotateAll} to do the rotation.
|
1234
1232
|
*
|
1235
|
-
* @param clientId - client identifier
|
1233
|
+
* @param clientId - client identifier e.g. `b7ac11a4-8f01-4527-af88-1c30885a7931:6add501bacd1d90e@example.com`
|
1236
1234
|
* @param expiryDays - generated x509 certificate expiry
|
1237
1235
|
* @param ciphersuite - for generating signing key material
|
1238
1236
|
* @param displayName - human-readable name displayed in the application e.g. `Smith, Alice M (QA)`
|
@@ -1307,7 +1305,7 @@ export declare class CoreCrypto {
|
|
1307
1305
|
* If no member has a x509 certificate, it will return an empty Vec.
|
1308
1306
|
*
|
1309
1307
|
* @param conversationId - identifier of the conversation
|
1310
|
-
* @param userIds - user identifiers e.g.
|
1308
|
+
* @param userIds - user identifiers hyphenated UUIDv4 e.g. 'bd4c7053-1c5a-4020-9559-cd7bf7961954'
|
1311
1309
|
* @returns a Map with all the identities for a given users. Consumers are then recommended to reduce those identities to determine the actual status of a user.
|
1312
1310
|
*/
|
1313
1311
|
getUserIdentities(conversationId: ConversationId, userIds: string[]): Promise<Map<string, WireIdentity[]>>;
|
@@ -1,12 +1,4 @@
|
|
1
1
|
// bindings/js/wasm/core-crypto-ffi.js
|
2
|
-
var addHeapObject = function(obj) {
|
3
|
-
if (heap_next === heap.length)
|
4
|
-
heap.push(heap.length + 1);
|
5
|
-
const idx = heap_next;
|
6
|
-
heap_next = heap[idx];
|
7
|
-
heap[idx] = obj;
|
8
|
-
return idx;
|
9
|
-
};
|
10
2
|
var getObject = function(idx) {
|
11
3
|
return heap[idx];
|
12
4
|
};
|
@@ -21,6 +13,14 @@ var takeObject = function(idx) {
|
|
21
13
|
dropObject(idx);
|
22
14
|
return ret;
|
23
15
|
};
|
16
|
+
var addHeapObject = function(obj) {
|
17
|
+
if (heap_next === heap.length)
|
18
|
+
heap.push(heap.length + 1);
|
19
|
+
const idx = heap_next;
|
20
|
+
heap_next = heap[idx];
|
21
|
+
heap[idx] = obj;
|
22
|
+
return idx;
|
23
|
+
};
|
24
24
|
var getUint8Memory0 = function() {
|
25
25
|
if (cachedUint8Memory0 === null || cachedUint8Memory0.byteLength === 0) {
|
26
26
|
cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);
|
@@ -262,22 +262,6 @@ async function __wbg_load(module, imports) {
|
|
262
262
|
var __wbg_get_imports = function() {
|
263
263
|
const imports = {};
|
264
264
|
imports.wbg = {};
|
265
|
-
imports.wbg.__wbindgen_number_new = function(arg0) {
|
266
|
-
const ret = arg0;
|
267
|
-
return addHeapObject(ret);
|
268
|
-
};
|
269
|
-
imports.wbg.__wbg_ffiwiree2eidentity_new = function(arg0) {
|
270
|
-
const ret = FfiWireE2EIdentity.__wrap(arg0);
|
271
|
-
return addHeapObject(ret);
|
272
|
-
};
|
273
|
-
imports.wbg.__wbg_proposalbundle_new = function(arg0) {
|
274
|
-
const ret = ProposalBundle.__wrap(arg0);
|
275
|
-
return addHeapObject(ret);
|
276
|
-
};
|
277
|
-
imports.wbg.__wbg_buffereddecryptedmessage_new = function(arg0) {
|
278
|
-
const ret = BufferedDecryptedMessage.__wrap(arg0);
|
279
|
-
return addHeapObject(ret);
|
280
|
-
};
|
281
265
|
imports.wbg.__wbg_proteusautoprekeybundle_new = function(arg0) {
|
282
266
|
const ret = ProteusAutoPrekeyBundle.__wrap(arg0);
|
283
267
|
return addHeapObject(ret);
|
@@ -289,22 +273,38 @@ var __wbg_get_imports = function() {
|
|
289
273
|
const ret = CommitBundle.__wrap(arg0);
|
290
274
|
return addHeapObject(ret);
|
291
275
|
};
|
276
|
+
imports.wbg.__wbindgen_number_new = function(arg0) {
|
277
|
+
const ret = arg0;
|
278
|
+
return addHeapObject(ret);
|
279
|
+
};
|
292
280
|
imports.wbg.__wbg_corecrypto_new = function(arg0) {
|
293
281
|
const ret = CoreCrypto.__wrap(arg0);
|
294
282
|
return addHeapObject(ret);
|
295
283
|
};
|
296
|
-
imports.wbg.
|
297
|
-
const ret =
|
284
|
+
imports.wbg.__wbg_buffereddecryptedmessage_new = function(arg0) {
|
285
|
+
const ret = BufferedDecryptedMessage.__wrap(arg0);
|
298
286
|
return addHeapObject(ret);
|
299
287
|
};
|
300
|
-
imports.wbg.
|
301
|
-
const ret =
|
288
|
+
imports.wbg.__wbg_ffiwiree2eidentity_new = function(arg0) {
|
289
|
+
const ret = FfiWireE2EIdentity.__wrap(arg0);
|
290
|
+
return addHeapObject(ret);
|
291
|
+
};
|
292
|
+
imports.wbg.__wbg_proposalbundle_new = function(arg0) {
|
293
|
+
const ret = ProposalBundle.__wrap(arg0);
|
294
|
+
return addHeapObject(ret);
|
295
|
+
};
|
296
|
+
imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
|
297
|
+
const ret = getObject(arg0);
|
302
298
|
return addHeapObject(ret);
|
303
299
|
};
|
304
300
|
imports.wbg.__wbindgen_is_null = function(arg0) {
|
305
301
|
const ret = getObject(arg0) === null;
|
306
302
|
return ret;
|
307
303
|
};
|
304
|
+
imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {
|
305
|
+
const ret = BigInt.asUintN(64, arg0);
|
306
|
+
return addHeapObject(ret);
|
307
|
+
};
|
308
308
|
imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
|
309
309
|
const obj = getObject(arg1);
|
310
310
|
const ret = typeof obj === "string" ? obj : undefined;
|
@@ -950,12 +950,12 @@ var __wbg_get_imports = function() {
|
|
950
950
|
const ret = wasm.memory;
|
951
951
|
return addHeapObject(ret);
|
952
952
|
};
|
953
|
-
imports.wbg.
|
953
|
+
imports.wbg.__wbindgen_closure_wrapper2200 = function(arg0, arg1, arg2) {
|
954
954
|
const ret = makeMutClosure(arg0, arg1, 356, __wbg_adapter_52);
|
955
955
|
return addHeapObject(ret);
|
956
956
|
};
|
957
957
|
imports.wbg.__wbindgen_closure_wrapper9921 = function(arg0, arg1, arg2) {
|
958
|
-
const ret = makeMutClosure(arg0, arg1,
|
958
|
+
const ret = makeMutClosure(arg0, arg1, 1326, __wbg_adapter_55);
|
959
959
|
return addHeapObject(ret);
|
960
960
|
};
|
961
961
|
return imports;
|
@@ -1017,6 +1017,18 @@ if (typeof TextDecoder !== "undefined") {
|
|
1017
1017
|
var cachedBigInt64Memory0 = null;
|
1018
1018
|
var cachedUint32Memory0 = null;
|
1019
1019
|
var cachedUint16Memory0 = null;
|
1020
|
+
var WirePolicy = Object.freeze({
|
1021
|
+
Plaintext: 1,
|
1022
|
+
"1": "Plaintext",
|
1023
|
+
Ciphertext: 2,
|
1024
|
+
"2": "Ciphertext"
|
1025
|
+
});
|
1026
|
+
var CredentialType = Object.freeze({
|
1027
|
+
Basic: 1,
|
1028
|
+
"1": "Basic",
|
1029
|
+
X509: 2,
|
1030
|
+
"2": "X509"
|
1031
|
+
});
|
1020
1032
|
var DeviceStatus = Object.freeze({
|
1021
1033
|
Valid: 0,
|
1022
1034
|
"0": "Valid",
|
@@ -1025,12 +1037,6 @@ var DeviceStatus = Object.freeze({
|
|
1025
1037
|
Revoked: 2,
|
1026
1038
|
"2": "Revoked"
|
1027
1039
|
});
|
1028
|
-
var CredentialType = Object.freeze({
|
1029
|
-
Basic: 1,
|
1030
|
-
"1": "Basic",
|
1031
|
-
X509: 2,
|
1032
|
-
"2": "X509"
|
1033
|
-
});
|
1034
1040
|
var Ciphersuite = Object.freeze({
|
1035
1041
|
MLS_128_DHKEMX25519_AES128GCM_SHA256_Ed25519: 1,
|
1036
1042
|
"1": "MLS_128_DHKEMX25519_AES128GCM_SHA256_Ed25519",
|
@@ -1049,12 +1055,6 @@ var Ciphersuite = Object.freeze({
|
|
1049
1055
|
MLS_128_X25519KYBER768DRAFT00_AES128GCM_SHA256_Ed25519: 61489,
|
1050
1056
|
"61489": "MLS_128_X25519KYBER768DRAFT00_AES128GCM_SHA256_Ed25519"
|
1051
1057
|
});
|
1052
|
-
var WirePolicy = Object.freeze({
|
1053
|
-
Plaintext: 1,
|
1054
|
-
"1": "Plaintext",
|
1055
|
-
Ciphertext: 2,
|
1056
|
-
"2": "Ciphertext"
|
1057
|
-
});
|
1058
1058
|
|
1059
1059
|
class AcmeChallenge {
|
1060
1060
|
static __wrap(ptr) {
|