Class JceCtrCryptoCodec

java.lang.Object
org.apache.hadoop.crypto.CryptoCodec
org.apache.hadoop.crypto.JceCtrCryptoCodec
All Implemented Interfaces:
Closeable, AutoCloseable, Configurable
Direct Known Subclasses:
JceAesCtrCryptoCodec, JceSm4CtrCryptoCodec

@Private @Evolving public abstract class JceCtrCryptoCodec extends CryptoCodec
  • Constructor Details

    • JceCtrCryptoCodec

      public JceCtrCryptoCodec()
  • Method Details

    • getProvider

      public String getProvider()
    • calculateIV

      public void calculateIV(byte[] initIV, long counter, byte[] iv, int blockSize)
    • close

      public void close() throws IOException
      Throws:
      IOException
    • getLogger

      protected abstract org.slf4j.Logger getLogger()
    • getConf

      public Configuration getConf()
      Description copied from interface: Configurable
      Return the configuration used by this object.
      Returns:
      Configuration
    • setConf

      public void setConf(Configuration conf)
      Description copied from interface: Configurable
      Set the configuration to be used by this object.
      Parameters:
      conf - configuration to be used
    • generateSecureRandom

      public void generateSecureRandom(byte[] bytes)
      Description copied from class: CryptoCodec
      Generate a number of secure, random bytes suitable for cryptographic use. This method needs to be thread-safe.
      Specified by:
      generateSecureRandom in class CryptoCodec
      Parameters:
      bytes - byte array to populate with random data