@keyhive/keyhive 0.1.0-alpha.3 → 0.1.0-alpha.5
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 +1 -1
- package/pkg/keyhive_wasm.d.ts +57 -37
- package/pkg/keyhive_wasm.js +1 -1
- package/pkg/keyhive_wasm_bg.js +255 -127
- package/pkg/keyhive_wasm_bg.wasm +0 -0
- package/pkg/keyhive_wasm_bg.wasm.d.ts +144 -135
- package/pkg-node/keyhive_wasm.d.ts +57 -37
- package/pkg-node/keyhive_wasm.js +259 -128
- package/pkg-node/keyhive_wasm_bg.wasm +0 -0
- package/pkg-node/keyhive_wasm_bg.wasm.d.ts +144 -135
- package/pkg-slim/keyhive_wasm.d.ts +201 -172
- package/pkg-slim/keyhive_wasm.js +255 -127
- package/pkg-slim/keyhive_wasm_bg.wasm +0 -0
- package/pkg-slim/keyhive_wasm_bg.wasm.base64.js +1 -1
- package/pkg-slim/keyhive_wasm_bg.wasm.d.ts +144 -135
|
@@ -9,26 +9,6 @@ export class Access {
|
|
|
9
9
|
static tryFromString(s: string): Access | undefined;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
/**
|
|
13
|
-
* The result of adding a member: the membership delegation, plus any new leaf
|
|
14
|
-
* secrets produced by auto-rekeying a non-forward-secret document on add.
|
|
15
|
-
*/
|
|
16
|
-
export class AddMemberUpdate {
|
|
17
|
-
private constructor();
|
|
18
|
-
free(): void;
|
|
19
|
-
[Symbol.dispose](): void;
|
|
20
|
-
readonly delegation: SignedDelegation;
|
|
21
|
-
/**
|
|
22
|
-
* New leaf secret keypairs from auto-rekeying a non-forward-secret document
|
|
23
|
-
* when this reader was added, serialized as a
|
|
24
|
-
* `BTreeMap<ShareKey, ShareSecretKey>` (the format `importPrekeySecrets`
|
|
25
|
-
* accepts). A sibling instance of this identity (e.g. a tab and its
|
|
26
|
-
* SharedWorker) installs them to derive the rotated key. `undefined` when
|
|
27
|
-
* no rotation occurred (a forward-secret document).
|
|
28
|
-
*/
|
|
29
|
-
readonly leafSecrets: Uint8Array | undefined;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
12
|
export class Agent {
|
|
33
13
|
private constructor();
|
|
34
14
|
free(): void;
|
|
@@ -135,6 +115,21 @@ export class ContactCard {
|
|
|
135
115
|
readonly shareKey: ShareKey;
|
|
136
116
|
}
|
|
137
117
|
|
|
118
|
+
/**
|
|
119
|
+
* Plaintext plus the application secret key that decrypted it.
|
|
120
|
+
*/
|
|
121
|
+
export class DecryptedKeyed {
|
|
122
|
+
private constructor();
|
|
123
|
+
free(): void;
|
|
124
|
+
[Symbol.dispose](): void;
|
|
125
|
+
/**
|
|
126
|
+
* The 32-byte application secret key used to decrypt this content.
|
|
127
|
+
* Treat as secret: do not log or persist unencrypted.
|
|
128
|
+
*/
|
|
129
|
+
readonly applicationSecret: Uint8Array;
|
|
130
|
+
readonly plaintext: Uint8Array;
|
|
131
|
+
}
|
|
132
|
+
|
|
138
133
|
export class Delegation {
|
|
139
134
|
private constructor();
|
|
140
135
|
free(): void;
|
|
@@ -183,6 +178,11 @@ export class Encrypted {
|
|
|
183
178
|
private constructor();
|
|
184
179
|
free(): void;
|
|
185
180
|
[Symbol.dispose](): void;
|
|
181
|
+
/**
|
|
182
|
+
* Decrypt this content with an explicit 32-byte application secret key,
|
|
183
|
+
* bypassing CGKA.
|
|
184
|
+
*/
|
|
185
|
+
decryptWithKey(key: Uint8Array): Uint8Array;
|
|
186
186
|
static fromBytes(bytes: Uint8Array): Encrypted;
|
|
187
187
|
serialize(): Uint8Array;
|
|
188
188
|
toBytes(): Uint8Array;
|
|
@@ -201,6 +201,21 @@ export class EncryptedContentWithUpdate {
|
|
|
201
201
|
update_op(): SignedCgkaOperation | undefined;
|
|
202
202
|
}
|
|
203
203
|
|
|
204
|
+
/**
|
|
205
|
+
* Encrypted content plus the application secret key it was encrypted under.
|
|
206
|
+
*/
|
|
207
|
+
export class EncryptedKeyed {
|
|
208
|
+
private constructor();
|
|
209
|
+
free(): void;
|
|
210
|
+
[Symbol.dispose](): void;
|
|
211
|
+
encrypted_content(): Encrypted;
|
|
212
|
+
update_op(): SignedCgkaOperation | undefined;
|
|
213
|
+
/**
|
|
214
|
+
* The 32-byte application secret key used to encrypt this content.
|
|
215
|
+
*/
|
|
216
|
+
readonly applicationSecret: Uint8Array;
|
|
217
|
+
}
|
|
218
|
+
|
|
204
219
|
export class Event {
|
|
205
220
|
private constructor();
|
|
206
221
|
free(): void;
|
|
@@ -293,7 +308,7 @@ export class Keyhive {
|
|
|
293
308
|
free(): void;
|
|
294
309
|
[Symbol.dispose](): void;
|
|
295
310
|
accessForDoc(id: Identifier, doc_id: DocumentId): Promise<Access | undefined>;
|
|
296
|
-
addMember(to_add: Agent, membered: Membered, access: Access, other_relevant_docs: Document[]): Promise<
|
|
311
|
+
addMember(to_add: Agent, membered: Membered, access: Access, other_relevant_docs: Document[]): Promise<SignedDelegation>;
|
|
297
312
|
/**
|
|
298
313
|
* Returns all agent events with deduplicated storage and two-tier indirection
|
|
299
314
|
* for membership, prekey, and CGKA ops.
|
|
@@ -314,14 +329,9 @@ export class Keyhive {
|
|
|
314
329
|
/**
|
|
315
330
|
* Force a PCS key rotation and return the new leaf secret, serialized as a
|
|
316
331
|
* one-entry `BTreeMap<ShareKey, ShareSecretKey>` (the exact format
|
|
317
|
-
* `importPrekeySecrets` accepts).
|
|
318
|
-
* install it to derive the rotated key without re-importing the whole bundle.
|
|
332
|
+
* `importPrekeySecrets` accepts).
|
|
319
333
|
*/
|
|
320
334
|
forcePcsUpdate(doc: Document): Promise<Uint8Array>;
|
|
321
|
-
/**
|
|
322
|
-
* Generate a document. Whether it provides forward secrecy is determined by
|
|
323
|
-
* this peer's forward-secrecy policy (chosen at `Keyhive.init`).
|
|
324
|
-
*/
|
|
325
335
|
generateDocument(coparents: Peer[], initial_content_ref_head: ChangeId, more_initial_content_refs: ChangeId[]): Promise<Document>;
|
|
326
336
|
generateGroup(js_coparents: Peer[]): Promise<Group>;
|
|
327
337
|
getAgent(id: Identifier): Promise<Agent | undefined>;
|
|
@@ -332,16 +342,7 @@ export class Keyhive {
|
|
|
332
342
|
importPrekeySecrets(bytes: Uint8Array): Promise<void>;
|
|
333
343
|
ingestArchive(archive: Archive): Promise<void>;
|
|
334
344
|
ingestEventsBytes(events_bytes_array: Array<any>): Promise<Array<any>>;
|
|
335
|
-
|
|
336
|
-
* Initialize a peer.
|
|
337
|
-
*
|
|
338
|
-
* `forward_secrecy` is this peer's policy for all documents it creates or
|
|
339
|
-
* receives. When `false`, documents carry the CGKA predecessor key chain
|
|
340
|
-
* (a member added later reads the whole prior history) and adding a reader
|
|
341
|
-
* auto-rekeys (see `addMember`'s `leafSecrets`). When `true`, a member
|
|
342
|
-
* added later cannot read content from before they joined.
|
|
343
|
-
*/
|
|
344
|
-
static init(signer: Signer, ciphertext_store: CiphertextStore, event_handler: Function, forward_secrecy: boolean): Promise<Keyhive>;
|
|
345
|
+
static init(signer: Signer, ciphertext_store: CiphertextStore, event_handler: Function): Promise<Keyhive>;
|
|
345
346
|
intoArchive(): Promise<Archive>;
|
|
346
347
|
membershipOpsForAgent(agent: Agent): Promise<Map<any, any>>;
|
|
347
348
|
pendingEventHashes(): Promise<Set<any>>;
|
|
@@ -353,8 +354,17 @@ export class Keyhive {
|
|
|
353
354
|
stats(): Promise<Stats>;
|
|
354
355
|
toArchive(): Promise<Archive>;
|
|
355
356
|
tryDecrypt(doc: Document, encrypted: Encrypted): Promise<Uint8Array>;
|
|
357
|
+
/**
|
|
358
|
+
* Decrypt content and also return the 32-byte application secret key used.
|
|
359
|
+
*/
|
|
360
|
+
tryDecryptKeyed(doc: Document, encrypted: Encrypted): Promise<DecryptedKeyed>;
|
|
356
361
|
tryEncrypt(doc: Document, content_ref: ChangeId, js_pred_refs: ChangeId[], content: Uint8Array): Promise<EncryptedContentWithUpdate>;
|
|
357
362
|
tryEncryptArchive(doc: Document, content_ref: ChangeId, pred_refs: ChangeId[], content: Uint8Array): Promise<EncryptedContentWithUpdate>;
|
|
363
|
+
/**
|
|
364
|
+
* Encrypt content and also return the application secret key it was
|
|
365
|
+
* encrypted under.
|
|
366
|
+
*/
|
|
367
|
+
tryEncryptKeyed(doc: Document, content_ref: ChangeId, js_pred_refs: ChangeId[], content: Uint8Array): Promise<EncryptedKeyed>;
|
|
358
368
|
tryPcsKeyHash(doc: Document): Promise<Uint8Array | undefined>;
|
|
359
369
|
trySign(data: Uint8Array): Promise<Signed>;
|
|
360
370
|
readonly id: IndividualId;
|
|
@@ -515,168 +525,64 @@ export class Summary {
|
|
|
515
525
|
*/
|
|
516
526
|
export function setPanicHook(): void;
|
|
517
527
|
|
|
528
|
+
/**
|
|
529
|
+
* Inverse of [`symmetric_encrypt`]. Reads `nonce(24) || ciphertext`.
|
|
530
|
+
*/
|
|
531
|
+
export function symmetricDecrypt(key: Uint8Array, blob: Uint8Array): Uint8Array;
|
|
532
|
+
|
|
533
|
+
/**
|
|
534
|
+
* Encrypt `plaintext` under a 32-byte `key`, returning `nonce(24) || ciphertext`.
|
|
535
|
+
*/
|
|
536
|
+
export function symmetricEncrypt(key: Uint8Array, plaintext: Uint8Array, associated_data: Uint8Array): Uint8Array;
|
|
537
|
+
|
|
518
538
|
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
|
519
539
|
|
|
520
540
|
export interface InitOutput {
|
|
521
541
|
readonly memory: WebAssembly.Memory;
|
|
522
|
-
readonly __wbg_allagentevents_free: (a: number, b: number) => void;
|
|
523
|
-
readonly __wbg_ciphertextstore_free: (a: number, b: number) => void;
|
|
524
542
|
readonly __wbg_invocation_free: (a: number, b: number) => void;
|
|
525
543
|
readonly __wbg_signedinvocation_free: (a: number, b: number) => void;
|
|
526
|
-
readonly
|
|
527
|
-
readonly allagentevents_agentMembershipSources: (a: number) => any;
|
|
528
|
-
readonly allagentevents_agentPrekeySources: (a: number) => any;
|
|
529
|
-
readonly allagentevents_cgkaSources: (a: number) => any;
|
|
530
|
-
readonly allagentevents_events: (a: number) => any;
|
|
531
|
-
readonly allagentevents_membershipSources: (a: number) => any;
|
|
532
|
-
readonly allagentevents_prekeySources: (a: number) => any;
|
|
533
|
-
readonly ciphertextstore_newFromWebStorage: (a: any) => number;
|
|
534
|
-
readonly ciphertextstore_newInMemory: () => number;
|
|
535
|
-
readonly __wbg_archive_free: (a: number, b: number) => void;
|
|
544
|
+
readonly setPanicHook: () => void;
|
|
536
545
|
readonly __wbg_signed_free: (a: number, b: number) => void;
|
|
537
|
-
readonly
|
|
538
|
-
readonly archive_toBytes: (a: number) => [number, number, number, number];
|
|
539
|
-
readonly archive_tryToKeyhive: (a: number, b: number, c: number, d: any) => any;
|
|
540
|
-
readonly archive_try_from_bytes: (a: number, b: number) => [number, number, number];
|
|
546
|
+
readonly __wbg_signedcgkaoperation_free: (a: number, b: number) => void;
|
|
541
547
|
readonly signed_fromBytes: (a: number, b: number) => [number, number, number];
|
|
542
548
|
readonly signed_payload: (a: number) => [number, number];
|
|
543
549
|
readonly signed_signature: (a: number) => [number, number];
|
|
544
550
|
readonly signed_toBytes: (a: number) => [number, number, number, number];
|
|
545
551
|
readonly signed_verify: (a: number) => number;
|
|
546
552
|
readonly signed_verifyingKey: (a: number) => [number, number];
|
|
547
|
-
readonly stats_activePrekeyCount: (a: number) => bigint;
|
|
548
|
-
readonly stats_cgkaOperations: (a: number) => bigint;
|
|
549
|
-
readonly stats_delegations: (a: number) => bigint;
|
|
550
|
-
readonly stats_docs: (a: number) => bigint;
|
|
551
|
-
readonly stats_groups: (a: number) => bigint;
|
|
552
|
-
readonly stats_individuals: (a: number) => bigint;
|
|
553
|
-
readonly stats_pendingCgkaOperation: (a: number) => bigint;
|
|
554
|
-
readonly stats_pendingCgkaOperationByActive: (a: number) => bigint;
|
|
555
|
-
readonly stats_pendingDelegated: (a: number) => bigint;
|
|
556
|
-
readonly stats_pendingDelegatedByActive: (a: number) => bigint;
|
|
557
|
-
readonly stats_pendingPrekeyRotated: (a: number) => bigint;
|
|
558
|
-
readonly stats_pendingPrekeyRotatedByActive: (a: number) => bigint;
|
|
559
|
-
readonly stats_pendingPrekeysExpanded: (a: number) => bigint;
|
|
560
|
-
readonly stats_pendingPrekeysExpandedByActive: (a: number) => bigint;
|
|
561
|
-
readonly stats_pendingRevoked: (a: number) => bigint;
|
|
562
|
-
readonly stats_pendingRevokedByActive: (a: number) => bigint;
|
|
563
|
-
readonly stats_prekeyRotations: (a: number) => bigint;
|
|
564
|
-
readonly stats_prekeysExpanded: (a: number) => bigint;
|
|
565
|
-
readonly stats_revocations: (a: number) => bigint;
|
|
566
|
-
readonly stats_totalOps: (a: number) => bigint;
|
|
567
|
-
readonly stats_totalPendingOps: (a: number) => bigint;
|
|
568
|
-
readonly __wbg_agent_free: (a: number, b: number) => void;
|
|
569
|
-
readonly __wbg_document_free: (a: number, b: number) => void;
|
|
570
|
-
readonly __wbg_encryptedcontentwithupdate_free: (a: number, b: number) => void;
|
|
571
|
-
readonly __wbg_group_free: (a: number, b: number) => void;
|
|
572
|
-
readonly __wbg_individual_free: (a: number, b: number) => void;
|
|
573
|
-
readonly __wbg_keyhive_free: (a: number, b: number) => void;
|
|
574
|
-
readonly __wbg_peer_free: (a: number, b: number) => void;
|
|
575
|
-
readonly agent_id: (a: number) => number;
|
|
576
|
-
readonly agent_isDocument: (a: number) => number;
|
|
577
|
-
readonly agent_isGroup: (a: number) => number;
|
|
578
|
-
readonly agent_isIndividual: (a: number) => number;
|
|
579
|
-
readonly agent_keyOpHashes: (a: number) => any;
|
|
580
|
-
readonly agent_keyOps: (a: number) => any;
|
|
581
|
-
readonly agent_toString: (a: number) => [number, number];
|
|
582
|
-
readonly document___wasm_refgen_toJsDocument: (a: number) => number;
|
|
583
|
-
readonly document_doc_id: (a: number) => number;
|
|
584
|
-
readonly document_id: (a: number) => number;
|
|
585
|
-
readonly document_members: (a: number) => any;
|
|
586
|
-
readonly document_toAgent: (a: number) => number;
|
|
587
|
-
readonly document_toMembered: (a: number) => number;
|
|
588
|
-
readonly document_toPeer: (a: number) => number;
|
|
589
|
-
readonly encryptedcontentwithupdate_encrypted_content: (a: number) => number;
|
|
590
|
-
readonly encryptedcontentwithupdate_update_op: (a: number) => number;
|
|
591
|
-
readonly group___wasm_refgen_toJsGroup: (a: number) => number;
|
|
592
|
-
readonly group_members: (a: number) => any;
|
|
593
|
-
readonly group_toAgent: (a: number) => number;
|
|
594
|
-
readonly group_toMembered: (a: number) => number;
|
|
595
|
-
readonly group_toPeer: (a: number) => number;
|
|
596
|
-
readonly individual_individualId: (a: number) => number;
|
|
597
|
-
readonly individual_pickPrekey: (a: number, b: number) => any;
|
|
598
|
-
readonly individual_toAgent: (a: number) => number;
|
|
599
|
-
readonly individual_toPeer: (a: number) => number;
|
|
600
|
-
readonly keyhive_accessForDoc: (a: number, b: number, c: number) => any;
|
|
601
|
-
readonly keyhive_addMember: (a: number, b: number, c: number, d: number, e: number, f: number) => any;
|
|
602
|
-
readonly keyhive_allAgentEvents: (a: number) => any;
|
|
603
|
-
readonly keyhive_contactCard: (a: number) => any;
|
|
604
|
-
readonly keyhive_docMemberCapabilities: (a: number, b: number) => any;
|
|
605
|
-
readonly keyhive_eventHashesForAgent: (a: number, b: number) => any;
|
|
606
|
-
readonly keyhive_eventsForAgent: (a: number, b: number) => any;
|
|
607
|
-
readonly keyhive_expandPrekeys: (a: number) => any;
|
|
608
|
-
readonly keyhive_exportPrekeySecrets: (a: number) => any;
|
|
609
|
-
readonly keyhive_forcePcsUpdate: (a: number, b: number) => any;
|
|
610
|
-
readonly keyhive_generateDocument: (a: number, b: number, c: number, d: number, e: number, f: number) => any;
|
|
611
|
-
readonly keyhive_generateGroup: (a: number, b: number, c: number) => any;
|
|
612
|
-
readonly keyhive_getAgent: (a: number, b: number) => any;
|
|
613
|
-
readonly keyhive_getDocument: (a: number, b: number) => any;
|
|
614
|
-
readonly keyhive_getExistingContactCard: (a: number) => any;
|
|
615
|
-
readonly keyhive_getGroup: (a: number, b: number) => any;
|
|
616
|
-
readonly keyhive_getIndividual: (a: number, b: number) => any;
|
|
617
|
-
readonly keyhive_id: (a: number) => number;
|
|
618
|
-
readonly keyhive_idString: (a: number) => [number, number];
|
|
619
|
-
readonly keyhive_importPrekeySecrets: (a: number, b: number, c: number) => any;
|
|
620
|
-
readonly keyhive_individual: (a: number) => any;
|
|
621
|
-
readonly keyhive_ingestArchive: (a: number, b: number) => any;
|
|
622
|
-
readonly keyhive_ingestEventsBytes: (a: number, b: any) => any;
|
|
623
|
-
readonly keyhive_init: (a: number, b: number, c: any, d: number) => any;
|
|
624
|
-
readonly keyhive_intoArchive: (a: number) => any;
|
|
625
|
-
readonly keyhive_membershipOpsForAgent: (a: number, b: number) => any;
|
|
626
|
-
readonly keyhive_pendingEventHashes: (a: number) => any;
|
|
627
|
-
readonly keyhive_reachableDocs: (a: number) => any;
|
|
628
|
-
readonly keyhive_receiveContactCard: (a: number, b: number) => any;
|
|
629
|
-
readonly keyhive_revokeMember: (a: number, b: number, c: number, d: number) => any;
|
|
630
|
-
readonly keyhive_revokedMembersForDoc: (a: number, b: number) => any;
|
|
631
|
-
readonly keyhive_rotatePrekey: (a: number, b: number) => any;
|
|
632
|
-
readonly keyhive_stats: (a: number) => any;
|
|
633
|
-
readonly keyhive_toArchive: (a: number) => any;
|
|
634
|
-
readonly keyhive_tryDecrypt: (a: number, b: number, c: number) => any;
|
|
635
|
-
readonly keyhive_tryEncrypt: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => any;
|
|
636
|
-
readonly keyhive_tryEncryptArchive: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => any;
|
|
637
|
-
readonly keyhive_tryPcsKeyHash: (a: number, b: number) => any;
|
|
638
|
-
readonly keyhive_trySign: (a: number, b: number, c: number) => any;
|
|
639
|
-
readonly keyhive_whoami: (a: number) => number;
|
|
640
|
-
readonly peer___wasm_refgen_toJsPeer: (a: number) => number;
|
|
641
|
-
readonly peer_isDocument: (a: number) => number;
|
|
642
|
-
readonly peer_isGroup: (a: number) => number;
|
|
643
|
-
readonly peer_isIndividual: (a: number) => number;
|
|
644
|
-
readonly peer_toString: (a: number) => [number, number];
|
|
645
|
-
readonly setPanicHook: () => void;
|
|
646
|
-
readonly group_groupId: (a: number) => number;
|
|
647
|
-
readonly group_id: (a: number) => number;
|
|
648
|
-
readonly individual_id: (a: number) => number;
|
|
649
|
-
readonly peer_id: (a: number) => number;
|
|
650
|
-
readonly __wbg_signedcgkaoperation_free: (a: number, b: number) => void;
|
|
651
553
|
readonly signedcgkaoperation_delegation: (a: number) => number;
|
|
652
554
|
readonly signedcgkaoperation_signature: (a: number) => [number, number];
|
|
653
555
|
readonly signedcgkaoperation_verify: (a: number) => number;
|
|
654
556
|
readonly signedcgkaoperation_verifyingKey: (a: number) => [number, number];
|
|
655
|
-
readonly
|
|
557
|
+
readonly __wbg_allagentevents_free: (a: number, b: number) => void;
|
|
656
558
|
readonly __wbg_changeid_free: (a: number, b: number) => void;
|
|
559
|
+
readonly __wbg_ciphertextstore_free: (a: number, b: number) => void;
|
|
560
|
+
readonly __wbg_decryptedkeyed_free: (a: number, b: number) => void;
|
|
657
561
|
readonly __wbg_doccontentrefs_free: (a: number, b: number) => void;
|
|
658
|
-
readonly __wbg_identifier_free: (a: number, b: number) => void;
|
|
659
562
|
readonly __wbg_revocation_free: (a: number, b: number) => void;
|
|
660
563
|
readonly __wbg_sharekey_free: (a: number, b: number) => void;
|
|
661
|
-
readonly
|
|
564
|
+
readonly allagentevents_agentCgkaSources: (a: number) => any;
|
|
565
|
+
readonly allagentevents_agentMembershipSources: (a: number) => any;
|
|
566
|
+
readonly allagentevents_agentPrekeySources: (a: number) => any;
|
|
567
|
+
readonly allagentevents_cgkaSources: (a: number) => any;
|
|
568
|
+
readonly allagentevents_events: (a: number) => any;
|
|
569
|
+
readonly allagentevents_membershipSources: (a: number) => any;
|
|
570
|
+
readonly allagentevents_prekeySources: (a: number) => any;
|
|
662
571
|
readonly changeid___wasm_refgen_toJsChangeId: (a: number) => number;
|
|
663
572
|
readonly changeid_bytes: (a: number) => [number, number];
|
|
664
573
|
readonly changeid_new: (a: number, b: number) => number;
|
|
574
|
+
readonly ciphertextstore_newFromWebStorage: (a: any) => number;
|
|
575
|
+
readonly ciphertextstore_newInMemory: () => number;
|
|
576
|
+
readonly decryptedkeyed_applicationSecret: (a: number) => [number, number];
|
|
577
|
+
readonly decryptedkeyed_plaintext: (a: number) => [number, number];
|
|
665
578
|
readonly doccontentrefs_addChangeId: (a: number, b: number) => any;
|
|
666
579
|
readonly doccontentrefs_change_hashes: (a: number) => any;
|
|
667
580
|
readonly doccontentrefs_docId: (a: number) => number;
|
|
668
581
|
readonly doccontentrefs_new: (a: number, b: number, c: number) => [number, number, number];
|
|
669
|
-
readonly identifier_new: (a: number, b: number) => [number, number, number];
|
|
670
|
-
readonly identifier_publicId: () => number;
|
|
671
|
-
readonly identifier_toBytes: (a: number) => [number, number];
|
|
672
582
|
readonly revocation_after: (a: number) => number;
|
|
673
583
|
readonly revocation_proof: (a: number) => number;
|
|
674
584
|
readonly revocation_revoked: (a: number) => number;
|
|
675
585
|
readonly revocation_subject_id: (a: number) => number;
|
|
676
|
-
readonly signedrevocation_delegation: (a: number) => number;
|
|
677
|
-
readonly signedrevocation_signature: (a: number) => [number, number];
|
|
678
|
-
readonly signedrevocation_verify: (a: number) => number;
|
|
679
|
-
readonly signedrevocation_verifyingKey: (a: number) => [number, number];
|
|
680
586
|
readonly __wbg_access_free: (a: number, b: number) => void;
|
|
681
587
|
readonly __wbg_cannotparseed25519signingkey_free: (a: number, b: number) => void;
|
|
682
588
|
readonly __wbg_cgkaoperation_free: (a: number, b: number) => void;
|
|
@@ -703,6 +609,7 @@ export interface InitOutput {
|
|
|
703
609
|
readonly documentid_toString: (a: number) => [number, number];
|
|
704
610
|
readonly encrypted_ciphertext: (a: number) => [number, number];
|
|
705
611
|
readonly encrypted_content_ref: (a: number) => [number, number];
|
|
612
|
+
readonly encrypted_decryptWithKey: (a: number, b: number, c: number) => [number, number, number, number];
|
|
706
613
|
readonly encrypted_fromBytes: (a: number, b: number) => [number, number, number];
|
|
707
614
|
readonly encrypted_nonce: (a: number) => [number, number];
|
|
708
615
|
readonly encrypted_pcs_key_hash: (a: number) => [number, number];
|
|
@@ -725,8 +632,10 @@ export interface InitOutput {
|
|
|
725
632
|
readonly signer_variant: (a: number) => [number, number];
|
|
726
633
|
readonly signer_verifyingKey: (a: number) => [number, number];
|
|
727
634
|
readonly signer_webCryptoSigner: (a: any) => any;
|
|
635
|
+
readonly symmetricDecrypt: (a: number, b: number, c: number, d: number) => [number, number, number, number];
|
|
636
|
+
readonly symmetricEncrypt: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number, number];
|
|
728
637
|
readonly encrypted_toBytes: (a: number) => [number, number];
|
|
729
|
-
readonly
|
|
638
|
+
readonly __wbg_archive_free: (a: number, b: number) => void;
|
|
730
639
|
readonly __wbg_capability_free: (a: number, b: number) => void;
|
|
731
640
|
readonly __wbg_delegation_free: (a: number, b: number) => void;
|
|
732
641
|
readonly __wbg_history_free: (a: number, b: number) => void;
|
|
@@ -734,9 +643,11 @@ export interface InitOutput {
|
|
|
734
643
|
readonly __wbg_membered_free: (a: number, b: number) => void;
|
|
735
644
|
readonly __wbg_membership_free: (a: number, b: number) => void;
|
|
736
645
|
readonly __wbg_signeddelegation_free: (a: number, b: number) => void;
|
|
646
|
+
readonly __wbg_signedrevocation_free: (a: number, b: number) => void;
|
|
737
647
|
readonly __wbg_summary_free: (a: number, b: number) => void;
|
|
738
|
-
readonly
|
|
739
|
-
readonly
|
|
648
|
+
readonly archive_toBytes: (a: number) => [number, number, number, number];
|
|
649
|
+
readonly archive_tryToKeyhive: (a: number, b: number, c: number, d: any) => any;
|
|
650
|
+
readonly archive_try_from_bytes: (a: number, b: number) => [number, number, number];
|
|
740
651
|
readonly capability_can: (a: number) => number;
|
|
741
652
|
readonly capability_proof: (a: number) => number;
|
|
742
653
|
readonly capability_who: (a: number) => number;
|
|
@@ -755,10 +666,128 @@ export interface InitOutput {
|
|
|
755
666
|
readonly signeddelegation_subjectId: (a: number) => number;
|
|
756
667
|
readonly signeddelegation_verify: (a: number) => number;
|
|
757
668
|
readonly signeddelegation_verifyingKey: (a: number) => [number, number];
|
|
669
|
+
readonly signedrevocation_delegation: (a: number) => number;
|
|
670
|
+
readonly signedrevocation_signature: (a: number) => [number, number];
|
|
671
|
+
readonly signedrevocation_verify: (a: number) => number;
|
|
672
|
+
readonly signedrevocation_verifyingKey: (a: number) => [number, number];
|
|
758
673
|
readonly summary_access: (a: number) => number;
|
|
759
674
|
readonly summary_doc: (a: number) => number;
|
|
760
|
-
readonly
|
|
761
|
-
readonly
|
|
675
|
+
readonly __wbg_cannotparseidentifier_free: (a: number, b: number) => void;
|
|
676
|
+
readonly __wbg_identifier_free: (a: number, b: number) => void;
|
|
677
|
+
readonly identifier_new: (a: number, b: number) => [number, number, number];
|
|
678
|
+
readonly identifier_publicId: () => number;
|
|
679
|
+
readonly identifier_toBytes: (a: number) => [number, number];
|
|
680
|
+
readonly __wbg_agent_free: (a: number, b: number) => void;
|
|
681
|
+
readonly __wbg_document_free: (a: number, b: number) => void;
|
|
682
|
+
readonly __wbg_encryptedcontentwithupdate_free: (a: number, b: number) => void;
|
|
683
|
+
readonly __wbg_encryptedkeyed_free: (a: number, b: number) => void;
|
|
684
|
+
readonly __wbg_group_free: (a: number, b: number) => void;
|
|
685
|
+
readonly __wbg_individual_free: (a: number, b: number) => void;
|
|
686
|
+
readonly __wbg_keyhive_free: (a: number, b: number) => void;
|
|
687
|
+
readonly __wbg_peer_free: (a: number, b: number) => void;
|
|
688
|
+
readonly __wbg_stats_free: (a: number, b: number) => void;
|
|
689
|
+
readonly agent_id: (a: number) => number;
|
|
690
|
+
readonly agent_isDocument: (a: number) => number;
|
|
691
|
+
readonly agent_isGroup: (a: number) => number;
|
|
692
|
+
readonly agent_isIndividual: (a: number) => number;
|
|
693
|
+
readonly agent_keyOpHashes: (a: number) => any;
|
|
694
|
+
readonly agent_keyOps: (a: number) => any;
|
|
695
|
+
readonly agent_toString: (a: number) => [number, number];
|
|
696
|
+
readonly document___wasm_refgen_toJsDocument: (a: number) => number;
|
|
697
|
+
readonly document_doc_id: (a: number) => number;
|
|
698
|
+
readonly document_id: (a: number) => number;
|
|
699
|
+
readonly document_members: (a: number) => any;
|
|
700
|
+
readonly document_toAgent: (a: number) => number;
|
|
701
|
+
readonly document_toMembered: (a: number) => number;
|
|
702
|
+
readonly document_toPeer: (a: number) => number;
|
|
703
|
+
readonly encryptedcontentwithupdate_encrypted_content: (a: number) => number;
|
|
704
|
+
readonly encryptedcontentwithupdate_update_op: (a: number) => number;
|
|
705
|
+
readonly encryptedkeyed_applicationSecret: (a: number) => [number, number];
|
|
706
|
+
readonly encryptedkeyed_encrypted_content: (a: number) => number;
|
|
707
|
+
readonly encryptedkeyed_update_op: (a: number) => number;
|
|
708
|
+
readonly group___wasm_refgen_toJsGroup: (a: number) => number;
|
|
709
|
+
readonly group_members: (a: number) => any;
|
|
710
|
+
readonly group_toAgent: (a: number) => number;
|
|
711
|
+
readonly group_toMembered: (a: number) => number;
|
|
712
|
+
readonly group_toPeer: (a: number) => number;
|
|
713
|
+
readonly individual_individualId: (a: number) => number;
|
|
714
|
+
readonly individual_pickPrekey: (a: number, b: number) => any;
|
|
715
|
+
readonly individual_toAgent: (a: number) => number;
|
|
716
|
+
readonly individual_toPeer: (a: number) => number;
|
|
717
|
+
readonly keyhive_accessForDoc: (a: number, b: number, c: number) => any;
|
|
718
|
+
readonly keyhive_addMember: (a: number, b: number, c: number, d: number, e: number, f: number) => any;
|
|
719
|
+
readonly keyhive_allAgentEvents: (a: number) => any;
|
|
720
|
+
readonly keyhive_contactCard: (a: number) => any;
|
|
721
|
+
readonly keyhive_docMemberCapabilities: (a: number, b: number) => any;
|
|
722
|
+
readonly keyhive_eventHashesForAgent: (a: number, b: number) => any;
|
|
723
|
+
readonly keyhive_eventsForAgent: (a: number, b: number) => any;
|
|
724
|
+
readonly keyhive_expandPrekeys: (a: number) => any;
|
|
725
|
+
readonly keyhive_exportPrekeySecrets: (a: number) => any;
|
|
726
|
+
readonly keyhive_forcePcsUpdate: (a: number, b: number) => any;
|
|
727
|
+
readonly keyhive_generateDocument: (a: number, b: number, c: number, d: number, e: number, f: number) => any;
|
|
728
|
+
readonly keyhive_generateGroup: (a: number, b: number, c: number) => any;
|
|
729
|
+
readonly keyhive_getAgent: (a: number, b: number) => any;
|
|
730
|
+
readonly keyhive_getDocument: (a: number, b: number) => any;
|
|
731
|
+
readonly keyhive_getExistingContactCard: (a: number) => any;
|
|
732
|
+
readonly keyhive_getGroup: (a: number, b: number) => any;
|
|
733
|
+
readonly keyhive_getIndividual: (a: number, b: number) => any;
|
|
734
|
+
readonly keyhive_id: (a: number) => number;
|
|
735
|
+
readonly keyhive_idString: (a: number) => [number, number];
|
|
736
|
+
readonly keyhive_importPrekeySecrets: (a: number, b: number, c: number) => any;
|
|
737
|
+
readonly keyhive_individual: (a: number) => any;
|
|
738
|
+
readonly keyhive_ingestArchive: (a: number, b: number) => any;
|
|
739
|
+
readonly keyhive_ingestEventsBytes: (a: number, b: any) => any;
|
|
740
|
+
readonly keyhive_init: (a: number, b: number, c: any) => any;
|
|
741
|
+
readonly keyhive_intoArchive: (a: number) => any;
|
|
742
|
+
readonly keyhive_membershipOpsForAgent: (a: number, b: number) => any;
|
|
743
|
+
readonly keyhive_pendingEventHashes: (a: number) => any;
|
|
744
|
+
readonly keyhive_reachableDocs: (a: number) => any;
|
|
745
|
+
readonly keyhive_receiveContactCard: (a: number, b: number) => any;
|
|
746
|
+
readonly keyhive_revokeMember: (a: number, b: number, c: number, d: number) => any;
|
|
747
|
+
readonly keyhive_revokedMembersForDoc: (a: number, b: number) => any;
|
|
748
|
+
readonly keyhive_rotatePrekey: (a: number, b: number) => any;
|
|
749
|
+
readonly keyhive_stats: (a: number) => any;
|
|
750
|
+
readonly keyhive_toArchive: (a: number) => any;
|
|
751
|
+
readonly keyhive_tryDecrypt: (a: number, b: number, c: number) => any;
|
|
752
|
+
readonly keyhive_tryDecryptKeyed: (a: number, b: number, c: number) => any;
|
|
753
|
+
readonly keyhive_tryEncrypt: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => any;
|
|
754
|
+
readonly keyhive_tryEncryptArchive: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => any;
|
|
755
|
+
readonly keyhive_tryEncryptKeyed: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => any;
|
|
756
|
+
readonly keyhive_tryPcsKeyHash: (a: number, b: number) => any;
|
|
757
|
+
readonly keyhive_trySign: (a: number, b: number, c: number) => any;
|
|
758
|
+
readonly keyhive_whoami: (a: number) => number;
|
|
759
|
+
readonly peer___wasm_refgen_toJsPeer: (a: number) => number;
|
|
760
|
+
readonly peer_isDocument: (a: number) => number;
|
|
761
|
+
readonly peer_isGroup: (a: number) => number;
|
|
762
|
+
readonly peer_isIndividual: (a: number) => number;
|
|
763
|
+
readonly peer_toString: (a: number) => [number, number];
|
|
764
|
+
readonly stats_activePrekeyCount: (a: number) => bigint;
|
|
765
|
+
readonly stats_cgkaOperations: (a: number) => bigint;
|
|
766
|
+
readonly stats_delegations: (a: number) => bigint;
|
|
767
|
+
readonly stats_docs: (a: number) => bigint;
|
|
768
|
+
readonly stats_groups: (a: number) => bigint;
|
|
769
|
+
readonly stats_individuals: (a: number) => bigint;
|
|
770
|
+
readonly stats_pendingCgkaOperation: (a: number) => bigint;
|
|
771
|
+
readonly stats_pendingCgkaOperationByActive: (a: number) => bigint;
|
|
772
|
+
readonly stats_pendingDelegated: (a: number) => bigint;
|
|
773
|
+
readonly stats_pendingDelegatedByActive: (a: number) => bigint;
|
|
774
|
+
readonly stats_pendingPrekeyRotated: (a: number) => bigint;
|
|
775
|
+
readonly stats_pendingPrekeyRotatedByActive: (a: number) => bigint;
|
|
776
|
+
readonly stats_pendingPrekeysExpanded: (a: number) => bigint;
|
|
777
|
+
readonly stats_pendingPrekeysExpandedByActive: (a: number) => bigint;
|
|
778
|
+
readonly stats_pendingRevoked: (a: number) => bigint;
|
|
779
|
+
readonly stats_pendingRevokedByActive: (a: number) => bigint;
|
|
780
|
+
readonly stats_prekeyRotations: (a: number) => bigint;
|
|
781
|
+
readonly stats_prekeysExpanded: (a: number) => bigint;
|
|
782
|
+
readonly stats_revocations: (a: number) => bigint;
|
|
783
|
+
readonly stats_totalOps: (a: number) => bigint;
|
|
784
|
+
readonly stats_totalPendingOps: (a: number) => bigint;
|
|
785
|
+
readonly group_groupId: (a: number) => number;
|
|
786
|
+
readonly group_id: (a: number) => number;
|
|
787
|
+
readonly individual_id: (a: number) => number;
|
|
788
|
+
readonly peer_id: (a: number) => number;
|
|
789
|
+
readonly wasm_bindgen__convert__closures_____invoke__h9887d5ab72723f8a: (a: number, b: number, c: any) => [number, number];
|
|
790
|
+
readonly wasm_bindgen__convert__closures_____invoke__h58982df154245cbc: (a: number, b: number, c: any, d: any) => void;
|
|
762
791
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
763
792
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
764
793
|
readonly __wbindgen_exn_store: (a: number) => void;
|