diff options
author | Aris Adamantiadis <aris@0xbadc0de.be> | 2013-09-21 23:34:50 +0200 |
---|---|---|
committer | Aris Adamantiadis <aris@0xbadc0de.be> | 2013-09-27 15:32:44 +0200 |
commit | 4cb6afcbd43ab503d4c3d3054b96a1492605ea8d (patch) | |
tree | dd142bcab88629a984936e708cca3d5ac9a1d1c6 /include/libssh/crypto.h | |
parent | 4eae4d592cb9195cac49832bf3bd4052c418b948 (diff) | |
download | libssh-4cb6afcbd43ab503d4c3d3054b96a1492605ea8d.tar.gz libssh-4cb6afcbd43ab503d4c3d3054b96a1492605ea8d.tar.xz libssh-4cb6afcbd43ab503d4c3d3054b96a1492605ea8d.zip |
kex: implement curve25519-sha256@libssh.org
Diffstat (limited to 'include/libssh/crypto.h')
-rw-r--r-- | include/libssh/crypto.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/include/libssh/crypto.h b/include/libssh/crypto.h index 5376ca61..eaff2ffd 100644 --- a/include/libssh/crypto.h +++ b/include/libssh/crypto.h @@ -44,6 +44,7 @@ #endif #include "libssh/ecdh.h" #include "libssh/kex.h" +#include "libssh/curve25519.h" enum ssh_key_exchange_e { /* diffie-hellman-group1-sha1 */ @@ -51,7 +52,9 @@ enum ssh_key_exchange_e { /* diffie-hellman-group14-sha1 */ SSH_KEX_DH_GROUP14_SHA1, /* ecdh-sha2-nistp256 */ - SSH_KEX_ECDH_SHA2_NISTP256 + SSH_KEX_ECDH_SHA2_NISTP256, + /* curve25519-sha256@libssh.org */ + SSH_KEX_CURVE25519_SHA256_LIBSSH_ORG }; struct ssh_crypto_struct { @@ -61,6 +64,11 @@ struct ssh_crypto_struct { ssh_string ecdh_client_pubkey; ssh_string ecdh_server_pubkey; #endif +#ifdef HAVE_CURVE25519 + ssh_curve25519_privkey curve25519_privkey; + ssh_curve25519_pubkey curve25519_client_pubkey; + ssh_curve25519_pubkey curve25519_server_pubkey; +#endif ssh_string dh_server_signature; /* information used by dh_handshake. */ size_t digest_len; /* len of all the fields below */ unsigned char *session_id; |