Class AesBytesEncryptor

  • All Implemented Interfaces:
    BytesEncryptor

    public final class AesBytesEncryptor
    extends java.lang.Object
    implements BytesEncryptor
    Encryptor that uses 256-bit AES encryption.
    • Constructor Detail

      • AesBytesEncryptor

        public AesBytesEncryptor​(java.lang.String password,
                                 java.lang.CharSequence salt)
      • AesBytesEncryptor

        public AesBytesEncryptor​(java.lang.String password,
                                 java.lang.CharSequence salt,
                                 BytesKeyGenerator ivGenerator)
    • Method Detail

      • encrypt

        public byte[] encrypt​(byte[] bytes)
        Description copied from interface: BytesEncryptor
        Encrypt the byte array.
        Specified by:
        encrypt in interface BytesEncryptor
      • decrypt

        public byte[] decrypt​(byte[] encryptedBytes)
        Description copied from interface: BytesEncryptor
        Decrypt the byte array.
        Specified by:
        decrypt in interface BytesEncryptor