cojson-core-wasm 0.20.9 → 0.20.10

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cojson-core-wasm",
3
3
  "type": "module",
4
- "version": "0.20.9",
4
+ "version": "0.20.10",
5
5
  "files": [
6
6
  "public/cojson_core_wasm.js",
7
7
  "public/cojson_core_wasm.d.ts",
@@ -1,33 +1,43 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
3
  /**
4
- * Compute a short hash of a stable-stringified JSON value.
5
- * The input should already be serialized using stableStringify on the JS side.
6
- * Returns a string prefixed with "shortHash_z" followed by base58-encoded hash.
4
+ * WASM-exposed function for sealing a message for a group (anonymous box pattern).
5
+ * Uses an ephemeral key pair, so no sender authentication is provided.
6
+ * - `message`: Raw bytes to seal
7
+ * - `recipient_id`: Base58-encoded recipient's public key with "sealer_z" prefix (the group's sealer)
8
+ * - `nonce_material`: Raw bytes used to generate the nonce
9
+ * Returns ephemeral_public_key (32 bytes) || ciphertext, or throws JsError if sealing fails.
7
10
  */
8
- export function shortHash(value: string): string;
11
+ export function sealForGroup(message: Uint8Array, recipient_id: string, nonce_material: Uint8Array): Uint8Array;
9
12
  /**
10
- * Generate a 24-byte nonce from input material using BLAKE3.
11
- * - `nonce_material`: Raw bytes to derive the nonce from
12
- * Returns 24 bytes suitable for use as a nonce in cryptographic operations.
13
- * This function is deterministic - the same input will produce the same nonce.
13
+ * WASM-exposed function for sealing a message using X25519 + XSalsa20-Poly1305.
14
+ * Provides authenticated encryption with perfect forward secrecy.
15
+ * - `message`: Raw bytes to seal
16
+ * - `sender_secret`: Base58-encoded sender's private key with "sealerSecret_z" prefix
17
+ * - `recipient_id`: Base58-encoded recipient's public key with "sealer_z" prefix
18
+ * - `nonce_material`: Raw bytes used to generate the nonce
19
+ * Returns sealed bytes or throws JsError if sealing fails.
14
20
  */
15
- export function generateNonce(nonce_material: Uint8Array): Uint8Array;
21
+ export function seal(message: Uint8Array, sender_secret: string, recipient_id: string, nonce_material: Uint8Array): Uint8Array;
16
22
  /**
17
- * Hash data once using BLAKE3.
18
- * - `data`: Raw bytes to hash
19
- * Returns 32 bytes of hash output.
20
- * This is the simplest way to compute a BLAKE3 hash of a single piece of data.
23
+ * WASM-exposed function for unsealing a message using X25519 + XSalsa20-Poly1305.
24
+ * Provides authenticated decryption with perfect forward secrecy.
25
+ * - `sealed_message`: The sealed bytes to decrypt
26
+ * - `recipient_secret`: Base58-encoded recipient's private key with "sealerSecret_z" prefix
27
+ * - `sender_id`: Base58-encoded sender's public key with "sealer_z" prefix
28
+ * - `nonce_material`: Raw bytes used to generate the nonce (must match sealing)
29
+ * Returns unsealed bytes or throws JsError if unsealing fails.
21
30
  */
22
- export function blake3HashOnce(data: Uint8Array): Uint8Array;
31
+ export function unseal(sealed_message: Uint8Array, recipient_secret: string, sender_id: string, nonce_material: Uint8Array): Uint8Array;
23
32
  /**
24
- * Hash data once using BLAKE3 with a context prefix.
25
- * - `data`: Raw bytes to hash
26
- * - `context`: Context bytes to prefix to the data
27
- * Returns 32 bytes of hash output.
28
- * This is useful for domain separation - the same data hashed with different contexts will produce different outputs.
33
+ * WASM-exposed function for unsealing a message sealed for a group (anonymous box pattern).
34
+ * Extracts the ephemeral public key and decrypts the message.
35
+ * - `sealed_message`: ephemeral_public_key (32 bytes) || ciphertext
36
+ * - `recipient_secret`: Base58-encoded recipient's private key with "sealerSecret_z" prefix
37
+ * - `nonce_material`: Raw bytes used to generate the nonce (must match sealing)
38
+ * Returns unsealed bytes or throws JsError if unsealing fails.
29
39
  */
30
- export function blake3HashOnceWithContext(data: Uint8Array, context: Uint8Array): Uint8Array;
40
+ export function unsealForGroup(sealed_message: Uint8Array, recipient_secret: string, nonce_material: Uint8Array): Uint8Array;
31
41
  /**
32
42
  * WASM-exposed function to encrypt bytes with a key secret and nonce material.
33
43
  * - `value`: The raw bytes to encrypt
@@ -44,6 +54,40 @@ export function encrypt(value: Uint8Array, key_secret: string, nonce_material: U
44
54
  * Returns the decrypted bytes or throws a JsError if decryption fails.
45
55
  */
46
56
  export function decrypt(ciphertext: Uint8Array, key_secret: string, nonce_material: Uint8Array): Uint8Array;
57
+ /**
58
+ * Generate a 24-byte nonce from input material using BLAKE3.
59
+ * - `nonce_material`: Raw bytes to derive the nonce from
60
+ * Returns 24 bytes suitable for use as a nonce in cryptographic operations.
61
+ * This function is deterministic - the same input will produce the same nonce.
62
+ */
63
+ export function generateNonce(nonce_material: Uint8Array): Uint8Array;
64
+ /**
65
+ * Compute a short hash of a stable-stringified JSON value.
66
+ * The input should already be serialized using stableStringify on the JS side.
67
+ * Returns a string prefixed with "shortHash_z" followed by base58-encoded hash.
68
+ */
69
+ export function shortHash(value: string): string;
70
+ /**
71
+ * Hash data once using BLAKE3 with a context prefix.
72
+ * - `data`: Raw bytes to hash
73
+ * - `context`: Context bytes to prefix to the data
74
+ * Returns 32 bytes of hash output.
75
+ * This is useful for domain separation - the same data hashed with different contexts will produce different outputs.
76
+ */
77
+ export function blake3HashOnceWithContext(data: Uint8Array, context: Uint8Array): Uint8Array;
78
+ /**
79
+ * Hash data once using BLAKE3.
80
+ * - `data`: Raw bytes to hash
81
+ * Returns 32 bytes of hash output.
82
+ * This is the simplest way to compute a BLAKE3 hash of a single piece of data.
83
+ */
84
+ export function blake3HashOnce(data: Uint8Array): Uint8Array;
85
+ /**
86
+ * WASM-exposed function to derive a sealer ID from a sealer secret.
87
+ * - `secret`: Raw bytes of the sealer secret
88
+ * Returns a base58-encoded sealer ID with "sealer_z" prefix or throws JsError if derivation fails.
89
+ */
90
+ export function getSealerId(secret: Uint8Array): string;
47
91
  /**
48
92
  * Generate a new X25519 private key using secure random number generation.
49
93
  * Returns 32 bytes of raw key material suitable for use with other X25519 functions.
@@ -64,11 +108,14 @@ export function x25519PublicKey(private_key: Uint8Array): Uint8Array;
64
108
  */
65
109
  export function x25519DiffieHellman(private_key: Uint8Array, public_key: Uint8Array): Uint8Array;
66
110
  /**
67
- * WASM-exposed function to derive a sealer ID from a sealer secret.
68
- * - `secret`: Raw bytes of the sealer secret
69
- * Returns a base58-encoded sealer ID with "sealer_z" prefix or throws JsError if derivation fails.
111
+ * WASM-exposed function for XSalsa20 decryption without authentication.
112
+ * - `key`: 32-byte key for decryption (must match encryption key)
113
+ * - `nonce_material`: Raw bytes used to generate a 24-byte nonce (must match encryption)
114
+ * - `ciphertext`: Encrypted bytes to decrypt
115
+ * Returns the decrypted bytes or throws a JsError if decryption fails.
116
+ * Note: This function does not provide authentication. Use decrypt_xsalsa20_poly1305 for authenticated decryption.
70
117
  */
71
- export function getSealerId(secret: Uint8Array): string;
118
+ export function decryptXsalsa20(key: Uint8Array, nonce_material: Uint8Array, ciphertext: Uint8Array): Uint8Array;
72
119
  /**
73
120
  * WASM-exposed function for XSalsa20 encryption without authentication.
74
121
  * - `key`: 32-byte key for encryption
@@ -78,15 +125,6 @@ export function getSealerId(secret: Uint8Array): string;
78
125
  * Note: This function does not provide authentication. Use encrypt_xsalsa20_poly1305 for authenticated encryption.
79
126
  */
80
127
  export function encryptXsalsa20(key: Uint8Array, nonce_material: Uint8Array, plaintext: Uint8Array): Uint8Array;
81
- /**
82
- * WASM-exposed function for XSalsa20 decryption without authentication.
83
- * - `key`: 32-byte key for decryption (must match encryption key)
84
- * - `nonce_material`: Raw bytes used to generate a 24-byte nonce (must match encryption)
85
- * - `ciphertext`: Encrypted bytes to decrypt
86
- * Returns the decrypted bytes or throws a JsError if decryption fails.
87
- * Note: This function does not provide authentication. Use decrypt_xsalsa20_poly1305 for authenticated decryption.
88
- */
89
- export function decryptXsalsa20(key: Uint8Array, nonce_material: Uint8Array, ciphertext: Uint8Array): Uint8Array;
90
128
  /**
91
129
  * WASM-exposed function to sign a message using Ed25519.
92
130
  * - `message`: Raw bytes to sign
@@ -109,54 +147,34 @@ export function verify(signature: Uint8Array, message: Uint8Array, id: Uint8Arra
109
147
  */
110
148
  export function getSignerId(secret: Uint8Array): string;
111
149
  /**
112
- * WASM-exposed function for sealing a message using X25519 + XSalsa20-Poly1305.
113
- * Provides authenticated encryption with perfect forward secrecy.
114
- * - `message`: Raw bytes to seal
115
- * - `sender_secret`: Base58-encoded sender's private key with "sealerSecret_z" prefix
116
- * - `recipient_id`: Base58-encoded recipient's public key with "sealer_z" prefix
117
- * - `nonce_material`: Raw bytes used to generate the nonce
118
- * Returns sealed bytes or throws JsError if sealing fails.
150
+ * WASM-exposed function to validate and copy Ed25519 signature bytes.
151
+ * - `bytes`: 64 bytes of signature material to validate
152
+ * Returns the same 64 bytes if valid or throws JsError if invalid.
119
153
  */
120
- export function seal(message: Uint8Array, sender_secret: string, recipient_id: string, nonce_material: Uint8Array): Uint8Array;
154
+ export function ed25519SignatureFromBytes(bytes: Uint8Array): Uint8Array;
121
155
  /**
122
- * WASM-exposed function for unsealing a message using X25519 + XSalsa20-Poly1305.
123
- * Provides authenticated decryption with perfect forward secrecy.
124
- * - `sealed_message`: The sealed bytes to decrypt
125
- * - `recipient_secret`: Base58-encoded recipient's private key with "sealerSecret_z" prefix
126
- * - `sender_id`: Base58-encoded sender's public key with "sealer_z" prefix
127
- * - `nonce_material`: Raw bytes used to generate the nonce (must match sealing)
128
- * Returns unsealed bytes or throws JsError if unsealing fails.
156
+ * WASM-exposed function to validate and copy Ed25519 verifying key bytes.
157
+ * - `bytes`: 32 bytes of verifying key material to validate
158
+ * Returns the same 32 bytes if valid or throws JsError if invalid.
129
159
  */
130
- export function unseal(sealed_message: Uint8Array, recipient_secret: string, sender_id: string, nonce_material: Uint8Array): Uint8Array;
160
+ export function ed25519VerifyingKeyFromBytes(bytes: Uint8Array): Uint8Array;
131
161
  /**
132
- * WASM-exposed function for sealing a message for a group (anonymous box pattern).
133
- * Uses an ephemeral key pair, so no sender authentication is provided.
134
- * - `message`: Raw bytes to seal
135
- * - `recipient_id`: Base58-encoded recipient's public key with "sealer_z" prefix (the group's sealer)
136
- * - `nonce_material`: Raw bytes used to generate the nonce
137
- * Returns ephemeral_public_key (32 bytes) || ciphertext, or throws JsError if sealing fails.
162
+ * WASM-exposed function to derive the public key from an Ed25519 signing key.
163
+ * - `signing_key`: 32 bytes of signing key material
164
+ * Returns 32 bytes of public key material or throws JsError if key is invalid.
138
165
  */
139
- export function sealForGroup(message: Uint8Array, recipient_id: string, nonce_material: Uint8Array): Uint8Array;
166
+ export function ed25519SigningKeyToPublic(signing_key: Uint8Array): Uint8Array;
140
167
  /**
141
- * WASM-exposed function for unsealing a message sealed for a group (anonymous box pattern).
142
- * Extracts the ephemeral public key and decrypts the message.
143
- * - `sealed_message`: ephemeral_public_key (32 bytes) || ciphertext
144
- * - `recipient_secret`: Base58-encoded recipient's private key with "sealerSecret_z" prefix
145
- * - `nonce_material`: Raw bytes used to generate the nonce (must match sealing)
146
- * Returns unsealed bytes or throws JsError if unsealing fails.
168
+ * WASM-exposed function to derive an Ed25519 verifying key from a signing key.
169
+ * - `signing_key`: 32 bytes of signing key material
170
+ * Returns 32 bytes of verifying key material or throws JsError if key is invalid.
147
171
  */
148
- export function unsealForGroup(sealed_message: Uint8Array, recipient_secret: string, nonce_material: Uint8Array): Uint8Array;
172
+ export function ed25519VerifyingKey(signing_key: Uint8Array): Uint8Array;
149
173
  /**
150
174
  * Generate a new Ed25519 signing key using secure random number generation.
151
175
  * Returns 32 bytes of raw key material suitable for use with other Ed25519 functions.
152
176
  */
153
177
  export function newEd25519SigningKey(): Uint8Array;
154
- /**
155
- * WASM-exposed function to derive an Ed25519 verifying key from a signing key.
156
- * - `signing_key`: 32 bytes of signing key material
157
- * Returns 32 bytes of verifying key material or throws JsError if key is invalid.
158
- */
159
- export function ed25519VerifyingKey(signing_key: Uint8Array): Uint8Array;
160
178
  /**
161
179
  * WASM-exposed function to sign a message using Ed25519.
162
180
  * - `signing_key`: 32 bytes of signing key material
@@ -164,14 +182,6 @@ export function ed25519VerifyingKey(signing_key: Uint8Array): Uint8Array;
164
182
  * Returns 64 bytes of signature material or throws JsError if signing fails.
165
183
  */
166
184
  export function ed25519Sign(signing_key: Uint8Array, message: Uint8Array): Uint8Array;
167
- /**
168
- * WASM-exposed function to verify an Ed25519 signature.
169
- * - `verifying_key`: 32 bytes of verifying key material
170
- * - `message`: Raw bytes that were signed
171
- * - `signature`: 64 bytes of signature material
172
- * Returns true if signature is valid, false otherwise, or throws JsError if verification fails.
173
- */
174
- export function ed25519Verify(verifying_key: Uint8Array, message: Uint8Array, signature: Uint8Array): boolean;
175
185
  /**
176
186
  * WASM-exposed function to validate and copy Ed25519 signing key bytes.
177
187
  * - `bytes`: 32 bytes of signing key material to validate
@@ -179,11 +189,13 @@ export function ed25519Verify(verifying_key: Uint8Array, message: Uint8Array, si
179
189
  */
180
190
  export function ed25519SigningKeyFromBytes(bytes: Uint8Array): Uint8Array;
181
191
  /**
182
- * WASM-exposed function to derive the public key from an Ed25519 signing key.
183
- * - `signing_key`: 32 bytes of signing key material
184
- * Returns 32 bytes of public key material or throws JsError if key is invalid.
192
+ * WASM-exposed function to verify an Ed25519 signature.
193
+ * - `verifying_key`: 32 bytes of verifying key material
194
+ * - `message`: Raw bytes that were signed
195
+ * - `signature`: 64 bytes of signature material
196
+ * Returns true if signature is valid, false otherwise, or throws JsError if verification fails.
185
197
  */
186
- export function ed25519SigningKeyToPublic(signing_key: Uint8Array): Uint8Array;
198
+ export function ed25519Verify(verifying_key: Uint8Array, message: Uint8Array, signature: Uint8Array): boolean;
187
199
  /**
188
200
  * WASM-exposed function to sign a message with an Ed25519 signing key.
189
201
  * - `signing_key`: 32 bytes of signing key material
@@ -191,110 +203,98 @@ export function ed25519SigningKeyToPublic(signing_key: Uint8Array): Uint8Array;
191
203
  * Returns 64 bytes of signature material or throws JsError if signing fails.
192
204
  */
193
205
  export function ed25519SigningKeySign(signing_key: Uint8Array, message: Uint8Array): Uint8Array;
194
- /**
195
- * WASM-exposed function to validate and copy Ed25519 verifying key bytes.
196
- * - `bytes`: 32 bytes of verifying key material to validate
197
- * Returns the same 32 bytes if valid or throws JsError if invalid.
198
- */
199
- export function ed25519VerifyingKeyFromBytes(bytes: Uint8Array): Uint8Array;
200
- /**
201
- * WASM-exposed function to validate and copy Ed25519 signature bytes.
202
- * - `bytes`: 64 bytes of signature material to validate
203
- * Returns the same 64 bytes if valid or throws JsError if invalid.
204
- */
205
- export function ed25519SignatureFromBytes(bytes: Uint8Array): Uint8Array;
206
206
  export class Blake3Hasher {
207
207
  free(): void;
208
208
  constructor();
209
+ clone(): Blake3Hasher;
209
210
  update(data: Uint8Array): void;
210
211
  finalize(): Uint8Array;
211
- clone(): Blake3Hasher;
212
212
  }
213
213
  export class SessionMap {
214
214
  free(): void;
215
- /**
216
- * Create a new SessionMap for a CoValue
217
- * `max_tx_size` is the threshold for recording in-between signatures (default: 100KB)
218
- * Create a new SessionMap for a CoValue.
219
- * Validates the header and verifies that `co_id` matches the hash of the header.
220
- * `max_tx_size` is the threshold for recording in-between signatures (default: 100KB)
221
- * `skip_verify` if true, skips uniqueness and ID validation (for trusted storage shards)
222
- */
223
- constructor(co_id: string, header_json: string, max_tx_size?: number | null, skip_verify?: boolean | null);
224
215
  /**
225
216
  * Get the header as JSON
226
217
  */
227
218
  getHeader(): string;
228
219
  /**
229
- * Add transactions to a session
230
- */
231
- addTransactions(session_id: string, signer_id: string | null | undefined, transactions_json: string, signature: string, skip_verify: boolean): void;
232
- /**
233
- * Create new private transaction (for local writes)
234
- * Returns JSON: { signature: string, transaction: Transaction }
220
+ * Check if this CoValue is deleted
235
221
  */
236
- makeNewPrivateTransaction(session_id: string, signer_secret: string, changes_json: string, key_id: string, key_secret: string, meta_json: string | null | undefined, made_at: number): string;
222
+ isDeleted(): boolean;
237
223
  /**
238
- * Create new trusting transaction (for local writes)
239
- * Returns JSON: { signature: string, transaction: Transaction }
224
+ * Get the known state as a native JavaScript object
240
225
  */
241
- makeNewTrustingTransaction(session_id: string, signer_secret: string, changes_json: string, meta_json: string | null | undefined, made_at: number): string;
226
+ getKnownState(): any;
242
227
  /**
243
228
  * Get all session IDs as native array
244
229
  */
245
230
  getSessionIds(): string[];
246
- /**
247
- * Get transaction count for a session (returns -1 if session not found)
248
- */
249
- getTransactionCount(session_id: string): number;
250
231
  /**
251
232
  * Get single transaction by index as JSON string (returns undefined if not found)
252
233
  */
253
234
  getTransaction(session_id: string, tx_index: number): string | undefined;
254
235
  /**
255
- * Get transactions for a session from index as JSON strings (returns undefined if session not found)
236
+ * Mark this CoValue as deleted
256
237
  */
257
- getSessionTransactions(session_id: string, from_index: number): string[] | undefined;
238
+ markAsDeleted(): void;
239
+ /**
240
+ * Add transactions to a session
241
+ */
242
+ addTransactions(session_id: string, signer_id: string | null | undefined, transactions_json: string, signature: string, skip_verify: boolean): void;
258
243
  /**
259
244
  * Get last signature for a session (returns undefined if session not found)
260
245
  */
261
246
  getLastSignature(session_id: string): string | undefined;
247
+ /**
248
+ * Decrypt transaction changes
249
+ */
250
+ decryptTransaction(session_id: string, tx_index: number, key_secret: string): string | undefined;
262
251
  /**
263
252
  * Get signature after specific transaction index
264
253
  */
265
254
  getSignatureAfter(session_id: string, tx_index: number): string | undefined;
266
255
  /**
267
- * Get the last signature checkpoint index (-1 if no checkpoints, undefined if session not found)
256
+ * Get transaction count for a session (returns -1 if session not found)
268
257
  */
269
- getLastSignatureCheckpoint(session_id: string): number | undefined;
258
+ getTransactionCount(session_id: string): number;
270
259
  /**
271
- * Get the known state as a native JavaScript object
260
+ * Decrypt transaction meta
272
261
  */
273
- getKnownState(): any;
262
+ decryptTransactionMeta(session_id: string, tx_index: number, key_secret: string): string | undefined;
274
263
  /**
275
- * Get the known state with streaming as a native JavaScript object
264
+ * Get transactions for a session from index as JSON strings (returns undefined if session not found)
276
265
  */
277
- getKnownStateWithStreaming(): any;
266
+ getSessionTransactions(session_id: string, from_index: number): string[] | undefined;
278
267
  /**
279
268
  * Set streaming known state
280
269
  */
281
270
  setStreamingKnownState(streaming_json: string): void;
282
271
  /**
283
- * Mark this CoValue as deleted
272
+ * Create new private transaction (for local writes)
273
+ * Returns JSON: { signature: string, transaction: Transaction }
284
274
  */
285
- markAsDeleted(): void;
275
+ makeNewPrivateTransaction(session_id: string, signer_secret: string, changes_json: string, key_id: string, key_secret: string, meta_json: string | null | undefined, made_at: number): string;
286
276
  /**
287
- * Check if this CoValue is deleted
277
+ * Get the last signature checkpoint index (-1 if no checkpoints, undefined if session not found)
288
278
  */
289
- isDeleted(): boolean;
279
+ getLastSignatureCheckpoint(session_id: string): number | undefined;
290
280
  /**
291
- * Decrypt transaction changes
281
+ * Create new trusting transaction (for local writes)
282
+ * Returns JSON: { signature: string, transaction: Transaction }
292
283
  */
293
- decryptTransaction(session_id: string, tx_index: number, key_secret: string): string | undefined;
284
+ makeNewTrustingTransaction(session_id: string, signer_secret: string, changes_json: string, meta_json: string | null | undefined, made_at: number): string;
294
285
  /**
295
- * Decrypt transaction meta
286
+ * Get the known state with streaming as a native JavaScript object
296
287
  */
297
- decryptTransactionMeta(session_id: string, tx_index: number, key_secret: string): string | undefined;
288
+ getKnownStateWithStreaming(): any;
289
+ /**
290
+ * Create a new SessionMap for a CoValue
291
+ * `max_tx_size` is the threshold for recording in-between signatures (default: 100KB)
292
+ * Create a new SessionMap for a CoValue.
293
+ * Validates the header and verifies that `co_id` matches the hash of the header.
294
+ * `max_tx_size` is the threshold for recording in-between signatures (default: 100KB)
295
+ * `skip_verify` if true, skips uniqueness and ID validation (for trusted storage shards)
296
+ */
297
+ constructor(co_id: string, header_json: string, max_tx_size?: number | null, skip_verify?: boolean | null);
298
298
  }
299
299
 
300
300
  export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
@@ -302,66 +302,66 @@ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembl
302
302
  export interface InitOutput {
303
303
  readonly memory: WebAssembly.Memory;
304
304
  readonly __wbg_sessionmap_free: (a: number, b: number) => void;
305
- readonly sessionmap_new: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
306
- readonly sessionmap_getHeader: (a: number) => [number, number];
307
305
  readonly sessionmap_addTransactions: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => [number, number];
308
- readonly sessionmap_makeNewPrivateTransaction: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number, k: number, l: number, m: number, n: number) => [number, number, number, number];
309
- readonly sessionmap_makeNewTrustingTransaction: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => [number, number, number, number];
306
+ readonly sessionmap_decryptTransaction: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
307
+ readonly sessionmap_decryptTransactionMeta: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
308
+ readonly sessionmap_getHeader: (a: number) => [number, number];
309
+ readonly sessionmap_getKnownState: (a: number) => any;
310
+ readonly sessionmap_getKnownStateWithStreaming: (a: number) => any;
311
+ readonly sessionmap_getLastSignature: (a: number, b: number, c: number) => [number, number];
312
+ readonly sessionmap_getLastSignatureCheckpoint: (a: number, b: number, c: number) => number;
310
313
  readonly sessionmap_getSessionIds: (a: number) => [number, number];
311
- readonly sessionmap_getTransactionCount: (a: number, b: number, c: number) => number;
312
- readonly sessionmap_getTransaction: (a: number, b: number, c: number, d: number) => [number, number];
313
314
  readonly sessionmap_getSessionTransactions: (a: number, b: number, c: number, d: number) => [number, number];
314
- readonly sessionmap_getLastSignature: (a: number, b: number, c: number) => [number, number];
315
315
  readonly sessionmap_getSignatureAfter: (a: number, b: number, c: number, d: number) => [number, number];
316
- readonly sessionmap_getLastSignatureCheckpoint: (a: number, b: number, c: number) => number;
317
- readonly sessionmap_getKnownState: (a: number) => any;
318
- readonly sessionmap_getKnownStateWithStreaming: (a: number) => any;
319
- readonly sessionmap_setStreamingKnownState: (a: number, b: number, c: number) => [number, number];
320
- readonly sessionmap_markAsDeleted: (a: number) => void;
316
+ readonly sessionmap_getTransaction: (a: number, b: number, c: number, d: number) => [number, number];
317
+ readonly sessionmap_getTransactionCount: (a: number, b: number, c: number) => number;
321
318
  readonly sessionmap_isDeleted: (a: number) => number;
322
- readonly sessionmap_decryptTransaction: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
323
- readonly sessionmap_decryptTransactionMeta: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
324
- readonly shortHash: (a: number, b: number) => [number, number];
325
- readonly generateNonce: (a: number, b: number) => [number, number];
319
+ readonly sessionmap_makeNewPrivateTransaction: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number, k: number, l: number, m: number, n: number) => [number, number, number, number];
320
+ readonly sessionmap_makeNewTrustingTransaction: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => [number, number, number, number];
321
+ readonly sessionmap_markAsDeleted: (a: number) => void;
322
+ readonly sessionmap_new: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
323
+ readonly sessionmap_setStreamingKnownState: (a: number, b: number, c: number) => [number, number];
324
+ readonly decrypt: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
325
+ readonly encrypt: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
326
+ readonly seal: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => [number, number, number, number];
327
+ readonly sealForGroup: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
328
+ readonly unseal: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => [number, number, number, number];
329
+ readonly unsealForGroup: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
330
+ readonly __wbg_blake3hasher_free: (a: number, b: number) => void;
326
331
  readonly blake3HashOnce: (a: number, b: number) => [number, number];
