node-ciphers
Version:
Lightweight AES and DES encryption library for Node.js, featuring flexible encoding, multiple cipher modes, and TypeScript support.
11 lines • 953 B
TypeScript
import type { BinaryLike } from 'node:crypto';
import type { TransformOptions } from 'node:stream';
import type { BaseEncryptResult, DesCipherEncodingOptions, Result } from '../../types';
import { BaseDesCipher } from './';
export declare abstract class BaseDesEncryptAndDecrypt extends BaseDesCipher {
decrypt(encryptedData: BinaryLike, iv: BinaryLike, encodingOptions?: DesCipherEncodingOptions.Decrypt, decipherOptions?: TransformOptions): Result<string>;
decryptToJson<T = any>(encryptedData: BinaryLike, iv: BinaryLike, encodingOptions?: DesCipherEncodingOptions.Decrypt, decipherOptions?: TransformOptions): Result<T>;
encrypt(data: BinaryLike, encodingOptions?: DesCipherEncodingOptions.Encrypt, cipherOptions?: TransformOptions): BaseEncryptResult;
encryptJson(data: any, encodingOptions?: DesCipherEncodingOptions.Encrypt, cipherOptions?: TransformOptions): BaseEncryptResult;
}
//# sourceMappingURL=encrypt-and-decrypt.d.ts.map