Class HKDFParameterSpec

  • All Implemented Interfaces:
    java.security.spec.AlgorithmParameterSpec, java.security.spec.KeySpec

    public class HKDFParameterSpec
    extends java.lang.Object
    implements java.security.spec.KeySpec, java.security.spec.AlgorithmParameterSpec
    • Constructor Summary

      Constructors 
      Constructor Description
      HKDFParameterSpec​(byte[] ikm, byte[] salt, byte[] info, int outputLength)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      byte[] getIKM()
      Returns the input keying material or seed.
      byte[] getInfo()
      Returns the info field, which may be empty (null is converted to empty).
      int getOutputLength()
      Returns the length (in bytes) of the output resulting from these parameters.
      byte[] getSalt()
      Returns the salt, or null if the salt should be generated as a byte array of HashLen zeros.
      boolean skipExtract()
      Returns if step 1: extract has to be skipped or not
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • HKDFParameterSpec

        public HKDFParameterSpec​(byte[] ikm,
                                 byte[] salt,
                                 byte[] info,
                                 int outputLength)
    • Method Detail

      • getIKM

        public byte[] getIKM()
        Returns the input keying material or seed.
        Returns:
        the keying material
      • skipExtract

        public boolean skipExtract()
        Returns if step 1: extract has to be skipped or not
        Returns:
        true for skipping, false for no skipping of step 1
      • getSalt

        public byte[] getSalt()
        Returns the salt, or null if the salt should be generated as a byte array of HashLen zeros.
        Returns:
        the salt, or null
      • getInfo

        public byte[] getInfo()
        Returns the info field, which may be empty (null is converted to empty).
        Returns:
        the info field, never null
      • getOutputLength

        public int getOutputLength()
        Returns the length (in bytes) of the output resulting from these parameters.
        Returns:
        output length, in bytes.