key definitions
This commit is contained in:
+13
-1
@@ -22,7 +22,19 @@ extern "C" {
|
|||||||
#define BRAVAIS_MAX_DATAGRAM_SIZE 1500
|
#define BRAVAIS_MAX_DATAGRAM_SIZE 1500
|
||||||
#define BRAVAIS_MAX_PLAINTEXT_SIZE 65535
|
#define BRAVAIS_MAX_PLAINTEXT_SIZE 65535
|
||||||
|
|
||||||
#define BRAVAIS_KEY_LENGTH 32 // For X25519 private and public - do PQC later
|
#define BRAVAIS_NONCE_LENGTH 12
|
||||||
|
#define BRAVAIS_AEAD_TAG_LENGTH 16 // Poly1305 and GCM alike
|
||||||
|
#define BRAVAIS_CHACHA20_POLY1305_KEY_LENGTH 32
|
||||||
|
#define BRAVAIS_QUIC_INITIAL_KEY_LENGTH 16 // AES-128-GCM
|
||||||
|
#define BRAVAIS_QUIC_INITIAL_IV_LENGTH 12 // XORed with the packet number
|
||||||
|
#define BRAVAIS_QUIC_HP_KEY_LENGTH 16 // AES-128-ECB header protection
|
||||||
|
#define BRAVAIS_QUIC_HP_SAMPLE_LENGTH 16
|
||||||
|
#define BRAVAIS_X25519_KEY_LENGTH 32 // For X25519 private and public
|
||||||
|
#define BRAVAIS_ML_KEM_768_PUBLIC_KEY_LENGTH 1184 // encapsulation key
|
||||||
|
#define BRAVAIS_ML_KEM_768_PRIVATE_KEY_LENGTH 2400 // decapsulation key, expanded
|
||||||
|
#define BRAVAIS_ML_KEM_768_SEED_LENGTH 64 // d || z, expands to the private key
|
||||||
|
#define BRAVAIS_ML_KEM_768_CIPHERTEXT_LENGTH 1088
|
||||||
|
#define BRAVAIS_ML_KEM_768_SHARED_SECRET_LENGTH 32
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
// Error codes; Generally <0 = error, 0 = success
|
// Error codes; Generally <0 = error, 0 = success
|
||||||
|
|||||||
Reference in New Issue
Block a user