Skip to content

Commit 8b57e3e

Browse files
authored
Merge pull request #7807 from Laboratory-for-Safe-and-Secure-Systems/mlkem_compat
ML-KEM compatibility
2 parents 055d68d + 2a2f9d5 commit 8b57e3e

1 file changed

Lines changed: 20 additions & 4 deletions

File tree

wolfssl/ssl.h

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4068,9 +4068,9 @@ enum {
40684068
WOLFSSL_FFDHE_8192 = 260,
40694069

40704070
#ifdef HAVE_PQC
4071-
/* These group numbers were taken from OQS's openssl fork, see:
4072-
* https://github.com/open-quantum-safe/openssl/blob/OQS-OpenSSL_1_1_1-stable/
4073-
* oqs-template/oqs-kem-info.md.
4071+
/* These group numbers were taken from OQS's openssl provider, see:
4072+
* https://github.com/open-quantum-safe/oqs-provider/blob/main/oqs-template/
4073+
* oqs-kem-info.md.
40744074
*
40754075
* The levels in the group name refer to the claimed NIST level of each
40764076
* parameter set. The associated parameter set name is listed as a comment
@@ -4084,6 +4084,7 @@ enum {
40844084
* algorithms have LEVEL2 and LEVEL4 because none of these submissions
40854085
* included them. */
40864086

4087+
#ifndef WOLFSSL_ML_KEM
40874088
WOLFSSL_PQC_MIN = 570,
40884089
WOLFSSL_PQC_SIMPLE_MIN = 570,
40894090
WOLFSSL_KYBER_LEVEL1 = 570, /* KYBER_512 */
@@ -4097,7 +4098,22 @@ enum {
40974098
WOLFSSL_P521_KYBER_LEVEL5 = 12093,
40984099
WOLFSSL_PQC_HYBRID_MAX = 12093,
40994100
WOLFSSL_PQC_MAX = 12093,
4100-
#endif
4101+
#else
4102+
WOLFSSL_PQC_MIN = 583,
4103+
WOLFSSL_PQC_SIMPLE_MIN = 583,
4104+
WOLFSSL_KYBER_LEVEL1 = 583, /* ML-KEM 512 */
4105+
WOLFSSL_KYBER_LEVEL3 = 584, /* ML-KEM 768 */
4106+
WOLFSSL_KYBER_LEVEL5 = 585, /* ML-KEM 1024 */
4107+
WOLFSSL_PQC_SIMPLE_MAX = 585,
4108+
4109+
WOLFSSL_PQC_HYBRID_MIN = 12103,
4110+
WOLFSSL_P256_KYBER_LEVEL1 = 12103,
4111+
WOLFSSL_P384_KYBER_LEVEL3 = 12104,
4112+
WOLFSSL_P521_KYBER_LEVEL5 = 12105,
4113+
WOLFSSL_PQC_HYBRID_MAX = 12105,
4114+
WOLFSSL_PQC_MAX = 12105,
4115+
#endif /* WOLFSSL_ML_KEM */
4116+
#endif /* HAVE_PQC */
41014117
};
41024118

41034119
enum {

0 commit comments

Comments
 (0)