//#region ../encryption/src/errors.d.ts /** * Base class for every error thrown by this package. * * Consumers can catch `EncryptionError` to handle any crypto failure, or the * narrower subclasses below when the distinction matters. */ declare class EncryptionError extends Error { constructor(message: string); } /** * Thrown when no encryption key was supplied, per call or in configurations. */ declare class MissingEncryptionKeyError extends EncryptionError { constructor(message?: string); } /** * Thrown when the runtime does not expose a usable WebCrypto implementation. * * There is deliberately no fallback: silently downgrading to a non-CSPRNG or a * hand-rolled cipher would defeat the point of the AEAD migration. */ declare class UnsupportedRuntimeError extends EncryptionError { constructor(message: string); } /** * Thrown when a ciphertext cannot be decrypted. * * The message intentionally does NOT distinguish "wrong key" from "tampered * ciphertext" for the AES-GCM path — the two are indistinguishable to the * cipher itself, and keeping them indistinguishable to the caller avoids * handing an attacker a decryption oracle. */ declare class DecryptionError extends EncryptionError { constructor(message: string); } //#endregion export { DecryptionError, EncryptionError, MissingEncryptionKeyError, UnsupportedRuntimeError }; //# sourceMappingURL=errors.d.mts.map