UNPKG

@beraji/wallet-sdk

Version:

Beraji: Distributed Secret Sharing.

23 lines (22 loc) 859 B
export declare const xor: (a: Uint8Array, b: Uint8Array) => Uint8Array; export declare const parity: (a: Uint8Array) => number; export declare class ElGamal { static publicKeyLength: number; static privateKeyLength: number; static plainTextLength: number; static cipherTextLength: number; encrypt: (msg: Uint8Array, pubkey: Uint8Array) => Uint8Array; decrypt: (cipher: Uint8Array, privkey: Uint8Array) => Uint8Array; } export declare class ExtendedElGamal { static publicKeyLength: number; static privateKeyLength: number; static blockLength: number; static plainTextLength: number; static cipherTextLength: number; constructor(); private _enc; private _dec; encrypt: (m: Uint8Array, pubkey: Uint8Array) => Uint8Array<ArrayBuffer>; decrypt: (c: Uint8Array, privkey: Uint8Array) => Uint8Array; }