MCPcopy Create free account
hub / github.com/LibPDF-js/core / tryOwnerPassword

Method tryOwnerPassword

src/security/standard-handler.ts:197–204  ·  view source on GitHub ↗

* Try to authenticate with the owner password.

(password: Uint8Array)

Source from the content-addressed store, hash-verified

195 * Try to authenticate with the owner password.
196 */
197 private tryOwnerPassword(password: Uint8Array): AuthResult {
198 const { revision } = this.encryptDict;
199
200 if (revision >= 5) {
201 return this.tryOwnerPasswordR56(password);
202 }
203 return this.tryOwnerPasswordR2R4(password);
204 }
205
206 /**
207 * Try user password for R2-R4 encryption.

Callers 1

authenticateMethod · 0.95

Calls 2

tryOwnerPasswordR56Method · 0.95
tryOwnerPasswordR2R4Method · 0.95

Tested by

no test coverage detected