From e6f8a99b344cfc73741cec5710ed867aba912276 Mon Sep 17 00:00:00 2001 From: Hubert Chathi Date: Wed, 29 Apr 2020 12:39:41 -0400 Subject: add missing declaration for PkDecryption#decrypt and SAS class --- javascript/index.d.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'javascript') diff --git a/javascript/index.d.ts b/javascript/index.d.ts index 44041e3..682041e 100644 --- a/javascript/index.d.ts +++ b/javascript/index.d.ts @@ -99,6 +99,7 @@ declare class PkDecryption { get_private_key(): Uint8Array; pickle(key: string): string; unpickle(key: string, pickle: string): string; + decrypt(ephemeral_key: string, mac: string, ciphertext: string): string; } declare class PkSigning { @@ -109,6 +110,16 @@ declare class PkSigning { sign(message: string): string; } +declare class SAS { + constructor(); + free(): void; + get_pubkey(): string; + set_their_key(their_key: string): void; + generate_bytes(info: string, length: number): Uint8Array; + calculate_mac(input: string, info: string): string; + calculate_mac_long_kdf(input: string, info: string): string; +} + export function init(): Promise; export function get_library_version(): [number, number, number]; -- cgit v1.2.3