class HexaPDF::Encryption::StandardSecurityHandler


The password-based standard security handler of the PDF specification, identified by a /Filter value of /Standard.


The PDF specification defines one security handler that should be implemented by all PDF conform libraries and applications. This standard security handler allows access permissions and a user password as well as an owner password to be set. See StandardSecurityHandler::EncryptionOptions for all valid options that can be used with this security handler.

The access permissions (see StandardSecurityHandler::Permissions) can be used to restrict what a user is allowed to do with a PDF file.

When a user or owner password is specified, a PDF file can only be opened when the correct password is supplied.

See: PDF1.7 s7.6.3, PDF2.0 s7.6.3



The padding used for passwords with fewer than 32 bytes. Only used for revisions <= 4.

See: PDF1.7 s7.6.3.3

Public Instance Methods


Additionally checks that the document trailer's ID has not changed.

See: SecurityHandler#encryption_key_valid?


Returns the permissions of the managed dictionary as array of symbol values.

See: Permissions