@wireapp/core-crypto 1.0.0-rc.58 → 1.0.0-rc.59

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wireapp/core-crypto",
3
- "version": "1.0.0-rc.58",
3
+ "version": "1.0.0-rc.59",
4
4
  "description": "CoreCrypto bindings for the Web",
5
5
  "type": "module",
6
6
  "module": "platforms/web/corecrypto.js",
@@ -1,4 +1,12 @@
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
+ };
2
10
  var getObject = function(idx) {
3
11
  return heap[idx];
4
12
  };
@@ -13,14 +21,6 @@ var takeObject = function(idx) {
13
21
  dropObject(idx);
14
22
  return ret;
15
23
  };
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);
@@ -265,23 +265,24 @@ async function __wbg_load(module, imports) {
265
265
  var __wbg_get_imports = function() {
266
266
  const imports = {};
267
267
  imports.wbg = {};
268
- imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
269
- takeObject(arg0);
268
+ imports.wbg.__wbindgen_number_new = function(arg0) {
269
+ const ret = arg0;
270
+ return addHeapObject(ret);
270
271
  };
271
- imports.wbg.__wbg_corecrypto_new = function(arg0) {
272
- const ret = CoreCrypto.__wrap(arg0);
272
+ imports.wbg.__wbg_commitbundle_new = function(arg0) {
273
+ const ret = CommitBundle.__wrap(arg0);
273
274
  return addHeapObject(ret);
274
275
  };
275
- imports.wbg.__wbg_buffereddecryptedmessage_new = function(arg0) {
276
- const ret = BufferedDecryptedMessage.__wrap(arg0);
276
+ imports.wbg.__wbg_newacmeorder_new = function(arg0) {
277
+ const ret = NewAcmeOrder.__wrap(arg0);
277
278
  return addHeapObject(ret);
278
279
  };
279
- imports.wbg.__wbindgen_number_new = function(arg0) {
280
- const ret = arg0;
280
+ imports.wbg.__wbg_proteusautoprekeybundle_new = function(arg0) {
281
+ const ret = ProteusAutoPrekeyBundle.__wrap(arg0);
281
282
  return addHeapObject(ret);
282
283
  };
283
- imports.wbg.__wbg_proposalbundle_new = function(arg0) {
284
- const ret = ProposalBundle.__wrap(arg0);
284
+ imports.wbg.__wbg_corecrypto_new = function(arg0) {
285
+ const ret = CoreCrypto.__wrap(arg0);
285
286
  return addHeapObject(ret);
286
287
  };
287
288
  imports.wbg.__wbg_newacmeauthz_new = function(arg0) {
@@ -292,20 +293,19 @@ var __wbg_get_imports = function() {
292
293
  const ret = FfiWireE2EIdentity.__wrap(arg0);
293
294
  return addHeapObject(ret);
294
295
  };
295
- imports.wbg.__wbg_commitbundle_new = function(arg0) {
296
- const ret = CommitBundle.__wrap(arg0);
297
- return addHeapObject(ret);
298
- };
299
296
  imports.wbg.__wbg_acmedirectory_new = function(arg0) {
300
297
  const ret = AcmeDirectory.__wrap(arg0);
301
298
  return addHeapObject(ret);
302
299
  };
303
- imports.wbg.__wbg_proteusautoprekeybundle_new = function(arg0) {
304
- const ret = ProteusAutoPrekeyBundle.__wrap(arg0);
300
+ imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
301
+ takeObject(arg0);
302
+ };
303
+ imports.wbg.__wbg_buffereddecryptedmessage_new = function(arg0) {
304
+ const ret = BufferedDecryptedMessage.__wrap(arg0);
305
305
  return addHeapObject(ret);
306
306
  };
307
- imports.wbg.__wbg_newacmeorder_new = function(arg0) {
308
- const ret = NewAcmeOrder.__wrap(arg0);
307
+ imports.wbg.__wbg_proposalbundle_new = function(arg0) {
308
+ const ret = ProposalBundle.__wrap(arg0);
309
309
  return addHeapObject(ret);
310
310
  };
311
311
  imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
@@ -316,10 +316,6 @@ var __wbg_get_imports = function() {
316
316
  const ret = getStringFromWasm0(arg0, arg1);
317
317
  return addHeapObject(ret);
318
318
  };
319
- imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {
320
- const ret = BigInt.asUintN(64, arg0);
321
- return addHeapObject(ret);
322
- };
323
319
  imports.wbg.__wbindgen_is_undefined = function(arg0) {
324
320
  const ret = getObject(arg0) === undefined;
325
321
  return ret;
@@ -328,6 +324,10 @@ var __wbg_get_imports = function() {
328
324
  const ret = getObject(arg0) === null;
329
325
  return ret;
330
326
  };
327
+ imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {
328
+ const ret = BigInt.asUintN(64, arg0);
329
+ return addHeapObject(ret);
330
+ };
331
331
  imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
332
332
  const obj = getObject(arg1);
333
333
  const ret = typeof obj === "string" ? obj : undefined;
@@ -984,7 +984,7 @@ var __wbg_get_imports = function() {
984
984
  return addHeapObject(ret);
985
985
  };
986
986
  imports.wbg.__wbindgen_closure_wrapper13251 = function(arg0, arg1, arg2) {
987
- const ret = makeMutClosure(arg0, arg1, 2142, __wbg_adapter_57);
987
+ const ret = makeMutClosure(arg0, arg1, 2143, __wbg_adapter_57);
988
988
  return addHeapObject(ret);
989
989
  };
990
990
  return imports;
@@ -1051,6 +1051,26 @@ var CLOSURE_DTORS = typeof FinalizationRegistry === "undefined" ? { register: ()
1051
1051
  });
1052
1052
  var cachedUint32Memory0 = null;
1053
1053
  var cachedUint16Memory0 = null;
1054
+ var WirePolicy = Object.freeze({
1055
+ Plaintext: 1,
1056
+ "1": "Plaintext",
1057
+ Ciphertext: 2,
1058
+ "2": "Ciphertext"
1059
+ });
1060
+ var CredentialType = Object.freeze({
1061
+ Basic: 1,
1062
+ "1": "Basic",
1063
+ X509: 2,
1064
+ "2": "X509"
1065
+ });
1066
+ var DeviceStatus = Object.freeze({
1067
+ Valid: 1,
1068
+ "1": "Valid",
1069
+ Expired: 2,
1070
+ "2": "Expired",
1071
+ Revoked: 3,
1072
+ "3": "Revoked"
1073
+ });
1054
1074
  var Ciphersuite = Object.freeze({
1055
1075
  MLS_128_DHKEMX25519_AES128GCM_SHA256_Ed25519: 1,
1056
1076
  "1": "MLS_128_DHKEMX25519_AES128GCM_SHA256_Ed25519",
@@ -1069,26 +1089,6 @@ var Ciphersuite = Object.freeze({
1069
1089
  MLS_128_X25519KYBER768DRAFT00_AES128GCM_SHA256_Ed25519: 61489,
1070
1090
  "61489": "MLS_128_X25519KYBER768DRAFT00_AES128GCM_SHA256_Ed25519"
1071
1091
  });
1072
- var WirePolicy = Object.freeze({
1073
- Plaintext: 1,
1074
- "1": "Plaintext",
1075
- Ciphertext: 2,
1076
- "2": "Ciphertext"
1077
- });
1078
- var DeviceStatus = Object.freeze({
1079
- Valid: 1,
1080
- "1": "Valid",
1081
- Expired: 2,
1082
- "2": "Expired",
1083
- Revoked: 3,
1084
- "3": "Revoked"
1085
- });
1086
- var CredentialType = Object.freeze({
1087
- Basic: 1,
1088
- "1": "Basic",
1089
- X509: 2,
1090
- "2": "X509"
1091
- });
1092
1092
  var AcmeChallengeFinalization = typeof FinalizationRegistry === "undefined" ? { register: () => {
1093
1093
  }, unregister: () => {
1094
1094
  } } : new FinalizationRegistry((ptr) => wasm.__wbg_acmechallenge_free(ptr >>> 0));