@tonappchain/adnl
Version:
ADNL TypeScript implementation
18 lines (17 loc) • 721 B
TypeScript
import { ModeOfOperation } from 'aes-js';
declare class CipherBase {
protected cipher: ModeOfOperation.ModeOfOperationCTR;
constructor(key: Uint8Array, iv: Uint8Array);
final(): Uint8Array;
}
declare class Cipher extends CipherBase {
constructor(key: Uint8Array, iv: Uint8Array);
update(data: Uint8Array): Uint8Array;
}
declare class Decipher extends Cipher {
constructor(key: Uint8Array, iv: Uint8Array);
update(data: Uint8Array): Uint8Array;
}
declare const createCipheriv: (_algo: string, key: Uint8Array, iv: Uint8Array) => Cipher;
declare const createDecipheriv: (_algo: string, key: Uint8Array, iv: Uint8Array) => Decipher;
export { Cipher, Decipher, createCipheriv, createDecipheriv };