import { t as PptRecord } from "./tree-Du_LXAF0.cjs"; //#region src/encryption.d.ts interface PptEncryptionInfo { readonly keySizeBits: number; readonly salt: Uint8Array; readonly encryptedVerifier: Uint8Array; readonly encryptedVerifierHash: Uint8Array; } /** Parses a DocumentEncryptionAtom's own fields — never encrypted, since it is what a decryptor needs before it can decrypt anything else. */ declare function readDocumentEncryptionAtom(record: PptRecord): PptEncryptionInfo; /** * Decrypts a PowerPoint Document stream protected by [MS-OFFCRYPTO] 2.3.5 RC4 CryptoAPI, given the password and the persist directory/`encryptSessionPersistIdRef` `buildPersistDirectory` already resolved — both come from parsing the stream's own never-encrypted UserEditAtom/PersistDirectoryAtom chain, which is why this module needs them handed in rather than deriving them itself. * * Returns a new, fully decrypted copy of the stream: every persist object in `directory` except the DocumentEncryptionAtom itself gets its own key, derived from its own persist ID as the RC4 CryptoAPI "block number" (see this file's own top comment), and is decrypted as one continuous keystream covering its header and data together — the header is encrypted too here, unlike the shared xls/doc RC4 scheme, so each object's own recLen has to be learned by decrypting its header first. * * Throws `PptEncryptedError` for a missing password, an incorrect one, or an encryption shape this module does not implement (anything other than RC4 CryptoAPI) — there is no partial or best-effort result to return in any of those cases. */ declare function decryptPptDocumentStream(streamBytes: Uint8Array, directory: ReadonlyMap, encryptSessionPersistIdRef: number, password: string): Uint8Array; //#endregion export { PptEncryptionInfo, decryptPptDocumentStream, readDocumentEncryptionAtom };