type NodeCryptoCreateCipher = typeof import('crypto').createCipheriv; type NodeCryptoCreateDecipher = typeof import('crypto').createDecipheriv; export type CipherAlgorithm = 'aes-256-cbc' | 'aes-128-cbc'; export interface AesCipher { encrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; decrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; } export declare class NodeCryptoAesCipher implements AesCipher { createCipher: NodeCryptoCreateCipher; createDecipher: NodeCryptoCreateDecipher; constructor(createCipher: NodeCryptoCreateCipher, createDecipher: NodeCryptoCreateDecipher); encrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; decrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; } export declare class WebCryptoAesCipher implements AesCipher { subtleCrypto: SubtleCrypto; constructor(subtleCrypto: SubtleCrypto); encrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; decrypt(algorithm: CipherAlgorithm, key: Uint8Array, iv: Uint8Array, data: Uint8Array): Promise; } export declare function createCipher(): Promise; export {};