327
332
  readonly blake3HashOnceWithContext: (a: number, b: number, c: number, d: number) => [number, number];
328
- readonly __wbg_blake3hasher_free: (a: number, b: number) => void;
333
+ readonly blake3hasher_clone: (a: number) => number;
334
+ readonly blake3hasher_finalize: (a: number) => [number, number];
329
335
  readonly blake3hasher_new: () => number;
330
336
  readonly blake3hasher_update: (a: number, b: number, c: number) => void;
331
- readonly blake3hasher_finalize: (a: number) => [number, number];
332
- readonly blake3hasher_clone: (a: number) => number;
333
- readonly encrypt: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
334
- readonly decrypt: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
335
- readonly newX25519PrivateKey: () => [number, number];
336
- readonly x25519PublicKey: (a: number, b: number) => [number, number, number, number];
337
- readonly x25519DiffieHellman: (a: number, b: number, c: number, d: number) => [number, number, number, number];
338
- readonly getSealerId: (a: number, b: number) => [number, number, number, number];
339
- readonly encryptXsalsa20: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
337
+ readonly generateNonce: (a: number, b: number) => [number, number];
338
+ readonly shortHash: (a: number, b: number) => [number, number];
340
339
  readonly decryptXsalsa20: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
340
+ readonly encryptXsalsa20: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
341
+ readonly getSealerId: (a: number, b: number) => [number, number, number, number];
342
+ readonly getSignerId: (a: number, b: number) => [number, number, number, number];
343
+ readonly newX25519PrivateKey: () => [number, number];
341
344
  readonly sign: (a: number, b: number, c: number, d: number) => [number, number, number, number];
