Enum Class CompositeMode
- All Implemented Interfaces:
Serializable,Comparable<CompositeMode>,Constable
A composite key pairs a classical component with a post-quantum one. The platform publishes the
single coarse key type COMPOSITE for every such pairing: the pairing itself is named by
alg (for example X25519+ML-KEM-768) and the construction — how the two
components work together — is this value, on its own axis.
This enumeration is the SDK's view of the compositeMode member published by
AlgorithmInfo (catalogue entries) and KeyMetadata (keys). It is absent — the
getter answers null — for every simple key and every simple algorithm; absence is the
statement "this is not composite", not a missing value.
Usage Example:
for (AlgorithmInfo info : sdk.getSupportedAlgorithms()) {
if (info.getCompositeMode() == CompositeMode.COMPOSITE_KEM_COMBINE) {
System.out.println(info.getAlg() + " derives one secret via " + info.getKty());
}
}
- Since:
- 3.0.0
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe component secrets are combined into a single shared secret through the key derivation function named byKeyMetadata.getKdf().The components sign independently, and the results are adjudicated by the key's verification policy. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic CompositeModeReturns the enum constant of this class with the specified name.static CompositeMode[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
COMPOSITE_KEM_COMBINE
The component secrets are combined into a single shared secret through the key derivation function named byKeyMetadata.getKdf(). -
COMPOSITE_SIGNATURE
The components sign independently, and the results are adjudicated by the key's verification policy.
-
-
Field Details
-
KEY_TYPE
The single coarse key type every composite key and every hybrid catalogue entry publishes.It is deliberately one token for every pairing and every construction: the pairing is named by
alg, the construction by a member of this enumeration. Comparing a key type against a member's name is the defect this constant exists to prevent — the two are different axes and a member name is never a key type.- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-