pdf-lite - v1.0.1
    Preparing search index...
    • Computes the Algorithm 2.B hash for PDF 2.0 AES-256 encryption. This iterative hash algorithm uses SHA-256, SHA-384, or SHA-512 based on intermediate results, running for at least 64 rounds.

      Parameters

      • password: ByteArray

        The user or owner password.

      • salt: ByteArray

        The 8-byte validation or key salt.

      • userKey: ByteArray = ...

        The user key (required for owner password validation). Defaults to empty.

      Returns Promise<ByteArray>

      A promise that resolves to a 32-byte hash.

      const hash = await computeAlgorithm2bHash(password, salt)