342
345
  readonly verify: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
343
- readonly getSignerId: (a: number, b: number) => [number, number, number, number];
344
- readonly seal: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => [number, number, number, number];
345
- readonly unseal: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => [number, number, number, number];
346
- readonly sealForGroup: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
347
- readonly unsealForGroup: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
348
- readonly newEd25519SigningKey: () => [number, number];
349
- readonly ed25519VerifyingKey: (a: number, b: number) => [number, number, number, number];
346
+ readonly x25519DiffieHellman: (a: number, b: number, c: number, d: number) => [number, number, number, number];
347
+ readonly x25519PublicKey: (a: number, b: number) => [number, number, number, number];
350
348
  readonly ed25519Sign: (a: number, b: number, c: number, d: number) => [number, number, number, number];
351
- readonly ed25519Verify: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
349
+ readonly ed25519SignatureFromBytes: (a: number, b: number) => [number, number, number, number];
352
350
  readonly ed25519SigningKeyFromBytes: (a: number, b: number) => [number, number, number, number];
353
351
  readonly ed25519SigningKeyToPublic: (a: number, b: number) => [number, number, number, number];
352
+ readonly ed25519Verify: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
353
+ readonly ed25519VerifyingKey: (a: number, b: number) => [number, number, number, number];
354
354
  readonly ed25519VerifyingKeyFromBytes: (a: number, b: number) => [number, number, number, number];
355
- readonly ed25519SignatureFromBytes: (a: number, b: number) => [number, number, number, number];
355
+ readonly newEd25519SigningKey: () => [number, number];
356
356
  readonly ed25519SigningKeySign: (a: number, b: number, c: number, d: number) => [number, number, number, number];
357
357
  readonly __wbindgen_malloc: (a: number, b: number) => number;
358
358
  readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
359
359
  readonly __wbindgen_exn_store: (a: number) => void;
360
360
  readonly __externref_table_alloc: () => number;
361
361
  readonly __wbindgen_export_4: WebAssembly.Table;
362
- readonly __externref_table_dealloc: (a: number) => void;
363
362
  readonly __wbindgen_free: (a: number, b: number, c: number) => void;
364
363
  readonly __externref_drop_slice: (a: number, b: number) => void;
364
+ readonly __externref_table_dealloc: (a: number) => void;
365
365
  readonly __wbindgen_start: () => void;
366
366
  }
367
367