mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 12:20:42 +09:00
Add ML-KEM implementation for gcrypt
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
@@ -160,7 +160,12 @@ struct ssh_crypto_struct {
|
||||
ssh_curve25519_pubkey curve25519_server_pubkey;
|
||||
#endif
|
||||
#ifdef HAVE_MLKEM
|
||||
#ifdef HAVE_LIBGCRYPT
|
||||
unsigned char *mlkem_privkey;
|
||||
size_t mlkem_privkey_len;
|
||||
#else
|
||||
EVP_PKEY *mlkem_privkey;
|
||||
#endif
|
||||
ssh_string mlkem_client_pubkey;
|
||||
ssh_string mlkem_ciphertext;
|
||||
#endif
|
||||
|
||||
@@ -36,7 +36,12 @@ extern "C" {
|
||||
struct mlkem_type_info {
|
||||
size_t pubkey_size;
|
||||
size_t ciphertext_size;
|
||||
#ifdef HAVE_LIBGCRYPT
|
||||
size_t privkey_size;
|
||||
enum gcry_kem_algos alg;
|
||||
#else
|
||||
const char *name;
|
||||
#endif
|
||||
};
|
||||
|
||||
extern const struct mlkem_type_info MLKEM768_INFO;
|
||||
|
||||
Reference in New Issue
Block a user