Interface TLSKDFExpandLabelSpec
- All Superinterfaces:
AlgorithmParameterSpec
This interface specifies the set of parameters used to instantiate a
DerivationFunction implementing the Key Derivation HKDF-Expand-Label
It can be used with the label prefix "tls13 " to perform TLS 1.3 operations (RFC 8446) or with the label prefix "dtls13" to perform DTLS 1.3 operations (RFC 9147).
This interface is bound to the constant DerivationFunction.ALG_HKDF_EXPAND_LABEL_TLS13.
- Since:
- 3.2
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final shortReferences the label prefix "dtls13" defined in DTLS 1.3 - IETF RFC 9147.static final shortReferences the label prefix "tls13 " defined in TLS 1.3 - IETF RFC 8446. -
Method Summary
Modifier and TypeMethodDescriptionbyteReturns the HMAC Algorithm associated with the derivation function.byte[]Gets the context.byte[]getLabel()Gets the label.shortRequests the label prefix to use.shortReturns the HKDF-Expand-Label output length in bytes.byte[]Gets the secret value for the key derivation function.
-
Field Details
-
LABEL_PREFIX_TLS13
static final short LABEL_PREFIX_TLS13References the label prefix "tls13 " defined in TLS 1.3 - IETF RFC 8446. It is a value that can be returned by the methodgetLabelPrefix().- See Also:
-
LABEL_PREFIX_DTLS13
static final short LABEL_PREFIX_DTLS13References the label prefix "dtls13" defined in DTLS 1.3 - IETF RFC 9147. It is a value that can be returned by the methodgetLabelPrefix().- See Also:
-
-
Method Details
-
getAlgorithm
byte getAlgorithm()Returns the HMAC Algorithm associated with the derivation function.- Returns:
- the HMAC algorithm associated with the derivation function
- See Also:
-
getSecret
byte[] getSecret()Gets the secret value for the key derivation function.It may be an array view.
- Returns:
- the secret value
-
getLabelPrefix
short getLabelPrefix()Requests the label prefix to use.Possible returned values are
LABEL_PREFIX_TLS13andLABEL_PREFIX_DTLS13.- Returns:
- the requested label prefix
-
getLabel
byte[] getLabel()Gets the label.It may be an array view. It may be null.
- Returns:
- the label
-
getContext
byte[] getContext()Gets the context.It may be an array view. It may be null.
- Returns:
- the context
-
getOutputLength
short getOutputLength()Returns the HKDF-Expand-Label output length in bytes. It specifies the total length of data that can be generated using subsequent calls toDerivationFunction.nextBytes(byte[], short, short)orDerivationFunction.nextBytes(javacard.security.SecretKey).- Returns:
- the output length
-