@inngest/middleware-encryption
Version:
E2E encryption middleware for Inngest.
20 lines (19 loc) • 747 B
TypeScript
import { type EncryptionService } from "../middleware";
/**
* The AES encryption service used by the encryption middleware.
*
* This service uses AES encryption to encrypt and decrypt data. It supports
* multiple keys, so that you can rotate keys without breaking existing
* encrypted data.
*
* It was the method used before the default encryption service using LibSodium
* was added, and is still used internally for decrypting data to ensure
* compatibility with older versions.
*/
export declare class AESEncryptionService implements EncryptionService {
private readonly keys;
identifier: string;
constructor(key: string | string[] | undefined);
encrypt(value: unknown): string;
decrypt(value: string): unknown;
}