Class StandardEncrypter

java.lang.Object
net.lingala.zip4j.crypto.StandardEncrypter
All Implemented Interfaces:
Encrypter

public class StandardEncrypter extends Object implements Encrypter
  • Field Details

    • zipCryptoEngine

      private final ZipCryptoEngine zipCryptoEngine
    • headerBytes

      private byte[] headerBytes
  • Constructor Details

    • StandardEncrypter

      public StandardEncrypter(char[] password, long key, boolean useUtf8ForPassword) throws ZipException
      Throws:
      ZipException
  • Method Details

    • init

      private void init(char[] password, long key, boolean useUtf8ForPassword) throws ZipException
      Throws:
      ZipException
    • encryptData

      public int encryptData(byte[] buff) throws ZipException
      Specified by:
      encryptData in interface Encrypter
      Throws:
      ZipException
    • encryptData

      public int encryptData(byte[] buff, int start, int len) throws ZipException
      Specified by:
      encryptData in interface Encrypter
      Throws:
      ZipException
    • encryptByte

      protected byte encryptByte(byte val)
    • generateRandomBytes

      protected byte[] generateRandomBytes()
    • getHeaderBytes

      public byte[] getHeaderBytes()