Package org.conscrypt
Class HpkeSuite
java.lang.Object
org.conscrypt.HpkeSuite
Holds the KEM, KDF, and AEAD that are used and supported by
HpkeContextRecipient and
HpkeContextSender defined on RFC 9180.
Some of the constants are defined in IANA HPKE.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAEAD ciphers.static enumKey Derivation Functions (KDFs)static enumKey Encapsulation Mechanisms (KEMs) -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intAEAD: 0x0001 AES-128-GCMstatic final intAEAD: 0x0002 AES-256-GCMstatic final intAEAD: 0x0003 ChaCha20Poly1305static final intKDF: 0x0001 HKDF-SHA256static final intKEM: 0x0020 DHKEM(X25519, HKDF-SHA256)static final intKEM: 0x0042 ML-KEM-1024static final intKEM: 0x0041 ML-KEM-768static final intKEM: 0x647a X-Wingprivate final HpkeSuite.AEADprivate final HpkeSuite.KDFprivate final HpkeSuite.KEM -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertAead(int aead) Deprecated.convertKdf(int kdf) Deprecated.convertKem(int kem) Deprecated.getAead()AEAD configured while creating an instance ofHpkeSuitegetKdf()KDF configured while creating an instance ofHpkeSuitegetKem()KEM configured while creating an instance ofHpkeSuitename()
-
Field Details
-
KEM_DHKEM_X25519_HKDF_SHA256
public static final int KEM_DHKEM_X25519_HKDF_SHA256KEM: 0x0020 DHKEM(X25519, HKDF-SHA256)- See Also:
-
KEM_MLKEM_768
public static final int KEM_MLKEM_768KEM: 0x0041 ML-KEM-768- See Also:
-
KEM_MLKEM_1024
public static final int KEM_MLKEM_1024KEM: 0x0042 ML-KEM-1024- See Also:
-
KEM_XWING
public static final int KEM_XWINGKEM: 0x647a X-Wing- See Also:
-
KDF_HKDF_SHA256
public static final int KDF_HKDF_SHA256KDF: 0x0001 HKDF-SHA256- See Also:
-
AEAD_AES_128_GCM
public static final int AEAD_AES_128_GCMAEAD: 0x0001 AES-128-GCM- See Also:
-
AEAD_AES_256_GCM
public static final int AEAD_AES_256_GCMAEAD: 0x0002 AES-256-GCM- See Also:
-
AEAD_CHACHA20POLY1305
public static final int AEAD_CHACHA20POLY1305AEAD: 0x0003 ChaCha20Poly1305- See Also:
-
mKem
-
mKdf
-
mAead
-
-
Constructor Details
-
HpkeSuite
public HpkeSuite(int kem, int kdf, int aead)
-
-
Method Details
-
name
-
getKem
KEM configured while creating an instance ofHpkeSuite- Returns:
- kem
-
getKdf
KDF configured while creating an instance ofHpkeSuite- Returns:
- kdf
-
getAead
AEAD configured while creating an instance ofHpkeSuite- Returns:
- aead
-
convertKem
Deprecated.Converts the KEM value into itsHpkeSuite.KEMrepresentation.- Parameters:
kem- value- Returns:
HpkeSuite.KEMrepresentation.
-
convertKdf
Deprecated.Converts the KDF value into itsHpkeSuite.KDFrepresentation.- Parameters:
kdf- value- Returns:
HpkeSuite.KDFrepresentation.
-
convertAead
Deprecated.Converts the AEAD value into itsHpkeSuite.AEADrepresentation.- Parameters:
aead- value- Returns:
HpkeSuite.AEADrepresentation.
-