Class StandardSecurityHandler

java.lang.Object
com.itextpdf.kernel.crypto.securityhandler.SecurityHandler
com.itextpdf.kernel.crypto.securityhandler.StandardSecurityHandler
Direct Known Subclasses:
StandardHandlerUsingAes256, StandardHandlerUsingStandard40

public abstract class StandardSecurityHandler extends SecurityHandler
  • Field Details

    • PERMS_MASK_1_FOR_REVISION_2

      protected static final int PERMS_MASK_1_FOR_REVISION_2
      See Also:
    • PERMS_MASK_1_FOR_REVISION_3_OR_GREATER

      protected static final int PERMS_MASK_1_FOR_REVISION_3_OR_GREATER
      See Also:
    • PERMS_MASK_2

      protected static final int PERMS_MASK_2
      See Also:
    • permissions

      protected long permissions
    • usedOwnerPassword

      protected boolean usedOwnerPassword
  • Constructor Details

    • StandardSecurityHandler

      public StandardSecurityHandler()
  • Method Details

    • getPermissions

      public long getPermissions()
    • isUsedOwnerPassword

      public boolean isUsedOwnerPassword()
    • setStandardHandlerDicEntries

      protected void setStandardHandlerDicEntries (PdfDictionary encryptionDictionary, byte[] userKey, byte[] ownerKey)
    • generateOwnerPasswordIfNullOrEmpty

      protected byte[] generateOwnerPasswordIfNullOrEmpty (byte[] ownerPassword)
    • getIsoBytes

      protected byte[] getIsoBytes (PdfString string)
      Gets bytes of String-value without considering encoding.
      Parameters:
      string - a PdfString to get bytes from it
      Returns:
      byte array
    • equalsArray

      protected static boolean equalsArray (byte[] ar1, byte[] ar2, int size)