import { E as Encryption } from './encryption-Cru0w9wm.js';
import { MessageVerifier } from './src/message_verifier.js';
import { EncryptionConfig, EncryptOptions, CypherText } from './src/types/main.js';
export { BaseDriver } from './src/drivers/base_driver.js';
export { base64UrlDecode, base64UrlEncode } from './src/base64.js';
import * as _poppinss_utils_exception from '@poppinss/utils/exception';
import '@poppinss/utils';

declare class EncryptionManager<KnownEncrypters extends Record<string, EncryptionConfig>> {
    #private;
    constructor(config: {
        default?: keyof KnownEncrypters;
        list: KnownEncrypters;
    });
    /**
     * Use one of the registered encrypters to encrypt values.
     *
     * ```ts
     * manager.use() // returns default encrypter
     * manager.use('aes_256_cbc')
     * ```
     */
    use<EncrypterName extends keyof KnownEncrypters>(encrypterName?: EncrypterName): Encryption;
    getMessageVerifier(): MessageVerifier;
    encrypt(payload: any, options?: EncryptOptions): CypherText;
    encrypt(payload: any, expiresIn?: string | number, purpose?: string): CypherText;
    decrypt<T extends any>(value: string, purpose?: string): T | null;
    blindIndex(payload: any, purpose: string): string;
    blindIndexes(payload: any, purpose: string): string[];
}

/**
 * A generic class for generating SHA-256 Hmac for verifying the value
 * integrity.
 */
declare class Hmac {
    #private;
    constructor(key: Buffer);
    /**
     * Generate the hmac
     */
    generate(value: string): string;
    /**
     * Compare raw value against an existing hmac
     */
    compare(value: string, existingHmac: string): boolean;
}

declare const E_INSECURE_ENCRYPTER_KEY: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_MISSING_ENCRYPTER_KEY: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_MISSING_ENCRYPTER_KEYS: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_MISSING_ENCRYPTER_ID: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_INVALID_ENCRYPTER_ID: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_DETERMINISTIC_DRIVER_EXPIRES_IN_NOT_SUPPORTED: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;
declare const E_BLIND_INDEX_PURPOSE_REQUIRED: new (args?: any, options?: ErrorOptions) => _poppinss_utils_exception.Exception;

declare const exceptions_E_BLIND_INDEX_PURPOSE_REQUIRED: typeof E_BLIND_INDEX_PURPOSE_REQUIRED;
declare const exceptions_E_DETERMINISTIC_DRIVER_EXPIRES_IN_NOT_SUPPORTED: typeof E_DETERMINISTIC_DRIVER_EXPIRES_IN_NOT_SUPPORTED;
declare const exceptions_E_INSECURE_ENCRYPTER_KEY: typeof E_INSECURE_ENCRYPTER_KEY;
declare const exceptions_E_INVALID_ENCRYPTER_ID: typeof E_INVALID_ENCRYPTER_ID;
declare const exceptions_E_MISSING_ENCRYPTER_ID: typeof E_MISSING_ENCRYPTER_ID;
declare const exceptions_E_MISSING_ENCRYPTER_KEY: typeof E_MISSING_ENCRYPTER_KEY;
declare const exceptions_E_MISSING_ENCRYPTER_KEYS: typeof E_MISSING_ENCRYPTER_KEYS;
declare namespace exceptions {
  export { exceptions_E_BLIND_INDEX_PURPOSE_REQUIRED as E_BLIND_INDEX_PURPOSE_REQUIRED, exceptions_E_DETERMINISTIC_DRIVER_EXPIRES_IN_NOT_SUPPORTED as E_DETERMINISTIC_DRIVER_EXPIRES_IN_NOT_SUPPORTED, exceptions_E_INSECURE_ENCRYPTER_KEY as E_INSECURE_ENCRYPTER_KEY, exceptions_E_INVALID_ENCRYPTER_ID as E_INVALID_ENCRYPTER_ID, exceptions_E_MISSING_ENCRYPTER_ID as E_MISSING_ENCRYPTER_ID, exceptions_E_MISSING_ENCRYPTER_KEY as E_MISSING_ENCRYPTER_KEY, exceptions_E_MISSING_ENCRYPTER_KEYS as E_MISSING_ENCRYPTER_KEYS };
}

export { Encryption, EncryptionManager, Hmac, exceptions as errors };
