import { _Sha256 } from './secureHash-algorithm256';
import { _Sha512 } from './secureHash-algorithm512';
/**
 * Abstract base for encryption key helpers used internally by PDF encryption.
 *
 * @private
 */
export declare abstract class _EncryptionKey {
    /**
     * Cached SHA-256 instance used for hashing operations.
     *
     * @private
     */
    _sha256Obj: _Sha256;
    /**
     * Lazily-created SHA-256 instance.
     *
     * @private
     * @returns {_Sha256} The `_Sha256` instance.
     */
    readonly _sha256: _Sha256;
    /**
     * Cached SHA-512 instance used for hashing operations.
     *
     * @private
     */
    _sha512Obj: _Sha512;
    /**
     * Lazily-created SHA-512 instance.
     *
     * @private
     * @returns {_Sha512} The `_Sha512` instance.
     */
    readonly _sha512: _Sha512;
    /**
     * Check whether the provided password matches the owner password.
     *
     * @private
     * @param {Uint8Array} password - The password to check.
     * @param {Uint8Array} ownerValidationSalt - Salt used for owner validation.
     * @param {Uint8Array} userBytes - User-specific bytes used in hashing.
     * @param {Uint8Array} ownerPassword - Expected owner password hash.
     * @returns {boolean} `true` when the password is valid.
     */
    abstract _checkOwnerPassword(password: Uint8Array, ownerValidationSalt: Uint8Array, userBytes: Uint8Array, ownerPassword: Uint8Array): boolean;
    /**
     * Check whether the provided password matches the user password.
     *
     * @private
     * @param {Uint8Array} password - The password to check.
     * @param {Uint8Array} userValidationSalt - Salt used for user validation.
     * @param {Uint8Array} userPassword - Expected user password hash.
     * @returns {boolean} `true` when the password is valid.
     */
    abstract _checkUserPassword(password: Uint8Array, userValidationSalt: Uint8Array, userPassword: Uint8Array): boolean;
    /**
     * Derive the owner key from the given password and salts.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} ownerKeySalt - Salt used for owner key derivation.
     * @param {Uint8Array} userBytes - User-specific bytes used in derivation.
     * @param {Uint8Array} ownerEncryption - Encrypted owner data to decrypt.
     * @returns {Uint8Array} The derived owner key bytes.
     */
    abstract _getOwnerKey(password: Uint8Array, ownerKeySalt: Uint8Array, userBytes: Uint8Array, ownerEncryption: Uint8Array): Uint8Array;
    /**
     * Derive the user key from the given password and salts.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} userKeySalt - Salt used for user key derivation.
     * @param {Uint8Array} userEncryption - Encrypted user data to decrypt.
     * @returns {Uint8Array} The derived user key bytes.
     */
    abstract _getUserKey(password: Uint8Array, userKeySalt: Uint8Array, userEncryption: Uint8Array): Uint8Array;
}
/**
 * Basic (PDF 1.7) encryption helper implementing `_EncryptionKey`.
 *
 * @private
 */
export declare class _BasicEncryption extends _EncryptionKey {
    /**
     * Validate the owner password for PDF 1.7-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The candidate password.
     * @param {Uint8Array} ownerValidationSalt - Salt for owner validation.
     * @param {Uint8Array} userBytes - Additional user bytes used in hashing.
     * @param {Uint8Array} ownerPassword - Expected owner password hash.
     * @returns {boolean} `true` when the owner password is valid.
     */
    _checkOwnerPassword(password: Uint8Array, ownerValidationSalt: Uint8Array, userBytes: Uint8Array, ownerPassword: Uint8Array): boolean;
    /**
     * Validate the user password for PDF 1.7-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The candidate password.
     * @param {Uint8Array} userValidationSalt - Salt for user validation.
     * @param {Uint8Array} userPassword - Expected user password hash.
     * @returns {boolean} `true` when the user password is valid.
     */
    _checkUserPassword(password: Uint8Array, userValidationSalt: Uint8Array, userPassword: Uint8Array): boolean;
    /**
     * Derive the owner key for PDF 1.7-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} ownerKeySalt - Salt used for owner key derivation.
     * @param {Uint8Array} userBytes - Additional user bytes used in derivation.
     * @param {Uint8Array} ownerEncryption - Encrypted owner data to decrypt.
     * @returns {Uint8Array} The derived owner key bytes.
     */
    _getOwnerKey(password: Uint8Array, ownerKeySalt: Uint8Array, userBytes: Uint8Array, ownerEncryption: Uint8Array): Uint8Array;
    /**
     * Derive the user key for PDF 1.7-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} userKeySalt - Salt used for user key derivation.
     * @param {Uint8Array} userEncryption - Encrypted user data to decrypt.
     * @returns {Uint8Array} The derived user key bytes.
     */
    _getUserKey(password: Uint8Array, userKeySalt: Uint8Array, userEncryption: Uint8Array): Uint8Array;
}
/**
 * Advanced (PDF 2.0) encryption helper implementing `_EncryptionKey`.
 *
 * @private
 */
export declare class _AdvancedEncryption extends _EncryptionKey {
    /**
     * Validate the owner password for PDF 2.0-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The candidate password.
     * @param {Uint8Array} ownerValidationSalt - Salt for owner validation.
     * @param {Uint8Array} userBytes - Additional user bytes used in hashing.
     * @param {Uint8Array} ownerPassword - Expected owner password hash.
     * @returns {boolean} `true` when the owner password is valid.
     */
    _checkOwnerPassword(password: Uint8Array, ownerValidationSalt: Uint8Array, userBytes: Uint8Array, ownerPassword: Uint8Array): boolean;
    _checkUserPassword(password: Uint8Array, userValidationSalt: Uint8Array, userPassword: Uint8Array): boolean;
    /**
     * Derive the owner key for PDF 2.0-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} ownerKeySalt - Salt used for owner key derivation.
     * @param {Uint8Array} userBytes - Additional user bytes used in derivation.
     * @param {Uint8Array} ownerEncryption - Encrypted owner data to decrypt.
     * @returns {Uint8Array} The derived owner key bytes.
     */
    _getOwnerKey(password: Uint8Array, ownerKeySalt: Uint8Array, userBytes: Uint8Array, ownerEncryption: Uint8Array): Uint8Array;
    /**
     * Derive the user key for PDF 2.0-style encryption.
     *
     * @private
     * @param {Uint8Array} password - The password to derive from.
     * @param {Uint8Array} userKeySalt - Salt used for user key derivation.
     * @param {Uint8Array} userEncryption - Encrypted user data to decrypt.
     * @returns {Uint8Array} The derived user key bytes.
     */
    _getUserKey(password: Uint8Array, userKeySalt: Uint8Array, userEncryption: Uint8Array): Uint8Array;
    /**
     * Internal iterative hash routine used by PDF 2.0 encryption key derivation.
     *
     * @private
     * @param {Uint8Array} password - The password bytes.
     * @param {Uint8Array} input - Input data for the hash routine.
     * @param {Uint8Array} userBytes - User-specific bytes influencing the result.
     * @returns {Uint8Array} A 32-byte hash used as an intermediate key.
     */
    _hash(password: Uint8Array, input: Uint8Array, userBytes: Uint8Array): Uint8Array;
}
