Package org.conscrypt

Enum HpkeSuite.KDF

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<HpkeSuite.KDF>
    Enclosing class:
    HpkeSuite

    public static enum HpkeSuite.KDF
    extends java.lang.Enum<HpkeSuite.KDF>
    Key Derivation Functions (KDFs)
    See Also:
    rfc9180
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      HKDF_SHA256  
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int hLength  
      private java.lang.String hName  
      private int id  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private KDF​(int id, int hLength, java.lang.String hName)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      static HpkeSuite.KDF forId​(int id)
      Returns the KDF value for a given id.
      int getHLength()
      Deprecated.
      int getId()
      KDF id
      java.lang.String getMacAlgorithmName()
      Deprecated.
      int getMacLength()
      The length in bytes for the output extract function.
      java.lang.String getMacName()  
      long maxExportLength()
      Returns the maximum export length that can be supported with this KDF.
      static HpkeSuite.KDF valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static HpkeSuite.KDF[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

    • Field Detail

      • id

        private final int id
      • hLength

        private final int hLength
      • hName

        private final java.lang.String hName
    • Constructor Detail

      • KDF

        private KDF​(int id,
                    int hLength,
                    java.lang.String hName)
    • Method Detail

      • values

        public static HpkeSuite.KDF[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (HpkeSuite.KDF c : HpkeSuite.KDF.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static HpkeSuite.KDF valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getId

        public int getId()
        KDF id
        Returns:
        kdf id
        See Also:
        KDF ids
      • getMacLength

        public int getMacLength()
        The length in bytes for the output extract function.
        Returns:
        extract output size in bytes
      • getHLength

        @Deprecated
        public int getHLength()
        Deprecated.
      • maxExportLength

        public long maxExportLength()
        Returns the maximum export length that can be supported with this KDF.
        See Also:
        secret export
      • getMacAlgorithmName

        @Deprecated
        public java.lang.String getMacAlgorithmName()
        Deprecated.
        Name as defined in Mac.
        Returns:
        name of mac algorithm used by the kdf.
      • getMacName

        public java.lang.String getMacName()
      • forId

        public static HpkeSuite.KDF forId​(int id)
        Returns the KDF value for a given id.