| 1 | /* This Source Code Form is subject to the terms of the Mozilla Public |
| 2 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
| 3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
| 4 | |
| 5 | #ifndef KYBER_UTIL_H |
| 6 | #define KYBER_UTIL_H |
| 7 | |
| 8 | #define KYBER768_PUBLIC_KEY_BYTES 1184U |
| 9 | #define KYBER768_PRIVATE_KEY_BYTES 2400U |
| 10 | #define KYBER768_CIPHERTEXT_BYTES 1088U |
| 11 | |
| 12 | #define KYBER_SHARED_SECRET_BYTES 32U |
| 13 | #define KYBER_KEYPAIR_COIN_BYTES 64U |
| 14 | #define KYBER_ENC_COIN_BYTES 32U |
| 15 | |
| 16 | typedef enum { |
| 17 | params_kyber_invalid, |
| 18 | |
| 19 | /* |
| 20 | * The Kyber768 parameters specified in version 3.02 of the NIST submission |
| 21 | * https://pq-crystals.org/kyber/data/kyber-specification-round3-20210804.pdf |
| 22 | */ |
| 23 | params_kyber768_round3, |
| 24 | |
| 25 | /* |
| 26 | * Identical to params_kyber768_round3 except that this parameter set allows |
| 27 | * the use of a seed in `Kyber_Encapsulate` for testing. |
| 28 | */ |
| 29 | params_kyber768_round3_test_mode, |
| 30 | } KyberParams; |
| 31 | |
| 32 | #endif /* KYBER_UTIL_H */ |
| 33 | |